Wiki Page Content

Differences between revisions 2 and 3
Revision 2 as of 2012-01-25 13:45:09
Size: 1011
Comment: Adding to CategoryRender
Revision 3 as of 2013-07-27 12:27:13
Size: 1012
Editor: axper
Comment: corrected vertical alignment of syntax
Deletions are marked like this. Additions are marked like this.
Line 12: Line 12:
                        SDL_Texture *texture)                         SDL_Texture  *texture)

SDL_SetRenderTarget

Set a texture as the current rendering target.

Syntax

int SDL_SetRenderTarget(SDL_Renderer *renderer,
                        SDL_Texture  *texture)

Function Parameters

renderer

the rendering context

texture

The targeted texture, which must be created with the SDL_TEXTUREACCESS_TARGET flag, or NULL for the default render target

Return Value

Returns 0 on success or a negative error code on failure; call SDL_GetError() for more information.

Code Examples

You can add your code example here

Remarks

Before using this function, you should check the SDL_RENDERER_TARGETTEXTURE bit in the flags of SDL_RendererInfo to see if render targets are supported.


CategoryAPI, CategoryRender


CategoryRender

None: SDL_SetRenderTarget (last edited 2016-05-11 20:37:00 by PhilippWiesemann)

(Page Info.)
Feedback
Please include your contact information if you'd like to receive a reply.
Submit