ITADN

Add Depth32F and Depth32F_Stencil8 Pixel Formats

#5Closedsridenour 创建于 2023-01-05
S
sridenourcommented
Right now, the only pixel format available for depth buffers in SDL_GPU is `Depth24_Stencil8`. **The issue:** Metal doesn't support this format on iOS (see screenshot of `MTLPixelFormat.h` below), it's macOS-only. On iOS there's only `Depth32F` and `Depth32F_Stencil8` (and `Depth16`, if you like z-fighting ;) ) Metal **does** support `Depth32F` and `Depth32F_Stencil8` on both iOS and macOS. They're also available in DX12 and Vulkan. `Depth32F` also gives more precision for large scenes. Please add `Depth32F` and `Depth32F_Stencil8` pixel formats to SDL_GPU. (I'm *not* arguing for Depth24_Stencil8 to be removed) ![MTLPixelFormat.h screenshot](https://user-images.githubusercontent.com/659453/210888496-b042fe36-d8ca-4815-a26b-3f934247c33b.png)
关闭于 2024-07-29 1 条评论