My Project
SDL_render.h
Go to the documentation of this file.
1 /*
2  Simple DirectMedia Layer
3  Copyright (C) 1997-2019 Sam Lantinga <slouken@libsdl.org>
4 
5  This software is provided 'as-is', without any express or implied
6  warranty. In no event will the authors be held liable for any damages
7  arising from the use of this software.
8 
9  Permission is granted to anyone to use this software for any purpose,
10  including commercial applications, and to alter it and redistribute it
11  freely, subject to the following restrictions:
12 
13  1. The origin of this software must not be misrepresented; you must not
14  claim that you wrote the original software. If you use this software
15  in a product, an acknowledgment in the product documentation would be
16  appreciated but is not required.
17  2. Altered source versions must be plainly marked as such, and must not be
18  misrepresented as being the original software.
19  3. This notice may not be removed or altered from any source distribution.
20 */
21 
48 #ifndef SDL_render_h_
49 #define SDL_render_h_
50 
51 #include "SDL_stdinc.h"
52 #include "SDL_rect.h"
53 #include "SDL_video.h"
54 
55 #include "begin_code.h"
56 /* Set up for C function definitions, even when using C++ */
57 #ifdef __cplusplus
58 extern "C" {
59 #endif
60 
64 typedef enum
65 {
66  SDL_RENDERER_SOFTWARE = 0x00000001,
67  SDL_RENDERER_ACCELERATED = 0x00000002,
74 
78 typedef struct SDL_RendererInfo
79 {
80  const char *name;
81  Uint32 flags;
83  Uint32 texture_formats[16];
87 
91 typedef enum
92 {
97 
101 typedef enum
102 {
107 
111 typedef enum
112 {
113  SDL_FLIP_NONE = 0x00000000,
114  SDL_FLIP_HORIZONTAL = 0x00000001,
115  SDL_FLIP_VERTICAL = 0x00000002
117 
121 struct SDL_Renderer;
122 typedef struct SDL_Renderer SDL_Renderer;
123 
127 struct SDL_Texture;
128 typedef struct SDL_Texture SDL_Texture;
129 
130 
131 /* Function prototypes */
132 
144 extern DECLSPEC int SDLCALL SDL_GetNumRenderDrivers(void);
145 
158 extern DECLSPEC int SDLCALL SDL_GetRenderDriverInfo(int index,
159  SDL_RendererInfo * info);
160 
172 extern DECLSPEC int SDLCALL SDL_CreateWindowAndRenderer(
173  int width, int height, Uint32 window_flags,
174  SDL_Window **window, SDL_Renderer **renderer);
175 
176 
191 extern DECLSPEC SDL_Renderer * SDLCALL SDL_CreateRenderer(SDL_Window * window,
192  int index, Uint32 flags);
193 
204 extern DECLSPEC SDL_Renderer * SDLCALL SDL_CreateSoftwareRenderer(SDL_Surface * surface);
205 
209 extern DECLSPEC SDL_Renderer * SDLCALL SDL_GetRenderer(SDL_Window * window);
210 
214 extern DECLSPEC int SDLCALL SDL_GetRendererInfo(SDL_Renderer * renderer,
215  SDL_RendererInfo * info);
216 
220 extern DECLSPEC int SDLCALL SDL_GetRendererOutputSize(SDL_Renderer * renderer,
221  int *w, int *h);
222 
242 extern DECLSPEC SDL_Texture * SDLCALL SDL_CreateTexture(SDL_Renderer * renderer,
243  Uint32 format,
244  int access, int w,
245  int h);
246 
260 extern DECLSPEC SDL_Texture * SDLCALL SDL_CreateTextureFromSurface(SDL_Renderer * renderer, SDL_Surface * surface);
261 
275 extern DECLSPEC int SDLCALL SDL_QueryTexture(SDL_Texture * texture,
276  Uint32 * format, int *access,
277  int *w, int *h);
278 
292 extern DECLSPEC int SDLCALL SDL_SetTextureColorMod(SDL_Texture * texture,
293  Uint8 r, Uint8 g, Uint8 b);
294 
295 
308 extern DECLSPEC int SDLCALL SDL_GetTextureColorMod(SDL_Texture * texture,
309  Uint8 * r, Uint8 * g,
310  Uint8 * b);
311 
323 extern DECLSPEC int SDLCALL SDL_SetTextureAlphaMod(SDL_Texture * texture,
324  Uint8 alpha);
325 
336 extern DECLSPEC int SDLCALL SDL_GetTextureAlphaMod(SDL_Texture * texture,
337  Uint8 * alpha);
338 
353 extern DECLSPEC int SDLCALL SDL_SetTextureBlendMode(SDL_Texture * texture,
354  SDL_BlendMode blendMode);
355 
366 extern DECLSPEC int SDLCALL SDL_GetTextureBlendMode(SDL_Texture * texture,
367  SDL_BlendMode *blendMode);
368 
385 extern DECLSPEC int SDLCALL SDL_UpdateTexture(SDL_Texture * texture,
386  const SDL_Rect * rect,
387  const void *pixels, int pitch);
388 
408 extern DECLSPEC int SDLCALL SDL_UpdateYUVTexture(SDL_Texture * texture,
409  const SDL_Rect * rect,
410  const Uint8 *Yplane, int Ypitch,
411  const Uint8 *Uplane, int Upitch,
412  const Uint8 *Vplane, int Vpitch);
413 
429 extern DECLSPEC int SDLCALL SDL_LockTexture(SDL_Texture * texture,
430  const SDL_Rect * rect,
431  void **pixels, int *pitch);
432 
438 extern DECLSPEC void SDLCALL SDL_UnlockTexture(SDL_Texture * texture);
439 
447 extern DECLSPEC SDL_bool SDLCALL SDL_RenderTargetSupported(SDL_Renderer *renderer);
448 
459 extern DECLSPEC int SDLCALL SDL_SetRenderTarget(SDL_Renderer *renderer,
460  SDL_Texture *texture);
461 
469 extern DECLSPEC SDL_Texture * SDLCALL SDL_GetRenderTarget(SDL_Renderer *renderer);
470 
494 extern DECLSPEC int SDLCALL SDL_RenderSetLogicalSize(SDL_Renderer * renderer, int w, int h);
495 
505 extern DECLSPEC void SDLCALL SDL_RenderGetLogicalSize(SDL_Renderer * renderer, int *w, int *h);
506 
519 extern DECLSPEC int SDLCALL SDL_RenderSetIntegerScale(SDL_Renderer * renderer,
520  SDL_bool enable);
521 
529 extern DECLSPEC SDL_bool SDLCALL SDL_RenderGetIntegerScale(SDL_Renderer * renderer);
530 
546 extern DECLSPEC int SDLCALL SDL_RenderSetViewport(SDL_Renderer * renderer,
547  const SDL_Rect * rect);
548 
554 extern DECLSPEC void SDLCALL SDL_RenderGetViewport(SDL_Renderer * renderer,
555  SDL_Rect * rect);
556 
568 extern DECLSPEC int SDLCALL SDL_RenderSetClipRect(SDL_Renderer * renderer,
569  const SDL_Rect * rect);
570 
580 extern DECLSPEC void SDLCALL SDL_RenderGetClipRect(SDL_Renderer * renderer,
581  SDL_Rect * rect);
582 
590 extern DECLSPEC SDL_bool SDLCALL SDL_RenderIsClipEnabled(SDL_Renderer * renderer);
591 
592 
611 extern DECLSPEC int SDLCALL SDL_RenderSetScale(SDL_Renderer * renderer,
612  float scaleX, float scaleY);
613 
623 extern DECLSPEC void SDLCALL SDL_RenderGetScale(SDL_Renderer * renderer,
624  float *scaleX, float *scaleY);
625 
638 extern DECLSPEC int SDLCALL SDL_SetRenderDrawColor(SDL_Renderer * renderer,
639  Uint8 r, Uint8 g, Uint8 b,
640  Uint8 a);
641 
654 extern DECLSPEC int SDLCALL SDL_GetRenderDrawColor(SDL_Renderer * renderer,
655  Uint8 * r, Uint8 * g, Uint8 * b,
656  Uint8 * a);
657 
671 extern DECLSPEC int SDLCALL SDL_SetRenderDrawBlendMode(SDL_Renderer * renderer,
672  SDL_BlendMode blendMode);
673 
684 extern DECLSPEC int SDLCALL SDL_GetRenderDrawBlendMode(SDL_Renderer * renderer,
685  SDL_BlendMode *blendMode);
686 
695 extern DECLSPEC int SDLCALL SDL_RenderClear(SDL_Renderer * renderer);
696 
706 extern DECLSPEC int SDLCALL SDL_RenderDrawPoint(SDL_Renderer * renderer,
707  int x, int y);
708 
718 extern DECLSPEC int SDLCALL SDL_RenderDrawPoints(SDL_Renderer * renderer,
719  const SDL_Point * points,
720  int count);
721 
733 extern DECLSPEC int SDLCALL SDL_RenderDrawLine(SDL_Renderer * renderer,
734  int x1, int y1, int x2, int y2);
735 
745 extern DECLSPEC int SDLCALL SDL_RenderDrawLines(SDL_Renderer * renderer,
746  const SDL_Point * points,
747  int count);
748 
757 extern DECLSPEC int SDLCALL SDL_RenderDrawRect(SDL_Renderer * renderer,
758  const SDL_Rect * rect);
759 
769 extern DECLSPEC int SDLCALL SDL_RenderDrawRects(SDL_Renderer * renderer,
770  const SDL_Rect * rects,
771  int count);
772 
782 extern DECLSPEC int SDLCALL SDL_RenderFillRect(SDL_Renderer * renderer,
783  const SDL_Rect * rect);
784 
794 extern DECLSPEC int SDLCALL SDL_RenderFillRects(SDL_Renderer * renderer,
795  const SDL_Rect * rects,
796  int count);
797 
810 extern DECLSPEC int SDLCALL SDL_RenderCopy(SDL_Renderer * renderer,
811  SDL_Texture * texture,
812  const SDL_Rect * srcrect,
813  const SDL_Rect * dstrect);
814 
830 extern DECLSPEC int SDLCALL SDL_RenderCopyEx(SDL_Renderer * renderer,
831  SDL_Texture * texture,
832  const SDL_Rect * srcrect,
833  const SDL_Rect * dstrect,
834  const double angle,
835  const SDL_Point *center,
836  const SDL_RendererFlip flip);
837 
838 
848 extern DECLSPEC int SDLCALL SDL_RenderDrawPointF(SDL_Renderer * renderer,
849  float x, float y);
850 
860 extern DECLSPEC int SDLCALL SDL_RenderDrawPointsF(SDL_Renderer * renderer,
861  const SDL_FPoint * points,
862  int count);
863 
875 extern DECLSPEC int SDLCALL SDL_RenderDrawLineF(SDL_Renderer * renderer,
876  float x1, float y1, float x2, float y2);
877 
887 extern DECLSPEC int SDLCALL SDL_RenderDrawLinesF(SDL_Renderer * renderer,
888  const SDL_FPoint * points,
889  int count);
890 
899 extern DECLSPEC int SDLCALL SDL_RenderDrawRectF(SDL_Renderer * renderer,
900  const SDL_FRect * rect);
901 
911 extern DECLSPEC int SDLCALL SDL_RenderDrawRectsF(SDL_Renderer * renderer,
912  const SDL_FRect * rects,
913  int count);
914 
924 extern DECLSPEC int SDLCALL SDL_RenderFillRectF(SDL_Renderer * renderer,
925  const SDL_FRect * rect);
926 
936 extern DECLSPEC int SDLCALL SDL_RenderFillRectsF(SDL_Renderer * renderer,
937  const SDL_FRect * rects,
938  int count);
939 
952 extern DECLSPEC int SDLCALL SDL_RenderCopyF(SDL_Renderer * renderer,
953  SDL_Texture * texture,
954  const SDL_Rect * srcrect,
955  const SDL_FRect * dstrect);
956 
972 extern DECLSPEC int SDLCALL SDL_RenderCopyExF(SDL_Renderer * renderer,
973  SDL_Texture * texture,
974  const SDL_Rect * srcrect,
975  const SDL_FRect * dstrect,
976  const double angle,
977  const SDL_FPoint *center,
978  const SDL_RendererFlip flip);
979 
995 extern DECLSPEC int SDLCALL SDL_RenderReadPixels(SDL_Renderer * renderer,
996  const SDL_Rect * rect,
997  Uint32 format,
998  void *pixels, int pitch);
999 
1003 extern DECLSPEC void SDLCALL SDL_RenderPresent(SDL_Renderer * renderer);
1004 
1011 extern DECLSPEC void SDLCALL SDL_DestroyTexture(SDL_Texture * texture);
1012 
1019 extern DECLSPEC void SDLCALL SDL_DestroyRenderer(SDL_Renderer * renderer);
1020 
1044 extern DECLSPEC int SDLCALL SDL_RenderFlush(SDL_Renderer * renderer);
1045 
1046 
1057 extern DECLSPEC int SDLCALL SDL_GL_BindTexture(SDL_Texture *texture, float *texw, float *texh);
1058 
1066 extern DECLSPEC int SDLCALL SDL_GL_UnbindTexture(SDL_Texture *texture);
1067 
1077 extern DECLSPEC void *SDLCALL SDL_RenderGetMetalLayer(SDL_Renderer * renderer);
1078 
1088 extern DECLSPEC void *SDLCALL SDL_RenderGetMetalCommandEncoder(SDL_Renderer * renderer);
1089 
1090 /* Ends C function definitions when using C++ */
1091 #ifdef __cplusplus
1092 }
1093 #endif
1094 #include "close_code.h"
1095 
1096 #endif /* SDL_render_h_ */
1097 
1098 /* vi: set ts=4 sw=4 expandtab: */
Definition: SDL_render.h:95
struct SDL_Window SDL_Window
The type used to identify a window.
Definition: SDL_video.h:90
DECLSPEC void *SDLCALL SDL_RenderGetMetalLayer(SDL_Renderer *renderer)
Get the CAMetalLayer associated with the given Metal renderer.
SDL_RendererFlip
Flip constants for SDL_RenderCopyEx.
Definition: SDL_render.h:111
DECLSPEC int SDLCALL SDL_GetRendererInfo(SDL_Renderer *renderer, SDL_RendererInfo *info)
Get information about a rendering context.
The structure that defines a point (floating point)
Definition: SDL_rect.h:60
DECLSPEC SDL_Renderer *SDLCALL SDL_CreateRenderer(SDL_Window *window, int index, Uint32 flags)
Create a 2D rendering context for a window.
Uint32 flags
Definition: SDL_render.h:81
DECLSPEC void SDLCALL SDL_RenderGetScale(SDL_Renderer *renderer, float *scaleX, float *scaleY)
Get the drawing scale for the current target.
DECLSPEC void SDLCALL SDL_RenderGetClipRect(SDL_Renderer *renderer, SDL_Rect *rect)
Get the clip rectangle for the current target.
DECLSPEC int SDLCALL SDL_LockTexture(SDL_Texture *texture, const SDL_Rect *rect, void **pixels, int *pitch)
Lock a portion of the texture for write-only pixel access.
DECLSPEC int SDLCALL SDL_GL_BindTexture(SDL_Texture *texture, float *texw, float *texh)
Bind the texture to the current OpenGL/ES/ES2 context for use with OpenGL instructions.
DECLSPEC int SDLCALL SDL_RenderDrawRect(SDL_Renderer *renderer, const SDL_Rect *rect)
Draw a rectangle on the current rendering target.
DECLSPEC int SDLCALL SDL_SetRenderDrawBlendMode(SDL_Renderer *renderer, SDL_BlendMode blendMode)
Set the blend mode used for drawing operations (Fill and Line).
DECLSPEC void SDLCALL SDL_RenderGetViewport(SDL_Renderer *renderer, SDL_Rect *rect)
Get the drawing area for the current target.
Definition: SDL_render.h:113
DECLSPEC int SDLCALL SDL_UpdateTexture(SDL_Texture *texture, const SDL_Rect *rect, const void *pixels, int pitch)
Update the given texture rectangle with new pixel data.
DECLSPEC int SDLCALL SDL_RenderDrawLineF(SDL_Renderer *renderer, float x1, float y1, float x2, float y2)
Draw a line on the current rendering target.
DECLSPEC int SDLCALL SDL_RenderCopyF(SDL_Renderer *renderer, SDL_Texture *texture, const SDL_Rect *srcrect, const SDL_FRect *dstrect)
Copy a portion of the texture to the current rendering target.
DECLSPEC int SDLCALL SDL_GL_UnbindTexture(SDL_Texture *texture)
Unbind a texture from the current OpenGL/ES/ES2 context.
DECLSPEC int SDLCALL SDL_UpdateYUVTexture(SDL_Texture *texture, const SDL_Rect *rect, const Uint8 *Yplane, int Ypitch, const Uint8 *Uplane, int Upitch, const Uint8 *Vplane, int Vpitch)
Update a rectangle within a planar YV12 or IYUV texture with new pixel data.
DECLSPEC int SDLCALL SDL_RenderSetScale(SDL_Renderer *renderer, float scaleX, float scaleY)
Set the drawing scale for rendering on the current target.
DECLSPEC SDL_Renderer *SDLCALL SDL_GetRenderer(SDL_Window *window)
Get the renderer associated with a window.
DECLSPEC int SDLCALL SDL_GetRendererOutputSize(SDL_Renderer *renderer, int *w, int *h)
Get the output size in pixels of a rendering context.
DECLSPEC void SDLCALL SDL_UnlockTexture(SDL_Texture *texture)
Unlock a texture, uploading the changes to video memory, if needed.
DECLSPEC void *SDLCALL SDL_RenderGetMetalCommandEncoder(SDL_Renderer *renderer)
Get the Metal command encoder for the current frame.
A rectangle, with the origin at the upper left (integer).
Definition: SDL_rect.h:77
DECLSPEC int SDLCALL SDL_RenderDrawLine(SDL_Renderer *renderer, int x1, int y1, int x2, int y2)
Draw a line on the current rendering target.
DECLSPEC int SDLCALL SDL_RenderDrawRectF(SDL_Renderer *renderer, const SDL_FRect *rect)
Draw a rectangle on the current rendering target.
DECLSPEC int SDLCALL SDL_RenderDrawLines(SDL_Renderer *renderer, const SDL_Point *points, int count)
Draw a series of connected lines on the current rendering target.
Definition: SDL_render.h:103
DECLSPEC int SDLCALL SDL_RenderSetViewport(SDL_Renderer *renderer, const SDL_Rect *rect)
Set the drawing area for rendering on the current target.
A collection of pixels used in software blitting.
Definition: SDL_surface.h:70
Definition: SDL_render.h:104
DECLSPEC int SDLCALL SDL_SetRenderTarget(SDL_Renderer *renderer, SDL_Texture *texture)
Set a texture as the current rendering target.
struct SDL_RendererInfo SDL_RendererInfo
Information on the capabilities of a render driver or context.
DECLSPEC int SDLCALL SDL_SetTextureAlphaMod(SDL_Texture *texture, Uint8 alpha)
Set an additional alpha value used in render copy operations.
DECLSPEC int SDLCALL SDL_RenderCopy(SDL_Renderer *renderer, SDL_Texture *texture, const SDL_Rect *srcrect, const SDL_Rect *dstrect)
Copy a portion of the texture to the current rendering target.
DECLSPEC SDL_bool SDLCALL SDL_RenderGetIntegerScale(SDL_Renderer *renderer)
Get whether integer scales are forced for resolution-independent rendering.
DECLSPEC int SDLCALL SDL_RenderDrawPoints(SDL_Renderer *renderer, const SDL_Point *points, int count)
Draw multiple points on the current rendering target.
DECLSPEC int SDLCALL SDL_RenderFillRect(SDL_Renderer *renderer, const SDL_Rect *rect)
Fill a rectangle on the current rendering target with the drawing color.
int max_texture_width
Definition: SDL_render.h:84
DECLSPEC int SDLCALL SDL_RenderFlush(SDL_Renderer *renderer)
Force the rendering context to flush any pending commands to the underlying rendering API...
DECLSPEC int SDLCALL SDL_GetTextureColorMod(SDL_Texture *texture, Uint8 *r, Uint8 *g, Uint8 *b)
Get the additional color value used in render copy operations.
DECLSPEC int SDLCALL SDL_RenderFillRectsF(SDL_Renderer *renderer, const SDL_FRect *rects, int count)
Fill some number of rectangles on the current rendering target with the drawing color.
DECLSPEC int SDLCALL SDL_RenderDrawRectsF(SDL_Renderer *renderer, const SDL_FRect *rects, int count)
Draw some number of rectangles on the current rendering target.
DECLSPEC int SDLCALL SDL_SetTextureBlendMode(SDL_Texture *texture, SDL_BlendMode blendMode)
Set the blend mode used for texture copy operations.
DECLSPEC SDL_bool SDLCALL SDL_RenderIsClipEnabled(SDL_Renderer *renderer)
Get whether clipping is enabled on the given renderer.
DECLSPEC int SDLCALL SDL_GetRenderDrawBlendMode(SDL_Renderer *renderer, SDL_BlendMode *blendMode)
Get the blend mode used for drawing operations.
DECLSPEC int SDLCALL SDL_RenderDrawRects(SDL_Renderer *renderer, const SDL_Rect *rects, int count)
Draw some number of rectangles on the current rendering target.
DECLSPEC void SDLCALL SDL_RenderGetLogicalSize(SDL_Renderer *renderer, int *w, int *h)
Get device independent resolution for rendering.
DECLSPEC SDL_Texture *SDLCALL SDL_CreateTexture(SDL_Renderer *renderer, Uint32 format, int access, int w, int h)
Create a texture for a rendering context.
Definition: SDL_render.h:67
DECLSPEC int SDLCALL SDL_RenderDrawLinesF(SDL_Renderer *renderer, const SDL_FPoint *points, int count)
Draw a series of connected lines on the current rendering target.
Definition: SDL_render.h:93
DECLSPEC SDL_Texture *SDLCALL SDL_CreateTextureFromSurface(SDL_Renderer *renderer, SDL_Surface *surface)
Create a texture from an existing surface.
DECLSPEC void SDLCALL SDL_RenderPresent(SDL_Renderer *renderer)
Update the screen with rendering performed.
DECLSPEC int SDLCALL SDL_RenderDrawPoint(SDL_Renderer *renderer, int x, int y)
Draw a point on the current rendering target.
DECLSPEC int SDLCALL SDL_GetTextureBlendMode(SDL_Texture *texture, SDL_BlendMode *blendMode)
Get the blend mode used for texture copy operations.
DECLSPEC SDL_bool SDLCALL SDL_RenderTargetSupported(SDL_Renderer *renderer)
Determines whether a window supports the use of render targets.
Definition: SDL_render.h:71
DECLSPEC int SDLCALL SDL_RenderClear(SDL_Renderer *renderer)
Clear the current rendering target with the drawing color.
SDL_TextureAccess
The access pattern allowed for a texture.
Definition: SDL_render.h:91
Definition: SDL_render.h:105
The structure that defines a point (integer)
Definition: SDL_rect.h:48
Definition: SDL_render.h:69
DECLSPEC int SDLCALL SDL_SetRenderDrawColor(SDL_Renderer *renderer, Uint8 r, Uint8 g, Uint8 b, Uint8 a)
Set the color used for drawing operations (Rect, Line and Clear).
Definition: SDL_render.h:114
DECLSPEC int SDLCALL SDL_RenderDrawPointsF(SDL_Renderer *renderer, const SDL_FPoint *points, int count)
Draw multiple points on the current rendering target.
Uint32 num_texture_formats
Definition: SDL_render.h:82
DECLSPEC int SDLCALL SDL_GetNumRenderDrivers(void)
Get the number of 2D rendering drivers available for the current display.
DECLSPEC SDL_Renderer *SDLCALL SDL_CreateSoftwareRenderer(SDL_Surface *surface)
Create a 2D software rendering context for a surface.
DECLSPEC int SDLCALL SDL_RenderDrawPointF(SDL_Renderer *renderer, float x, float y)
Draw a point on the current rendering target.
Information on the capabilities of a render driver or context.
Definition: SDL_render.h:78
Definition: SDL_render.h:115
DECLSPEC int SDLCALL SDL_GetRenderDrawColor(SDL_Renderer *renderer, Uint8 *r, Uint8 *g, Uint8 *b, Uint8 *a)
Get the color used for drawing operations (Rect, Line and Clear).
DECLSPEC int SDLCALL SDL_RenderSetIntegerScale(SDL_Renderer *renderer, SDL_bool enable)
Set whether to force integer scales for resolution-independent rendering.
DECLSPEC int SDLCALL SDL_QueryTexture(SDL_Texture *texture, Uint32 *format, int *access, int *w, int *h)
Query the attributes of a texture.
SDL_RendererFlags
Flags used when creating a rendering context.
Definition: SDL_render.h:64
SDL_BlendMode
The blend mode used in SDL_RenderCopy() and drawing operations.
Definition: SDL_blendmode.h:40
DECLSPEC void SDLCALL SDL_DestroyTexture(SDL_Texture *texture)
Destroy the specified texture.
DECLSPEC int SDLCALL SDL_RenderFillRectF(SDL_Renderer *renderer, const SDL_FRect *rect)
Fill a rectangle on the current rendering target with the drawing color.
DECLSPEC int SDLCALL SDL_RenderFillRects(SDL_Renderer *renderer, const SDL_Rect *rects, int count)
Fill some number of rectangles on the current rendering target with the drawing color.
DECLSPEC int SDLCALL SDL_RenderCopyExF(SDL_Renderer *renderer, SDL_Texture *texture, const SDL_Rect *srcrect, const SDL_FRect *dstrect, const double angle, const SDL_FPoint *center, const SDL_RendererFlip flip)
Copy a portion of the source texture to the current rendering target, rotating it by angle around the...
int max_texture_height
Definition: SDL_render.h:85
DECLSPEC int SDLCALL SDL_CreateWindowAndRenderer(int width, int height, Uint32 window_flags, SDL_Window **window, SDL_Renderer **renderer)
Create a window and default renderer.
DECLSPEC int SDLCALL SDL_GetRenderDriverInfo(int index, SDL_RendererInfo *info)
Get information about a specific 2D rendering driver for the current display.
DECLSPEC SDL_Texture *SDLCALL SDL_GetRenderTarget(SDL_Renderer *renderer)
Get the current render target or NULL for the default render target.
DECLSPEC int SDLCALL SDL_RenderSetClipRect(SDL_Renderer *renderer, const SDL_Rect *rect)
Set the clip rectangle for the current target.
const char * name
Definition: SDL_render.h:80
DECLSPEC int SDLCALL SDL_RenderSetLogicalSize(SDL_Renderer *renderer, int w, int h)
Set device independent resolution for rendering.
DECLSPEC void SDLCALL SDL_DestroyRenderer(SDL_Renderer *renderer)
Destroy the rendering context for a window and free associated textures.
Definition: SDL_render.h:94
SDL_TextureModulate
The texture channel modulation used in SDL_RenderCopy().
Definition: SDL_render.h:101
A rectangle, with the origin at the upper left (floating point).
Definition: SDL_rect.h:87
DECLSPEC int SDLCALL SDL_RenderCopyEx(SDL_Renderer *renderer, SDL_Texture *texture, const SDL_Rect *srcrect, const SDL_Rect *dstrect, const double angle, const SDL_Point *center, const SDL_RendererFlip flip)
Copy a portion of the source texture to the current rendering target, rotating it by angle around the...
Uint32 texture_formats[16]
Definition: SDL_render.h:83
DECLSPEC int SDLCALL SDL_RenderReadPixels(SDL_Renderer *renderer, const SDL_Rect *rect, Uint32 format, void *pixels, int pitch)
Read pixels from the current rendering target.
DECLSPEC int SDLCALL SDL_SetTextureColorMod(SDL_Texture *texture, Uint8 r, Uint8 g, Uint8 b)
Set an additional color value used in render copy operations.
DECLSPEC int SDLCALL SDL_GetTextureAlphaMod(SDL_Texture *texture, Uint8 *alpha)
Get the additional alpha value used in render copy operations.
Definition: SDL_render.h:66