---
name: "SDL_GetRendererProperties"
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_GetRendererProperties"
---

# SDL\_GetRendererProperties(3)

Get the properties associated with a renderer.

## NAME

SDL\_GetRendererProperties - Get the properties associated with a renderer.

## HEADER FILE

Defined in SDL3/SDL\_render.h

## SYNOPSIS

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

**SDL\_PropertiesID SDL\_GetRendererProperties(SDL\_Renderer \*renderer);**

## DESCRIPTION

The following read-only properties are provided by SDL:

•  **SDL\_PROP\_RENDERER\_NAME\_STRING** : the\
   name of the rendering driver

•  **SDL\_PROP\_RENDERER\_WINDOW\_POINTER** :\
   the window where rendering is displayed, if any

•  **SDL\_PROP\_RENDERER\_SURFACE\_POINTER** :\
   the surface where rendering is displayed, if this is a software renderer\
   without a window

•  **SDL\_PROP\_RENDERER\_VSYNC\_NUMBER** : the\
   current vsync setting

•  **SDL\_PROP\_RENDERER\_MAX\_TEXTURE\_SIZE\_NUMBER** :\
   the maximum texture width and height

•  **SDL\_PROP\_RENDERER\_TEXTURE\_FORMATS\_POINTER** :\
   a (const  **SDL\_PixelFormat**\
  \*) array of pixel formats,\
   terminated with  **SDL\_PIXELFORMAT\_UNKNOWN** ,\
   representing the available texture formats for this renderer.

•  **SDL\_PROP\_RENDERER\_OUTPUT\_COLORSPACE\_NUMBER** :\
   an  **SDL\_Colorspace**\
  value describing the colorspace for\
   output to the display, defaults to

**SDL\_COLORSPACE\_SRGB** .

•  **SDL\_PROP\_RENDERER\_HDR\_ENABLED\_BOOLEAN** :\
   true if the output colorspace is

**SDL\_COLORSPACE\_SRGB\_LINEAR**\
  and the renderer\
   is showing on a display with HDR enabled. This property can change\
   dynamically when

**SDL\_EVENT\_WINDOW\_HDR\_STATE\_CHANGED**

  is sent.

•  **SDL\_PROP\_RENDERER\_SDR\_WHITE\_POINT\_FLOAT** :\
   the value of SDR white in the

**SDL\_COLORSPACE\_SRGB\_LINEAR**\
  colorspace. When\
   HDR is enabled, this value is automatically multiplied into the color\
   scale. This property can change dynamically when

**SDL\_EVENT\_WINDOW\_HDR\_STATE\_CHANGED**

  is sent.

•  **SDL\_PROP\_RENDERER\_HDR\_HEADROOM\_FLOAT** :\
   the additional high dynamic range that can be displayed, in terms of the\
   SDR white point. When HDR is not enabled, this will be 1.0. This property\
   can change dynamically when

**SDL\_EVENT\_WINDOW\_HDR\_STATE\_CHANGED**

  is sent.

With the direct3d renderer:

•  **SDL\_PROP\_RENDERER\_D3D9\_DEVICE\_POINTER** :\
   the IDirect3DDevice9 associated with the renderer

With the direct3d11 renderer:

•  **SDL\_PROP\_RENDERER\_D3D11\_DEVICE\_POINTER** :\
   the ID3D11Device associated with the renderer

•  **SDL\_PROP\_RENDERER\_D3D11\_SWAPCHAIN\_POINTER** :\
   the IDXGISwapChain1 associated with the renderer. This may change when\
   the window is resized.

With the direct3d12 renderer:

•  **SDL\_PROP\_RENDERER\_D3D12\_DEVICE\_POINTER** :\
   the ID3D12Device associated with the renderer

•  **SDL\_PROP\_RENDERER\_D3D12\_SWAPCHAIN\_POINTER** :\
   the IDXGISwapChain4 associated with the renderer.

•  **SDL\_PROP\_RENDERER\_D3D12\_COMMAND\_QUEUE\_POINTER** :\
   the ID3D12CommandQueue associated with the renderer

With the vulkan renderer:

•  **SDL\_PROP\_RENDERER\_VULKAN\_INSTANCE\_POINTER** :\
   the VkInstance associated with the renderer

•  **SDL\_PROP\_RENDERER\_VULKAN\_SURFACE\_NUMBER** :\
   the VkSurfaceKHR associated with the renderer

•  **SDL\_PROP\_RENDERER\_VULKAN\_PHYSICAL\_DEVICE\_POINTER** :\
   the VkPhysicalDevice associated with the renderer

•  **SDL\_PROP\_RENDERER\_VULKAN\_DEVICE\_POINTER** :\
   the VkDevice associated with the renderer

•  **SDL\_PROP\_RENDERER\_VULKAN\_GRAPHICS\_QUEUE\_FAMILY\_INDEX\_NUMBER** :\
   the queue family index used for rendering

•  **SDL\_PROP\_RENDERER\_VULKAN\_PRESENT\_QUEUE\_FAMILY\_INDEX\_NUMBER** :\
   the queue family index used for presentation

•  **SDL\_PROP\_RENDERER\_VULKAN\_SWAPCHAIN\_IMAGE\_COUNT\_NUMBER** :\
   the number of swapchain images, or potential frames in flight, used by\
   the Vulkan renderer

With the gpu renderer:

•  **SDL\_PROP\_RENDERER\_GPU\_DEVICE\_POINTER** :\
   the  **SDL\_GPUDevice**\
  associated with the renderer

## FUNCTION PARAMETERS

- *renderer*

  the rendering context.

## RETURN VALUE

( **SDL\_PropertiesID** ) Returns a valid property ID on success or 0 on failure; call  **SDL\_GetError** () for more information.

## THREAD SAFETY

It is safe to call this function from any thread.

## AVAILABILITY

This function is available since SDL 3.2.0.
