# Depth

> A depth render texture format.

## Definition

* **Type:** Field
* **Namespace:** [UnityEngine](/engine/6000.5/script-reference/unityengine.md)
* **Assembly:** UnityEngine.CoreModule

```csharp
Depth = 1
```

### Remarks

Depth format is used to render high precision "depth" value into a render texture. Which format is actually used depends on platform support and on the number of depth bits you request through the constructor.

You can also set an exact depth-stencil format with [RenderTexture.depthStencilFormat](/engine/6000.5/script-reference/unityengine/rendertexture/depthstencilformat.md) or a [RenderTexture](/engine/6000.5/script-reference/unityengine/rendertexture.md) constructor that takes [GraphicsFormat](/engine/6000.5/script-reference/unityengine/experimental/rendering/graphicsformat.md). Use [SystemInfo.IsFormatSupported](/engine/6000.5/script-reference/unityengine/systeminfo/isformatsupported.md) to check your platform supports this.

When writing shaders that use or render into a depth texture, care must be taken to ensure that they work both on OpenGL and on Direct3D, see [depth textures documentation](/engine/6000.5/manual/cameras/camera-output/sl-camera-depth-texture.md).

Note that not all graphics cards support depth textures. Use [SystemInfo.SupportsRenderTextureFormat](/engine/6000.5/script-reference/unityengine/systeminfo/supportsrendertextureformat.md) to check for support.

Additional Resources: [RenderTexture](/engine/6000.5/script-reference/unityengine/rendertexture.md) class, [SystemInfo.SupportsRenderTextureFormat](/engine/6000.5/script-reference/unityengine/systeminfo/supportsrendertextureformat.md).
