feat(rhi)!: refactor resource handles to GPUTexture/GPUBuffer
Refactored all graphics resource handles to use Handle<GPUTexture> and Handle<GPUBuffer> instead of Handle<Texture> and Handle<GraphicsBuffer>. Updated all APIs, interfaces, and implementations to use the new types, including ICommandBuffer, IResourceAllocator, ISwapChain, IRenderOutput, IRenderGraphBuilder, and related classes. Introduced TempJobAllocator for frame-latency-aware allocations. Updated ResourceHandleExtensions for new conversions. Performed minor code cleanups and removed the empty ClusterLod.cs file. BREAKING CHANGE: All usages of Handle<Texture> and Handle<GraphicsBuffer> are replaced with Handle<GPUTexture> and Handle<GPUBuffer>. This affects all APIs and resource management code. Callers must update their code to use the new handle types.
This commit is contained in:
@@ -24,8 +24,8 @@ public unsafe struct Camera : IComponent
|
||||
public int swapChainIndex; // The index of the swap chain to render to. -1 means render to rt only.
|
||||
public int priority;
|
||||
|
||||
public Handle<Texture> colorTarget;
|
||||
public Handle<Texture> depthTarget;
|
||||
public Handle<GPUTexture> colorTarget;
|
||||
public Handle<GPUTexture> depthTarget;
|
||||
// TODO: Add more render targets like motion vector, etc.
|
||||
|
||||
// Custim render function. If it's not null, the render system will call this function instead of the default render pipeline.
|
||||
|
||||
Reference in New Issue
Block a user