begin render test
This commit is contained in:
parent
a39c649dc3
commit
fdecaacebd
@ -215,7 +215,7 @@ int CALLBACK wWinMain(_In_ HINSTANCE instance, _In_opt_ HINSTANCE prev_instance,
|
||||
/* Run app start job */
|
||||
if (!Atomic32Fetch(&g->panicking))
|
||||
{
|
||||
RunJob(1, W32_AppStartupJob, 0, JobPool_Floating, JobPriority_High, 0);
|
||||
RunJob(1, W32_AppStartupJob, JobPool_Floating, JobPriority_High, 0, 0);
|
||||
}
|
||||
|
||||
/* Wait for startup end or panic */
|
||||
@ -243,7 +243,7 @@ int CALLBACK wWinMain(_In_ HINSTANCE instance, _In_opt_ HINSTANCE prev_instance,
|
||||
/* Run exit callbacks job */
|
||||
if (!Atomic32Fetch(&g->panicking))
|
||||
{
|
||||
RunJob(1, W32_AppShutdownJob, 0, JobPool_Floating, JobPriority_High, 0);
|
||||
RunJob(1, W32_AppShutdownJob, JobPool_Floating, JobPriority_High, 0, 0);
|
||||
}
|
||||
|
||||
/* Wait for exit end or panic */
|
||||
|
||||
6
src/gtest/dx12/gtest_dx12.c
Normal file
6
src/gtest/dx12/gtest_dx12.c
Normal file
@ -0,0 +1,6 @@
|
||||
////////////////////////////////
|
||||
//~ Startup
|
||||
|
||||
void GT_StartupCore(void)
|
||||
{
|
||||
}
|
||||
0
src/gtest/dx12/gtest_dx12.h
Normal file
0
src/gtest/dx12/gtest_dx12.h
Normal file
13
src/gtest/gtest.c
Normal file
13
src/gtest/gtest.c
Normal file
@ -0,0 +1,13 @@
|
||||
#include "gtest.h"
|
||||
|
||||
#if PlatformIsWindows
|
||||
# include "dx12/gtest_dx12.c"
|
||||
#else
|
||||
# error Gpu backend not implemented
|
||||
#endif
|
||||
void GT_Main(void)
|
||||
{
|
||||
RunOnce();
|
||||
GT_StartupDeps();
|
||||
GT_StartupCore();
|
||||
}
|
||||
22
src/gtest/gtest.h
Normal file
22
src/gtest/gtest.h
Normal file
@ -0,0 +1,22 @@
|
||||
#ifndef GTEST_H
|
||||
#define GTEST_H
|
||||
|
||||
////////////////////////////////
|
||||
//~ Layer dependencies
|
||||
|
||||
#include "../base/base.h"
|
||||
inline void GT_StartupDeps(void)
|
||||
{
|
||||
BaseMain();
|
||||
}
|
||||
|
||||
////////////////////////////////
|
||||
//~ Layer headers
|
||||
|
||||
#include "gtest_core.h"
|
||||
#if PlatformIsWindows
|
||||
# include "dx12/gtest_dx12.h"
|
||||
#endif
|
||||
void GT_Main(void);
|
||||
|
||||
#endif
|
||||
4
src/gtest/gtest_core.h
Normal file
4
src/gtest/gtest_core.h
Normal file
@ -0,0 +1,4 @@
|
||||
////////////////////////////////
|
||||
//~ Startup
|
||||
|
||||
void GT_StartupCore(void);
|
||||
@ -15,7 +15,7 @@ void PB_StartupCore(void)
|
||||
PB_WSP_SharedState *g = &PB_WSP_shared_state;
|
||||
PB_WSP_InitializeWasapi();
|
||||
/* Start playback job */
|
||||
RunJob(1, PB_WSP_PlaybackJob, 0, JobPool_Audio, JobPriority_High, &g->PB_WSP_PlaybackJob_counter);
|
||||
RunJob(1, PB_WSP_PlaybackJob, JobPool_Audio, JobPriority_High, &g->PB_WSP_PlaybackJob_counter, 0);
|
||||
OnExit(&PB_WSP_Shutdown);
|
||||
}
|
||||
|
||||
|
||||
@ -5,7 +5,7 @@
|
||||
//~ Layer dependencies
|
||||
|
||||
#include "../base/base.h"
|
||||
#include "../gpu/gpu.h"
|
||||
#include "../gtest/gtest.h"
|
||||
#include "../sprite/sprite.h"
|
||||
#include "../font/font.h"
|
||||
#include "../collider/collider.h"
|
||||
@ -13,10 +13,11 @@
|
||||
#include "../net/net.h"
|
||||
#include "../mixer/mixer.h"
|
||||
#include "../bitbuff/bitbuff.h"
|
||||
#include "../rendertest/rendertest.h"
|
||||
inline void StartupPpDeps(void)
|
||||
{
|
||||
BaseMain();
|
||||
GPU_Main();
|
||||
GT_Main();
|
||||
S_Main();
|
||||
F_Main();
|
||||
CLD_Main();
|
||||
@ -24,6 +25,7 @@ inline void StartupPpDeps(void)
|
||||
N_Main();
|
||||
MIX_Main();
|
||||
BB_Main();
|
||||
RT_Main();
|
||||
}
|
||||
|
||||
////////////////////////////////
|
||||
|
||||
@ -44,8 +44,8 @@ void StartupUser(void)
|
||||
P_ShowWindow(g->window);
|
||||
|
||||
/* Start jobs */
|
||||
RunJob(1, UpdateUserJob, 0, JobPool_User, JobPriority_High, &g->shutdown_job_counters);
|
||||
RunJob(1, SimJob, 0, JobPool_Sim, JobPriority_High, &g->shutdown_job_counters);
|
||||
RunJob(1, UpdateUserJob, JobPool_User, JobPriority_High, &g->shutdown_job_counters, 0);
|
||||
RunJob(1, SimJob, JobPool_Sim, JobPriority_High, &g->shutdown_job_counters, 0);
|
||||
OnExit(&ShutdownUser);
|
||||
}
|
||||
|
||||
|
||||
@ -2064,7 +2064,6 @@ void StepSim(SimStepCtx *ctx)
|
||||
|
||||
ReleaseAllWithProp(world, Prop_Release);
|
||||
|
||||
|
||||
//- Sync to publish client
|
||||
|
||||
if (publish_client->valid && world->tick > publish_client->last_tick)
|
||||
|
||||
9
src/rendertest/rendertest.c
Normal file
9
src/rendertest/rendertest.c
Normal file
@ -0,0 +1,9 @@
|
||||
#include "rendertest.h"
|
||||
|
||||
#include "rendertest_core.c"
|
||||
void RT_Main(void)
|
||||
{
|
||||
RunOnce();
|
||||
RT_StartupDeps();
|
||||
RT_StartupCore();
|
||||
}
|
||||
27
src/rendertest/rendertest.h
Normal file
27
src/rendertest/rendertest.h
Normal file
@ -0,0 +1,27 @@
|
||||
#ifndef RENDERTEST_H
|
||||
#define RENDERTEST_H
|
||||
|
||||
////////////////////////////////
|
||||
//~ Layer dependencies
|
||||
|
||||
#include "../base/base.h"
|
||||
#include "../gpu/gpu.h"
|
||||
#include "../sprite/sprite.h"
|
||||
#include "../font/font.h"
|
||||
#include "../collider/collider.h"
|
||||
inline void RT_StartupDeps(void)
|
||||
{
|
||||
BaseMain();
|
||||
GPU_Main();
|
||||
S_Main();
|
||||
F_Main();
|
||||
CLD_Main();
|
||||
}
|
||||
|
||||
////////////////////////////////
|
||||
//~ Layer headers
|
||||
|
||||
#include "rendertest_core.h"
|
||||
void RT_Main(void);
|
||||
|
||||
#endif
|
||||
6
src/rendertest/rendertest_core.c
Normal file
6
src/rendertest/rendertest_core.c
Normal file
@ -0,0 +1,6 @@
|
||||
////////////////////////////////
|
||||
//~ Startup
|
||||
|
||||
void RT_StartupCore(void)
|
||||
{
|
||||
}
|
||||
4
src/rendertest/rendertest_core.h
Normal file
4
src/rendertest/rendertest_core.h
Normal file
@ -0,0 +1,4 @@
|
||||
////////////////////////////////
|
||||
//~ Startup
|
||||
|
||||
void RT_StartupCore(void);
|
||||
Loading…
Reference in New Issue
Block a user