---
name: "SDL_SetGPUStencilReference"
section: "3"
platform: "linux"
package: "libsdl3-doc"
version: "3.2.10+ds-1"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/SDL_SetGPUStencilReference"
---

# SDL\_SetGPUStencilReference(3)

Sets the current stencil reference value on a command buffer.

## NAME

SDL\_SetGPUStencilReference - Sets the current stencil reference value on a command buffer.

## HEADER FILE

Defined in SDL3/SDL\_gpu.h

## SYNOPSIS

```
#include "SDL3/SDL.h"
```

**void SDL\_SetGPUStencilReference(**     **SDL\_GPURenderPass \*render\_pass,**     **Uint8 reference);**

## FUNCTION PARAMETERS

- *render\_pass*

  a render pass handle.

- *reference*

  the stencil reference value to set.

## AVAILABILITY

This function is available since SDL 3.2.0.
