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

# SDL\_GPURasterizerState(3type)

A structure specifying the parameters of the graphics pipeline rasterizer state.

## NAME

SDL\_GPURasterizerState - A structure specifying the parameters of the graphics pipeline rasterizer state.

## HEADER FILE

Defined in SDL3/SDL\_gpu.h

## SYNOPSIS

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

**typedef struct SDL\_GPURasterizerState** **{**     **SDL\_GPUFillMode fill\_mode;         /\*\*\< Whether polygons will be filled in or drawn as lines. \*/**     **SDL\_GPUCullMode cull\_mode;         /\*\*\< The facing direction in which triangles will be culled. \*/**     **SDL\_GPUFrontFace front\_face;       /\*\*\< The vertex winding that will cause a triangle to be determined as front-facing. \*/**     **float depth\_bias\_constant\_factor;  /\*\*\< A scalar factor controlling the depth value added to each fragment. \*/**     **float depth\_bias\_clamp;            /\*\*\< The maximum depth bias of a fragment. \*/**     **float depth\_bias\_slope\_factor;     /\*\*\< A scalar factor applied to a fragment's slope in depth calculations. \*/**     **bool enable\_depth\_bias;        /\*\*\< true to bias fragment depth values. \*/**     **bool enable\_depth\_clip;        /\*\*\< true to enable depth clip, false to enable depth clamp. \*/**     **Uint8 padding1;**     **Uint8 padding2;** **} SDL\_GPURasterizerState;**

## DESCRIPTION

Note that  **SDL\_GPU\_FILLMODE\_LINE**\
  is not supported on many Android devices. For those devices, the fill mode will automatically fall back to FILL.

Also note that the D3D12 driver will enable depth clamping even if enable\_depth\_clip is true. If you need this clamp+clip behavior, consider enabling depth clip and then manually clamping depth in your fragment shaders on Metal and Vulkan.

## AVAILABILITY

This struct is available since SDL 3.2.0.

## SEE ALSO

**•**(3), [**SDL\_GPUGraphicsPipelineCreateInfo**(3type)](/SDL_GPUGraphicsPipelineCreateInfo/3type.md)
