forked from Misaki/GhostEngine
feat: Implement D3D12 resource factory and improve swap chain management
- Added D3D12ResourceFactory for creating render targets, textures, and buffers. - Enhanced D3D12SwapChain to manage back buffer render targets and provide access to them. - Updated D3D12Texture to utilize resource handles for better resource management. - Removed legacy ResourceAllocator and integrated improvements for resource handling. - Introduced new interfaces for resource factory and swap chain to streamline resource creation. - Added support for mip levels and texture dimensions in render target and texture descriptions. - Created new markdown files to document allocator and swap chain improvements.
This commit is contained in:
@@ -81,6 +81,8 @@ public readonly struct TextureHandle : IEquatable<TextureHandle>, IDisposable
|
||||
|
||||
internal ResourceHandle ResourceHandle => _resourceHandle;
|
||||
|
||||
public static TextureHandle Invalid => new(ResourceHandle.Invalid);
|
||||
|
||||
internal TextureHandle(ResourceHandle resourceHandle)
|
||||
{
|
||||
_resourceHandle = resourceHandle;
|
||||
@@ -125,6 +127,8 @@ public readonly struct BufferHandle : IEquatable<BufferHandle>, IDisposable
|
||||
|
||||
internal ResourceHandle ResourceHandle => _resourceHandle;
|
||||
|
||||
public static BufferHandle Invalid => new(ResourceHandle.Invalid);
|
||||
|
||||
internal BufferHandle(ResourceHandle resourceHandle)
|
||||
{
|
||||
_resourceHandle = resourceHandle;
|
||||
|
||||
Reference in New Issue
Block a user