API > RenderTextureDescriptor
RenderTextureDescriptor⚓︎
This struct contains all the information required to create a RenderTexture. It can be copied, cached, and reused to easily create RenderTextures that all share the same properties. Avoid using the default constructor as it does not initialize some flags with the recommended values.
Members⚓︎
Properties⚓︎
Name | Description |
---|---|
RenderTextureDescriptor .autoGenerateMips |
Mipmap levels are generated automatically when this flag is set. |
RenderTextureDescriptor .bindMS |
If true and msaaSamples is greater than 1, the render texture will not be resolved by default. Use this if the render texture needs to be bound as a multisampled texture in a shader. |
RenderTextureDescriptor .colorFormat |
The format of the RenderTarget is expressed as a RenderTextureFormat. |
RenderTextureDescriptor .depthBufferBits |
The precision of the render texture's depth buffer in bits (0, 16, 24/32 are supported). |
RenderTextureDescriptor .dimension |
Dimensionality (type) of the render texture. |
RenderTextureDescriptor .enableRandomWrite |
Enable random access write into this render texture on Shader Model 5.0 level shaders. |
RenderTextureDescriptor .flags |
A set of RenderTextureCreationFlags that control how the texture is created. |
RenderTextureDescriptor .graphicsFormat |
The color format for the RenderTexture. |
RenderTextureDescriptor .height |
The height of the render texture in pixels. |
RenderTextureDescriptor .memoryless |
The render texture memoryless mode property. |
RenderTextureDescriptor .mipCount |
User-defined mipmap count. |
RenderTextureDescriptor .msaaSamples |
The multisample antialiasing level for the RenderTexture. |
RenderTextureDescriptor .shadowSamplingMode |
Determines how the RenderTexture is sampled if it is used as a shadow map. |
RenderTextureDescriptor .sRGB |
This flag causes the render texture uses sRGB read/write conversions. |
RenderTextureDescriptor .stencilFormat |
The format of the stencil data that you can encapsulate within a RenderTexture. |
RenderTextureDescriptor .useDynamicScale |
Set to true to enable dynamic resolution scaling on this render texture. |
RenderTextureDescriptor .useMipMap |
Render texture has mipmaps when this flag is set. |
RenderTextureDescriptor .volumeDepth |
Volume extent of a 3D render texture. |
RenderTextureDescriptor .width |
The width of the render texture in pixels. |
Constructor⚓︎
Name | Description |
---|---|
RenderTextureDescriptor(width, height) |
Create a RenderTextureDescriptor with default values. |