207 lines
3.9 KiB
C
207 lines
3.9 KiB
C
////////////////////////////////
|
|
//~ @hookdef Startup hook
|
|
|
|
void GT_StartupCore(void)
|
|
{
|
|
}
|
|
|
|
////////////////////////////////
|
|
//~ @hookdef Rasterizer helper hooks
|
|
|
|
GT_Viewport GT_ViewportFromRect(Rect rect)
|
|
{
|
|
LAX rect;
|
|
return (GT_Viewport) ZI;
|
|
}
|
|
|
|
GT_Scissor GT_ScissorRectFromRect(Rect rect)
|
|
{
|
|
LAX rect;
|
|
return (GT_Scissor) ZI;
|
|
}
|
|
|
|
////////////////////////////////
|
|
//~ @hookdef Fence hooks
|
|
|
|
GT_Fence GT_GetGlobalFence(void)
|
|
{
|
|
return (GT_Fence) ZI;
|
|
}
|
|
|
|
////////////////////////////////
|
|
//~ @hookdef Resource hooks
|
|
|
|
GT_Resource *GT_AcquireResource(GT_ResourceDesc desc)
|
|
{
|
|
LAX desc;
|
|
return (GT_Resource *)0;
|
|
}
|
|
|
|
void GT_ReleaseResource(GT_Resource *resource, GT_Fence fence, GT_ReleaseFlag flags)
|
|
{
|
|
LAX resource;
|
|
LAX fence;
|
|
LAX flags;
|
|
}
|
|
|
|
u32 GT_GetResourceId(GT_Resource *resource)
|
|
{
|
|
LAX resource;
|
|
return 0;
|
|
}
|
|
|
|
Vec2I32 GT_GetTextureSize(GT_Resource *resource)
|
|
{
|
|
LAX resource;
|
|
return VEC2I32(0, 0);
|
|
}
|
|
|
|
////////////////////////////////
|
|
//~ @hookdef Command list hooks
|
|
|
|
GT_CommandList *GT_BeginCommandList(void)
|
|
{
|
|
return 0;
|
|
}
|
|
|
|
GT_Fence GT_EndCommandList(GT_CommandList *cl)
|
|
{
|
|
LAX cl;
|
|
return (GT_Fence) ZI;
|
|
}
|
|
|
|
void GT_ProfileDF(GT_CommandList *cl, String zone_name)
|
|
{
|
|
LAX cl;
|
|
LAX zone_name;
|
|
}
|
|
|
|
////////////////////////////////
|
|
//~ @hookdef Resource transition hooks
|
|
|
|
void GT_TransitionToSrv(GT_CommandList *cl, GT_Resource *resource)
|
|
{
|
|
LAX cl;
|
|
LAX resource;
|
|
}
|
|
|
|
void GT_TransitionToUav(GT_CommandList *cl, GT_Resource *resource)
|
|
{
|
|
LAX cl;
|
|
LAX resource;
|
|
}
|
|
|
|
void GT_TransitionToRtv(GT_CommandList *cl, GT_Resource *resource)
|
|
{
|
|
LAX cl;
|
|
LAX resource;
|
|
}
|
|
|
|
void GT_Flush(GT_CommandList *cl, GT_Resource *resource)
|
|
{
|
|
LAX cl;
|
|
LAX resource;
|
|
}
|
|
|
|
////////////////////////////////
|
|
//~ @hookdef Dispatch hooks
|
|
|
|
void GT_DispatchClear(GT_CommandList *cl, GT_Resource *resource)
|
|
{
|
|
LAX cl;
|
|
LAX resource;
|
|
}
|
|
|
|
void GT_DispatchRasterize(GT_CommandList *cl,
|
|
GT_ShaderDesc vs,
|
|
GT_ShaderDesc ps,
|
|
void *sig,
|
|
u32 rts_count,
|
|
GT_Resource **rts,
|
|
u32 viewports_count,
|
|
GT_Viewport *viewports,
|
|
u32 scissors_count,
|
|
GT_Scissor *scissors,
|
|
u32 instances_count,
|
|
GT_Resource *index_buffer,
|
|
GT_RasterizeMode mode)
|
|
{
|
|
LAX cl;
|
|
LAX vs;
|
|
LAX ps;
|
|
LAX sig;
|
|
LAX rts_count;
|
|
LAX rts;
|
|
LAX viewports_count;
|
|
LAX *viewports;
|
|
LAX scissors_count;
|
|
LAX scissors;
|
|
LAX instances_count;
|
|
LAX index_buffer;
|
|
LAX mode;
|
|
}
|
|
|
|
void GT_DispatchCompute(GT_CommandList *cl, GT_ShaderDesc cs, void *sig, u32 num_threads_x, u32 num_threads_y, u32 num_threads_z)
|
|
{
|
|
LAX cl;
|
|
LAX cs;
|
|
LAX sig;
|
|
LAX num_threads_x;
|
|
LAX num_threads_y;
|
|
LAX num_threads_z;
|
|
}
|
|
|
|
////////////////////////////////
|
|
//~ @hookdef Copy hooks
|
|
|
|
void GT_PushResource(GT_CommandList *cl, GT_Resource *dst, GT_Resource *src)
|
|
{
|
|
LAX cl;
|
|
LAX dst;
|
|
LAX src;
|
|
}
|
|
|
|
void GT_PushString(GT_CommandList *cl, GT_Resource *dst, String src)
|
|
{
|
|
LAX cl;
|
|
LAX dst;
|
|
LAX src;
|
|
}
|
|
|
|
////////////////////////////////
|
|
//~ @hookdef Memory info hooks
|
|
|
|
GT_MemoryInfo GT_QueryMemoryInfo(void)
|
|
{
|
|
return (GT_MemoryInfo) ZI;
|
|
}
|
|
|
|
////////////////////////////////
|
|
//~ @hookdef Swapchain hooks
|
|
|
|
GT_Swapchain *GT_AcquireSwapchain(P_Window *window, Vec2I32 size)
|
|
{
|
|
LAX window;
|
|
LAX size;
|
|
return 0;
|
|
}
|
|
|
|
void GT_ReleaseSwapchain(GT_Swapchain *swapchain)
|
|
{
|
|
LAX swapchain;
|
|
}
|
|
|
|
void GT_WaitOnSwapchain(GT_Swapchain *swapchain)
|
|
{
|
|
LAX swapchain;
|
|
}
|
|
|
|
void GT_PresentSwapchain(GT_Swapchain *swapchain, Vec2I32 backbuffer_resolution, GT_Resource *texture, Xform texture_xf, i32 vsync)
|
|
{
|
|
LAX swapchain;
|
|
LAX backbuffer_resolution;
|
|
LAX texture;
|
|
LAX texture_xf;
|
|
LAX vsync;
|
|
}
|