Wiki Page Content

Differences between revisions 1 and 2
Revision 1 as of 2009-12-14 06:40:21
Size: 1171
Editor: SheenaSmith
Comment: create page, add content
Revision 2 as of 2010-01-10 19:18:46
Size: 1251
Editor: SheenaSmith
Comment: added DRAFT to top for removal after page is edited
Deletions are marked like this. Additions are marked like this.
Line 3: Line 3:
||<tablewidth="100%"style="color: rgb(255, 0, 0); text-align: center;">DRAFT||

DRAFT

SDL_RenderReadPixels

Use this function to read pixels from the current rendering target.

Syntax

int SDL_RenderReadPixels(const SDL_Rect* rect,
                         Uint32          format,
                         void*           pixels,
                         int             pitch)

Function Parameters

rect

a pointer to the SDL_Rect to read, or NULL for the entire render target

format

the desired format of the pixel data, or 0 to use the format of the rendering target

pixels

a pointer to be filled in with the pixel data

pitch

the pitch of the pixels parameter

Return Value

Returns 0 on success or -1 if pixel reading is not supported; call SDL_GetError() for more information.

Code Examples

You can add your code example here

Remarks

WARNING: This is a very slow operation, and should not be used frequently.


CategoryAPI, CategoryVideo

None: SDL_RenderReadPixels (last edited 2020-04-29 20:50:08 by DanielG)

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