The TextureBuilder
struct in the Sandbox
namespace is used to configure and create textures with various properties and usage hints for optimal performance and flexibility in rendering operations.
The TextureBuilder
struct in the Sandbox
namespace is used to configure and create textures with various properties and usage hints for optimal performance and flexibility in rendering operations.
Member Name | Summary |
---|---|
WithStaticUsage | Provides a hint to the GPU that this texture will not be modified. |
WithSemiStaticUsage | Provides a hint to the GPU that this texture will only be updated sometimes. |
WithDynamicUsage | Provides a hint to the GPU that this texture will be updated regularly (almost every frame). |
WithGPUOnlyUsage | Specify the texture to ONLY be used on the GPU and not allow CPU access. |
WithSize | Sets the size of the texture using width and height. |
WithWidth | Sets the width of the texture. |
WithHeight | Sets the height of the texture. |
WithDepth | Sets the depth of the texture. |
WithMSAA | Sets the multisample anti-aliasing (MSAA) level for the texture. |
WithMultiSample2X | Sets the texture to use 2x multisampling. |
WithMultiSample4X | Sets the texture to use 4x multisampling. |
WithMultiSample6X | Sets the texture to use 6x multisampling. |
WithMultiSample8X | Sets the texture to use 8x multisampling. |
WithMultiSample16X | Sets the texture to use 16x multisampling. |
WithScreenMultiSample | Sets the texture to use the same multisampling as the screen/framebuffer. |
WithFormat | Sets the format of the texture. |
WithScreenFormat | Sets the internal texture format to use the same format as the screen/frame buffer. |
WithDepthFormat | Uses the same depth format as the screen/framebuffer. |
WithMips | Sets the number of mipmap levels for the texture. |
WithUAVBinding | Enables or disables UAV (Unordered Access View) binding for the texture. |
Create | Creates a texture with the specified name, anonymity, data, and data length. |