Set the final presentation rectangle for rendering.
Defined in <SDL3/SDL_render.h>
bool SDL_SetRenderLogicalPresentationRect(SDL_Renderer *renderer, const SDL_FRect *rect);| SDL_Renderer * | renderer | the rendering context. |
| const SDL_FRect * | rect | the presentation rectangle, in pixels, or NULL to stretch to the full output size. |
(bool) Returns true on success or false on failure; call SDL_GetError() for more information.
This function sets the rectangle used when the logical presentation mode is SDL_LOGICAL_PRESENTATION_CUSTOM.
The logical size is scaled to fit the rectangle, so if the rectangle has a different aspect ratio than the logical size, the output will be stretched. The rectangle is in pixels and may extend past the edges of the output.
Each render target has its own logical presentation state. This function sets the rectangle for the current render target.
This function should only be called on the main thread.
This function is available since SDL 3.6.0.