Skip to content

Format

typescript
RenderTexture.depthType

class: RenderTexture

Description

(Read Only) The depth buffer format of the current rendering texture.

This method returns an enumeration type, for more details see DepthType.

Parameters

param_nametypedescription

Return

typedescription
DepthTypeDepthType enumeration value

Code Example

typescript
function Test() {
    try {
        let temp_texture = RenderTexture.GetTemporary(100, 100, RenderTextureFormat.Default, DepthType.Depth24Stencil8, AntiAliasingLevel.x8);
    } catch (error) {
        Debug.Log(error);
    }
}