4#ifndef _USE_MATH_DEFINES
5#define _USE_MATH_DEFINES
14#include "begin_code.h"
21#include "SDL_gpu_version.h"
24#if SDL_VERSION_ATLEAST(2,0,0)
25 #define SDL_GPU_USE_SDL2
27 #define SDL_GPU_USE_SDL1
32#ifdef __STDC_VERSION__
33 #define GPU_HAVE_STDC 1
35 #define GPU_HAVE_STDC 0
38#define GPU_HAVE_C99 (GPU_HAVE_STDC && (__STDC_VERSION__ >= 199901L))
41 #define GPU_HAVE_GNUC 1
43 #define GPU_HAVE_GNUC 0
47 #define GPU_HAVE_MSVC 1
49 #define GPU_HAVE_MSVC 0
52#define GPU_HAVE_MSVC18 (GPU_HAVE_MSVC && (_MSC_VER >= 1800))
54#if defined(GPU_USE_REAL_BOOL) && GPU_USE_REAL_BOOL
56#elif defined(GPU_USE_INT_BOOL) && GPU_USE_INT_BOOL
58#elif GPU_HAVE_C99 || GPU_HAVE_GNUC || GPU_HAVE_MSVC18 || (defined(GPU_HAVE_STDBOOL) && GPU_HAVE_STDBOOL)
65#if defined(_MSC_VER) || (defined(__INTEL_COMPILER) && defined(_WIN32))
67 #define SDL_GPU_BITNESS 64
69 #define SDL_GPU_BITNESS 32
71 #define SDL_GPU_LONG_SIZE 4
72#elif defined(__clang__) || defined(__INTEL_COMPILER) || defined(__GNUC__)
74 #define SDL_GPU_BITNESS 64
76 #define SDL_GPU_BITNESS 32
78 #if __LONG_MAX__ == 2147483647L
79 #define SDL_GPU_LONG_SIZE 4
81 #define SDL_GPU_LONG_SIZE 8
86#if SDL_GPU_BITNESS == 32
87#define GPU_PAD_1_TO_32 char _padding[1];
88#define GPU_PAD_2_TO_32 char _padding[2];
89#define GPU_PAD_3_TO_32 char _padding[3];
90#define GPU_PAD_1_TO_64 char _padding[1];
91#define GPU_PAD_2_TO_64 char _padding[2];
92#define GPU_PAD_3_TO_64 char _padding[3];
93#define GPU_PAD_4_TO_64
94#define GPU_PAD_5_TO_64 char _padding[1];
95#define GPU_PAD_6_TO_64 char _padding[2];
96#define GPU_PAD_7_TO_64 char _padding[3];
97#elif SDL_GPU_BITNESS == 64
98#define GPU_PAD_1_TO_32 char _padding[1];
99#define GPU_PAD_2_TO_32 char _padding[2];
100#define GPU_PAD_3_TO_32 char _padding[3];
101#define GPU_PAD_1_TO_64 char _padding[1];
102#define GPU_PAD_2_TO_64 char _padding[2];
103#define GPU_PAD_3_TO_64 char _padding[3];
104#define GPU_PAD_4_TO_64 char _padding[4];
105#define GPU_PAD_5_TO_64 char _padding[5];
106#define GPU_PAD_6_TO_64 char _padding[6];
107#define GPU_PAD_7_TO_64 char _padding[7];
143#define GPU_RENDERER_ORDER_MAX 10
145typedef Uint32 GPU_RendererEnum;
146static const GPU_RendererEnum GPU_RENDERER_UNKNOWN = 0;
147static const GPU_RendererEnum GPU_RENDERER_OPENGL_1_BASE = 1;
148static const GPU_RendererEnum GPU_RENDERER_OPENGL_1 = 2;
149static const GPU_RendererEnum GPU_RENDERER_OPENGL_2 = 3;
150static const GPU_RendererEnum GPU_RENDERER_OPENGL_3 = 4;
151static const GPU_RendererEnum GPU_RENDERER_OPENGL_4 = 5;
152static const GPU_RendererEnum GPU_RENDERER_GLES_1 = 11;
153static const GPU_RendererEnum GPU_RENDERER_GLES_2 = 12;
154static const GPU_RendererEnum GPU_RENDERER_GLES_3 = 13;
155static const GPU_RendererEnum GPU_RENDERER_D3D9 = 21;
156static const GPU_RendererEnum GPU_RENDERER_D3D10 = 22;
157static const GPU_RendererEnum GPU_RENDERER_D3D11 = 23;
158#define GPU_RENDERER_CUSTOM_0 1000
170 GPU_RendererEnum renderer;
188 GPU_GREATER = 0x0204,
189 GPU_NOTEQUAL = 0x0205,
203 GPU_FUNC_SRC_COLOR = 0x0300,
204 GPU_FUNC_DST_COLOR = 0x0306,
205 GPU_FUNC_ONE_MINUS_SRC = 0x0301,
206 GPU_FUNC_ONE_MINUS_DST = 0x0307,
207 GPU_FUNC_SRC_ALPHA = 0x0302,
208 GPU_FUNC_DST_ALPHA = 0x0304,
209 GPU_FUNC_ONE_MINUS_SRC_ALPHA = 0x0303,
210 GPU_FUNC_ONE_MINUS_DST_ALPHA = 0x0305
220 GPU_EQ_SUBTRACT = 0x800A,
221 GPU_EQ_REVERSE_SUBTRACT = 0x800B
243 GPU_BLEND_NORMAL = 0,
244 GPU_BLEND_PREMULTIPLIED_ALPHA = 1,
245 GPU_BLEND_MULTIPLY = 2,
247 GPU_BLEND_SUBTRACT = 4,
248 GPU_BLEND_MOD_ALPHA = 5,
249 GPU_BLEND_SET_ALPHA = 6,
251 GPU_BLEND_NORMAL_KEEP_ALPHA = 8,
252 GPU_BLEND_NORMAL_ADD_ALPHA = 9,
253 GPU_BLEND_NORMAL_FACTOR_ALPHA = 10
261 GPU_FILTER_NEAREST = 0,
262 GPU_FILTER_LINEAR = 1,
263 GPU_FILTER_LINEAR_MIPMAP = 2
273 GPU_SNAP_POSITION = 1,
274 GPU_SNAP_DIMENSIONS = 2,
275 GPU_SNAP_POSITION_AND_DIMENSIONS = 3
286 GPU_WRAP_MIRRORED = 2
294 GPU_FORMAT_LUMINANCE = 1,
295 GPU_FORMAT_LUMINANCE_ALPHA = 2,
298 GPU_FORMAT_ALPHA = 5,
300 GPU_FORMAT_YCbCr422 = 7,
301 GPU_FORMAT_YCbCr420P = 8,
303 GPU_FORMAT_BGRA = 10,
344 Uint16 base_w, base_h;
345 Uint16 texture_w, texture_h;
359 GPU_bool using_virtual_resolution;
360 GPU_bool has_mipmaps;
361 GPU_bool use_blending;
383 float zoom_x, zoom_y;
385 GPU_bool use_centered_origin;
403 int modelViewProjection_loc;
412#define GPU_PROJECTION 2
418 unsigned int storage_size;
456 Uint32 default_textured_fragment_shader_id;
457 Uint32 default_untextured_vertex_shader_id;
458 Uint32 default_untextured_fragment_shader_id;
464 Uint32 default_textured_shader_program;
465 Uint32 default_untextured_shader_program;
468 float line_thickness;
475 GPU_bool use_texturing;
476 GPU_bool shapes_use_blending;
499 Uint16 base_w, base_h;
513 GPU_bool using_virtual_resolution;
514 GPU_bool use_clip_rect;
525 GPU_bool use_depth_test;
526 GPU_bool use_depth_write;
542static const GPU_FeatureEnum GPU_FEATURE_BLEND_EQUATIONS_SEPARATE = 0x10;
551static const GPU_FeatureEnum GPU_FEATURE_CORE_FRAMEBUFFER_OBJECTS = 0x1000;
554#define GPU_FEATURE_ALL_BASE GPU_FEATURE_RENDER_TARGETS
555#define GPU_FEATURE_ALL_BLEND_PRESETS (GPU_FEATURE_BLEND_EQUATIONS | GPU_FEATURE_BLEND_FUNC_SEPARATE)
556#define GPU_FEATURE_ALL_GL_FORMATS (GPU_FEATURE_GL_BGR | GPU_FEATURE_GL_BGRA | GPU_FEATURE_GL_ABGR)
557#define GPU_FEATURE_BASIC_SHADERS (GPU_FEATURE_FRAGMENT_SHADER | GPU_FEATURE_VERTEX_SHADER)
558#define GPU_FEATURE_ALL_SHADERS (GPU_FEATURE_FRAGMENT_SHADER | GPU_FEATURE_VERTEX_SHADER | GPU_FEATURE_GEOMETRY_SHADER)
561typedef Uint32 GPU_WindowFlagEnum;
573static const GPU_InitFlagEnum GPU_INIT_DISABLE_AUTO_VIRTUAL_RESOLUTION = 0x8;
575static const GPU_InitFlagEnum GPU_INIT_USE_ROW_BY_ROW_TEXTURE_UPLOAD_FALLBACK = 0x20;
576static const GPU_InitFlagEnum GPU_INIT_USE_COPY_TEXTURE_UPLOAD_FALLBACK = 0x40;
578#define GPU_DEFAULT_INIT_FLAGS 0
581static const Uint32 GPU_NONE = 0x0;
604typedef Uint32 GPU_BatchFlagEnum;
605static const GPU_BatchFlagEnum GPU_BATCH_XY = 0x1;
606static const GPU_BatchFlagEnum GPU_BATCH_XYZ = 0x2;
607static const GPU_BatchFlagEnum GPU_BATCH_ST = 0x4;
608static const GPU_BatchFlagEnum GPU_BATCH_RGB = 0x8;
609static const GPU_BatchFlagEnum GPU_BATCH_RGBA = 0x10;
610static const GPU_BatchFlagEnum GPU_BATCH_RGB8 = 0x20;
611static const GPU_BatchFlagEnum GPU_BATCH_RGBA8 = 0x40;
613#define GPU_BATCH_XY_ST (GPU_BATCH_XY | GPU_BATCH_ST)
614#define GPU_BATCH_XYZ_ST (GPU_BATCH_XYZ | GPU_BATCH_ST)
615#define GPU_BATCH_XY_RGB (GPU_BATCH_XY | GPU_BATCH_RGB)
616#define GPU_BATCH_XYZ_RGB (GPU_BATCH_XYZ | GPU_BATCH_RGB)
617#define GPU_BATCH_XY_RGBA (GPU_BATCH_XY | GPU_BATCH_RGBA)
618#define GPU_BATCH_XYZ_RGBA (GPU_BATCH_XYZ | GPU_BATCH_RGBA)
619#define GPU_BATCH_XY_ST_RGBA (GPU_BATCH_XY | GPU_BATCH_ST | GPU_BATCH_RGBA)
620#define GPU_BATCH_XYZ_ST_RGBA (GPU_BATCH_XYZ | GPU_BATCH_ST | GPU_BATCH_RGBA)
621#define GPU_BATCH_XY_RGB8 (GPU_BATCH_XY | GPU_BATCH_RGB8)
622#define GPU_BATCH_XYZ_RGB8 (GPU_BATCH_XYZ | GPU_BATCH_RGB8)
623#define GPU_BATCH_XY_RGBA8 (GPU_BATCH_XY | GPU_BATCH_RGBA8)
624#define GPU_BATCH_XYZ_RGBA8 (GPU_BATCH_XYZ | GPU_BATCH_RGBA8)
625#define GPU_BATCH_XY_ST_RGBA8 (GPU_BATCH_XY | GPU_BATCH_ST | GPU_BATCH_RGBA8)
626#define GPU_BATCH_XYZ_ST_RGBA8 (GPU_BATCH_XYZ | GPU_BATCH_ST | GPU_BATCH_RGBA8)
633typedef Uint32 GPU_FlipEnum;
634static const GPU_FlipEnum GPU_FLIP_NONE = 0x0;
635static const GPU_FlipEnum GPU_FLIP_HORIZONTAL = 0x1;
636static const GPU_FlipEnum GPU_FLIP_VERTICAL = 0x2;
645static const GPU_TypeEnum GPU_TYPE_UNSIGNED_BYTE = 0x1401;
647static const GPU_TypeEnum GPU_TYPE_UNSIGNED_SHORT = 0x1403;
649static const GPU_TypeEnum GPU_TYPE_UNSIGNED_INT = 0x1405;
665 GPU_VERTEX_SHADER = 0,
666 GPU_FRAGMENT_SHADER = 1,
667 GPU_PIXEL_SHADER = 1,
668 GPU_GEOMETRY_SHADER = 2
677 GPU_LANGUAGE_NONE = 0,
678 GPU_LANGUAGE_ARB_ASSEMBLY = 1,
679 GPU_LANGUAGE_GLSL = 2,
680 GPU_LANGUAGE_GLSLES = 3,
681 GPU_LANGUAGE_HLSL = 4,
688 int num_elems_per_value;
692 GPU_bool is_per_sprite;
712 void* per_vertex_storage;
716 int per_vertex_storage_stride_bytes;
717 int per_vertex_storage_offset_bytes;
718 int per_vertex_storage_size;
733 GPU_ERROR_BACKEND_ERROR = 1,
734 GPU_ERROR_DATA_ERROR = 2,
735 GPU_ERROR_USER_ERROR = 3,
736 GPU_ERROR_UNSUPPORTED_FUNCTION = 4,
737 GPU_ERROR_NULL_ARGUMENT = 5,
738 GPU_ERROR_FILE_NOT_FOUND = 6
758 GPU_DEBUG_LEVEL_0 = 0,
759 GPU_DEBUG_LEVEL_1 = 1,
760 GPU_DEBUG_LEVEL_2 = 2,
761 GPU_DEBUG_LEVEL_3 = 3,
762 GPU_DEBUG_LEVEL_MAX = 3
786 GPU_WindowFlagEnum SDL_init_flags;
790 int min_shader_version;
791 int max_shader_version;
799 float default_image_anchor_y;
819static SDL_version SDLCALL GPU_GetCompiledVersion(
void)
821static inline SDL_version SDLCALL GPU_GetCompiledVersion(
void)
824 SDL_version v = {SDL_GPU_VERSION_MAJOR, SDL_GPU_VERSION_MINOR, SDL_GPU_VERSION_PATCH};
828DECLSPEC SDL_version SDLCALL GPU_GetLinkedVersion(
void);
882DECLSPEC
GPU_Target* SDLCALL
GPU_Init(Uint16 w, Uint16 h, GPU_WindowFlagEnum SDL_flags);
885DECLSPEC
GPU_Target* SDLCALL
GPU_InitRenderer(GPU_RendererEnum renderer_enum, Uint16 w, Uint16 h, GPU_WindowFlagEnum SDL_flags);
903DECLSPEC
void SDLCALL
GPU_Quit(
void);
912#define GPU_Log GPU_LogInfo
928DECLSPEC
void SDLCALL
GPU_LogInfo(
const char* format, ...);
934DECLSPEC
void SDLCALL
GPU_LogError(
const char* format, ...);
1008DECLSPEC
void SDLCALL GPU_FreeRenderer(
GPU_Renderer* renderer);
1018DECLSPEC GPU_bool SDLCALL GPU_GetCoordinateMode(
void);
1065DECLSPEC GPU_bool SDLCALL
GPU_SetFullscreen(GPU_bool enable_fullscreen, GPU_bool use_desktop_resolution);
1241DECLSPEC SDL_Surface* SDLCALL
GPU_LoadSurface_RW(SDL_RWops* rwops, GPU_bool free_rwops);
1407DECLSPEC
float SDLCALL
GPU_VectorDot(
const float* A,
const float* B);
1410DECLSPEC
void SDLCALL
GPU_VectorCross(
float* result,
const float* A,
const float* B);
1413DECLSPEC
void SDLCALL
GPU_VectorCopy(
float* result,
const float* A);
1426DECLSPEC
void SDLCALL
GPU_MatrixCopy(
float* result,
const float* A);
1432DECLSPEC
void SDLCALL
GPU_MatrixOrtho(
float* result,
float left,
float right,
float bottom,
float top,
float z_near,
float z_far);
1435DECLSPEC
void SDLCALL
GPU_MatrixFrustum(
float* result,
float left,
float right,
float bottom,
float top,
float z_near,
float z_far);
1438DECLSPEC
void SDLCALL
GPU_MatrixPerspective(
float* result,
float fovy,
float aspect,
float z_near,
float z_far);
1441DECLSPEC
void SDLCALL
GPU_MatrixLookAt(
float* matrix,
float eye_x,
float eye_y,
float eye_z,
float target_x,
float target_y,
float target_z,
float up_x,
float up_y,
float up_z);
1447DECLSPEC
void SDLCALL
GPU_MatrixScale(
float* result,
float sx,
float sy,
float sz);
1450DECLSPEC
void SDLCALL
GPU_MatrixRotate(
float* result,
float degrees,
float x,
float y,
float z);
1455DECLSPEC
void SDLCALL
GPU_MatrixMultiply(
float* result,
const float* A,
const float* B);
1539DECLSPEC
void SDLCALL
GPU_Ortho(
float left,
float right,
float bottom,
float top,
float z_near,
float z_far);
1542DECLSPEC
void SDLCALL
GPU_Frustum(
float left,
float right,
float bottom,
float top,
float z_near,
float z_far);
1545DECLSPEC
void SDLCALL
GPU_Perspective(
float fovy,
float aspect,
float z_near,
float z_far);
1548DECLSPEC
void SDLCALL
GPU_LookAt(
float eye_x,
float eye_y,
float eye_z,
float target_x,
float target_y,
float target_z,
float up_x,
float up_y,
float up_z);
1551DECLSPEC
void SDLCALL
GPU_Translate(
float x,
float y,
float z);
1554DECLSPEC
void SDLCALL
GPU_Scale(
float sx,
float sy,
float sz);
1557DECLSPEC
void SDLCALL
GPU_Rotate(
float degrees,
float x,
float y,
float z);
1648DECLSPEC
void SDLCALL
GPU_TriangleBatch(
GPU_Image* image,
GPU_Target* target,
unsigned short num_vertices,
float* values,
unsigned int num_indices,
unsigned short* indices, GPU_BatchFlagEnum flags);
1655DECLSPEC
void SDLCALL
GPU_TriangleBatchX(
GPU_Image* image,
GPU_Target* target,
unsigned short num_vertices,
void* values,
unsigned int num_indices,
unsigned short* indices, GPU_BatchFlagEnum flags);
1716DECLSPEC
void SDLCALL
GPU_Arc(
GPU_Target* target,
float x,
float y,
float radius,
float start_angle,
float end_angle,
SDL_Color color);
1779DECLSPEC
void SDLCALL
GPU_Sector(
GPU_Target* target,
float x,
float y,
float inner_radius,
float outer_radius,
float start_angle,
float end_angle,
SDL_Color color);
1803DECLSPEC
void SDLCALL
GPU_Tri(
GPU_Target* target,
float x1,
float y1,
float x2,
float y2,
float x3,
float y3,
SDL_Color color);
2010DECLSPEC
void SDLCALL
GPU_SetUniformiv(
int location,
int num_elements_per_value,
int num_values,
int* values);
2020DECLSPEC
void SDLCALL
GPU_SetUniformuiv(
int location,
int num_elements_per_value,
int num_values,
unsigned int* values);
2030DECLSPEC
void SDLCALL
GPU_SetUniformfv(
int location,
int num_elements_per_value,
int num_values,
float* values);
2036DECLSPEC
void SDLCALL
GPU_SetUniformMatrixfv(
int location,
int num_matrices,
int num_rows,
int num_columns, GPU_bool transpose,
float* values);
2048DECLSPEC
void SDLCALL
GPU_SetAttributefv(
int location,
int num_elements,
float* value);
2054DECLSPEC
void SDLCALL
GPU_SetAttributeuiv(
int location,
int num_elements,
unsigned int* value);
2067#include "close_code.h"
DECLSPEC float SDLCALL GPU_GetLineThickness(void)
Definition: SDL_gpu_shapes.c:29
DECLSPEC GPU_bool SDLCALL GPU_SetFullscreen(GPU_bool enable_fullscreen, GPU_bool use_desktop_resolution)
Definition: SDL_gpu.c:512
DECLSPEC void SDLCALL GPU_SetShapeBlendEquation(GPU_BlendEqEnum color_equation, GPU_BlendEqEnum alpha_equation)
Definition: SDL_gpu.c:1949
DECLSPEC GPU_Target *SDLCALL GPU_GetActiveTarget(void)
Definition: SDL_gpu.c:536
DECLSPEC float SDLCALL GPU_SetLineThickness(float thickness)
Definition: SDL_gpu_shapes.c:23
DECLSPEC void SDLCALL GPU_SetShapeBlendFunction(GPU_BlendFuncEnum source_color, GPU_BlendFuncEnum dest_color, GPU_BlendFuncEnum source_alpha, GPU_BlendFuncEnum dest_alpha)
Definition: SDL_gpu.c:1935
DECLSPEC GPU_Target *SDLCALL GPU_GetWindowTarget(Uint32 windowID)
Definition: SDL_gpu.c:390
DECLSPEC GPU_bool SDLCALL GPU_GetFullscreen(void)
Definition: SDL_gpu.c:520
DECLSPEC GPU_bool SDLCALL GPU_SetActiveTarget(GPU_Target *target)
Definition: SDL_gpu.c:545
DECLSPEC GPU_BlendMode SDLCALL GPU_GetBlendModeFromPreset(GPU_BlendPresetEnum preset)
Definition: SDL_gpu.c:1820
DECLSPEC GPU_Target *SDLCALL GPU_CreateTargetFromWindow(Uint32 windowID)
Definition: SDL_gpu.c:483
DECLSPEC void SDLCALL GPU_SetShapeBlendMode(GPU_BlendPresetEnum mode)
Definition: SDL_gpu.c:1961
DECLSPEC void SDLCALL GPU_SetShapeBlending(GPU_bool enable)
Definition: SDL_gpu.c:1811
DECLSPEC void SDLCALL GPU_MakeCurrent(GPU_Target *target, Uint32 windowID)
Definition: SDL_gpu.c:504
DECLSPEC GPU_bool SDLCALL GPU_SetWindowResolution(Uint16 w, Uint16 h)
Definition: SDL_gpu.c:579
DECLSPEC GPU_Target *SDLCALL GPU_GetContextTarget(void)
Definition: SDL_gpu.c:1360
DECLSPEC GPU_Image *SDLCALL GPU_CopyImageFromSurface(SDL_Surface *surface)
Definition: SDL_gpu.c:1305
DECLSPEC SDL_Surface *SDLCALL GPU_CopySurfaceFromTarget(GPU_Target *target)
Definition: SDL_gpu.c:1332
DECLSPEC GPU_Image *SDLCALL GPU_CopyImageFromSurfaceRect(SDL_Surface *surface, GPU_Rect *surface_rect)
Definition: SDL_gpu.c:1313
DECLSPEC SDL_Surface *SDLCALL GPU_CopySurfaceFromImage(GPU_Image *image)
Definition: SDL_gpu.c:1343
DECLSPEC GPU_Image *SDLCALL GPU_CopyImageFromTarget(GPU_Target *target)
Definition: SDL_gpu.c:1321
DECLSPEC GPU_Image *SDLCALL GPU_CopyImage(GPU_Image *image)
Definition: SDL_gpu.c:1027
DECLSPEC GPU_SnapEnum SDLCALL GPU_GetSnapMode(GPU_Image *image)
Definition: SDL_gpu.c:2025
GPU_FormatEnum
Definition: SDL_gpu.h:293
GPU_FilterEnum
Definition: SDL_gpu.h:260
GPU_WrapEnum
Definition: SDL_gpu.h:283
DECLSPEC void SDLCALL GPU_SetBlendFunction(GPU_Image *image, GPU_BlendFuncEnum source_color, GPU_BlendFuncEnum dest_color, GPU_BlendFuncEnum source_alpha, GPU_BlendFuncEnum dest_alpha)
Definition: SDL_gpu.c:1904
DECLSPEC void SDLCALL GPU_UpdateImageBytes(GPU_Image *image, const GPU_Rect *image_rect, const unsigned char *bytes, int bytes_per_row)
Definition: SDL_gpu.c:1043
uintptr_t GPU_TextureHandle
Definition: SDL_gpu.h:370
GPU_FileFormatEnum
Definition: SDL_gpu.h:314
DECLSPEC GPU_bool SDLCALL GPU_GetBlending(GPU_Image *image)
Definition: SDL_gpu.c:1794
DECLSPEC GPU_Image *SDLCALL GPU_CreateImageUsingTexture(GPU_TextureHandle handle, GPU_bool take_ownership)
Definition: SDL_gpu.c:966
DECLSPEC void SDLCALL GPU_GetAnchor(GPU_Image *image, float *anchor_x, float *anchor_y)
Definition: SDL_gpu.c:2013
DECLSPEC void SDLCALL GPU_UnsetImageVirtualResolution(GPU_Image *image)
Definition: SDL_gpu.c:640
DECLSPEC void SDLCALL GPU_SetColor(GPU_Image *image, SDL_Color color)
Definition: SDL_gpu.c:1700
DECLSPEC void SDLCALL GPU_SetAnchor(GPU_Image *image, float anchor_x, float anchor_y)
Definition: SDL_gpu.c:2004
DECLSPEC void SDLCALL GPU_SetBlending(GPU_Image *image, GPU_bool enable)
Definition: SDL_gpu.c:1803
GPU_BlendPresetEnum
Definition: SDL_gpu.h:242
DECLSPEC void SDLCALL GPU_SetBlendEquation(GPU_Image *image, GPU_BlendEqEnum color_equation, GPU_BlendEqEnum alpha_equation)
Definition: SDL_gpu.c:1915
DECLSPEC GPU_Image *SDLCALL GPU_CreateImage(Uint16 w, Uint16 h, GPU_FormatEnum format)
Definition: SDL_gpu.c:958
DECLSPEC void SDLCALL GPU_SetWrapMode(GPU_Image *image, GPU_WrapEnum wrap_mode_x, GPU_WrapEnum wrap_mode_y)
Definition: SDL_gpu.c:2041
DECLSPEC GPU_bool SDLCALL GPU_ReplaceImage(GPU_Image *image, SDL_Surface *surface, const GPU_Rect *surface_rect)
Definition: SDL_gpu.c:1051
DECLSPEC void SDLCALL GPU_UnsetColor(GPU_Image *image)
Definition: SDL_gpu.c:1736
DECLSPEC void SDLCALL GPU_SetBlendMode(GPU_Image *image, GPU_BlendPresetEnum mode)
Definition: SDL_gpu.c:1924
DECLSPEC GPU_bool SDLCALL GPU_SaveImage_RW(GPU_Image *image, SDL_RWops *rwops, GPU_bool free_rwops, GPU_FileFormatEnum format)
Definition: SDL_gpu.c:1015
GPU_BlendEqEnum
Definition: SDL_gpu.h:218
DECLSPEC void SDLCALL GPU_SetRGBA(GPU_Image *image, Uint8 r, Uint8 g, Uint8 b, Uint8 a)
Definition: SDL_gpu.c:1722
DECLSPEC GPU_Image *SDLCALL GPU_LoadImage_RW(SDL_RWops *rwops, GPU_bool free_rwops)
Definition: SDL_gpu.c:979
DECLSPEC GPU_bool SDLCALL GPU_SaveImage(GPU_Image *image, const char *filename, GPU_FileFormatEnum format)
Definition: SDL_gpu.c:1007
GPU_SnapEnum
Definition: SDL_gpu.h:271
DECLSPEC void SDLCALL GPU_SetRGB(GPU_Image *image, Uint8 r, Uint8 g, Uint8 b)
Definition: SDL_gpu.c:1708
DECLSPEC void SDLCALL GPU_GenerateMipmaps(GPU_Image *image)
Definition: SDL_gpu.c:1594
DECLSPEC GPU_Image *SDLCALL GPU_CreateAliasImage(GPU_Image *image)
Definition: SDL_gpu.c:999
DECLSPEC void SDLCALL GPU_SetImageFilter(GPU_Image *image, GPU_FilterEnum filter)
Definition: SDL_gpu.c:1972
DECLSPEC GPU_Image *SDLCALL GPU_LoadImage(const char *filename)
Definition: SDL_gpu.c:974
DECLSPEC void SDLCALL GPU_FreeImage(GPU_Image *image)
Definition: SDL_gpu.c:1351
DECLSPEC void SDLCALL GPU_SetImageVirtualResolution(GPU_Image *image, Uint16 w, Uint16 h)
Definition: SDL_gpu.c:626
DECLSPEC void SDLCALL GPU_UpdateImage(GPU_Image *image, const GPU_Rect *image_rect, SDL_Surface *surface, const GPU_Rect *surface_rect)
Definition: SDL_gpu.c:1035
GPU_BlendFuncEnum
Definition: SDL_gpu.h:200
DECLSPEC GPU_TextureHandle SDLCALL GPU_GetTextureHandle(GPU_Image *image)
Definition: SDL_gpu.c:2051
DECLSPEC void SDLCALL GPU_SetSnapMode(GPU_Image *image, GPU_SnapEnum mode)
Definition: SDL_gpu.c:2033
DECLSPEC void SDLCALL GPU_Quit(void)
Definition: SDL_gpu.c:694
DECLSPEC GPU_InitFlagEnum SDLCALL GPU_GetPreInitFlags(void)
Definition: SDL_gpu.c:230
DECLSPEC GPU_bool SDLCALL GPU_IsFeatureEnabled(GPU_FeatureEnum feature)
Definition: SDL_gpu.c:475
DECLSPEC void SDLCALL GPU_SetRendererOrder(int order_size, GPU_RendererID *order)
Definition: SDL_gpu_renderer.c:300
DECLSPEC GPU_Target *SDLCALL GPU_InitRenderer(GPU_RendererEnum renderer_enum, Uint16 w, Uint16 h, GPU_WindowFlagEnum SDL_flags)
Definition: SDL_gpu.c:438
Uint32 GPU_InitFlagEnum
Definition: SDL_gpu.h:569
DECLSPEC Uint32 SDLCALL GPU_GetInitWindow(void)
Definition: SDL_gpu.c:220
DECLSPEC void SDLCALL GPU_SetInitWindow(Uint32 windowID)
Definition: SDL_gpu.c:215
DECLSPEC GPU_Target *SDLCALL GPU_InitRendererByID(GPU_RendererID renderer_request, Uint16 w, Uint16 h, GPU_WindowFlagEnum SDL_flags)
Definition: SDL_gpu.c:444
DECLSPEC void SDLCALL GPU_SetRequiredFeatures(GPU_FeatureEnum features)
Definition: SDL_gpu.c:235
DECLSPEC GPU_Target *SDLCALL GPU_Init(Uint16 w, Uint16 h, GPU_WindowFlagEnum SDL_flags)
Definition: SDL_gpu.c:410
DECLSPEC void SDLCALL GPU_GetRendererOrder(int *order_size, GPU_RendererID *order)
Definition: SDL_gpu_renderer.c:291
Uint32 GPU_FeatureEnum
Definition: SDL_gpu.h:537
DECLSPEC void SDLCALL GPU_CloseCurrentRenderer(void)
Definition: SDL_gpu.c:685
DECLSPEC void SDLCALL GPU_SetPreInitFlags(GPU_InitFlagEnum GPU_flags)
Definition: SDL_gpu.c:225
DECLSPEC void SDLCALL GPU_GetDefaultRendererOrder(int *order_size, GPU_RendererID *order)
Definition: SDL_gpu_renderer.c:327
DECLSPEC GPU_FeatureEnum SDLCALL GPU_GetRequiredFeatures(void)
Definition: SDL_gpu.c:240
DECLSPEC GPU_ErrorObject SDLCALL GPU_PopErrorCode(void)
Definition: SDL_gpu.c:788
DECLSPEC void SDLCALL GPU_LogError(const char *format,...)
Definition: SDL_gpu.c:180
DECLSPEC void SDLCALL GPU_SetDebugLevel(GPU_DebugLevelEnum level)
Definition: SDL_gpu.c:732
GPU_DebugLevelEnum
Definition: SDL_gpu.h:757
DECLSPEC void SDLCALL GPU_PushErrorCode(const char *function, GPU_ErrorEnum error, const char *details,...)
Definition: SDL_gpu.c:744
DECLSPEC void SDLCALL GPU_SetLogCallback(int(*callback)(GPU_LogLevelEnum log_level, const char *format, va_list args))
Definition: SDL_gpu.c:156
GPU_LogLevelEnum
Definition: SDL_gpu.h:770
DECLSPEC void SDLCALL GPU_LogWarning(const char *format,...)
Definition: SDL_gpu.c:172
DECLSPEC void SDLCALL GPU_SetErrorQueueMax(unsigned int max)
Definition: SDL_gpu.c:676
GPU_ErrorEnum
Definition: SDL_gpu.h:731
DECLSPEC void SDLCALL GPU_LogInfo(const char *format,...)
Definition: SDL_gpu.c:164
DECLSPEC GPU_DebugLevelEnum SDLCALL GPU_GetDebugLevel(void)
Definition: SDL_gpu.c:739
DECLSPEC const char *SDLCALL GPU_GetErrorString(GPU_ErrorEnum error)
Definition: SDL_gpu.c:817
DECLSPEC void SDLCALL GPU_MatrixLookAt(float *matrix, float eye_x, float eye_y, float eye_z, float target_x, float target_y, float target_z, float up_x, float up_y, float up_z)
Definition: SDL_gpu_matrix.c:303
DECLSPEC void SDLCALL GPU_Ortho(float left, float right, float bottom, float top, float z_near, float z_far)
Definition: SDL_gpu_matrix.c:702
DECLSPEC void SDLCALL GPU_MatrixCopy(float *result, const float *A)
Definition: SDL_gpu_matrix.c:231
DECLSPEC void SDLCALL GPU_MatrixOrtho(float *result, float left, float right, float bottom, float top, float z_near, float z_far)
Definition: SDL_gpu_matrix.c:243
DECLSPEC void SDLCALL GPU_SetModelFromStack(GPU_MatrixStack *stack)
Definition: SDL_gpu_matrix.c:658
DECLSPEC void SDLCALL GPU_ResetProjection(GPU_Target *target)
Definition: SDL_gpu_matrix.c:126
DECLSPEC void SDLCALL GPU_MatrixIdentity(float *result)
Definition: SDL_gpu_matrix.c:236
DECLSPEC void SDLCALL GPU_MatrixScale(float *result, float sx, float sy, float sz)
Definition: SDL_gpu_matrix.c:370
DECLSPEC void SDLCALL GPU_PopMatrix(void)
Definition: SDL_gpu_matrix.c:589
DECLSPEC void SDLCALL GPU_GetModelViewProjection(float *result)
Definition: SDL_gpu_matrix.c:754
DECLSPEC float *SDLCALL GPU_GetTopMatrix(GPU_MatrixStack *stack)
Definition: SDL_gpu_matrix.c:676
DECLSPEC void SDLCALL GPU_MatrixMultiply(float *result, const float *A, const float *B)
Definition: SDL_gpu_matrix.c:434
DECLSPEC void SDLCALL GPU_Frustum(float left, float right, float bottom, float top, float z_near, float z_far)
Definition: SDL_gpu_matrix.c:708
DECLSPEC void SDLCALL GPU_SetModel(const float *A)
Definition: SDL_gpu_matrix.c:629
DECLSPEC float SDLCALL GPU_VectorDot(const float *A, const float *B)
Definition: SDL_gpu_matrix.c:160
DECLSPEC float *SDLCALL GPU_GetProjection(void)
Definition: SDL_gpu_matrix.c:519
DECLSPEC void SDLCALL GPU_MultiplyAndAssign(float *result, const float *B)
Definition: SDL_gpu_matrix.c:457
DECLSPEC void SDLCALL GPU_VectorCross(float *result, const float *A, const float *B)
Definition: SDL_gpu_matrix.c:165
DECLSPEC void SDLCALL GPU_MatrixRotate(float *result, float degrees, float x, float y, float z)
Definition: SDL_gpu_matrix.c:388
DECLSPEC void SDLCALL GPU_Rotate(float degrees, float x, float y, float z)
Definition: SDL_gpu_matrix.c:739
DECLSPEC void SDLCALL GPU_MatrixMode(GPU_Target *target, int matrix_mode)
Definition: SDL_gpu_matrix.c:489
DECLSPEC void SDLCALL GPU_InitMatrixStack(GPU_MatrixStack *stack)
Definition: SDL_gpu_matrix.c:79
DECLSPEC GPU_MatrixStack *SDLCALL GPU_CreateMatrixStack(void)
Definition: SDL_gpu_matrix.c:62
DECLSPEC void SDLCALL GPU_LoadMatrix(const float *matrix4x4)
Definition: SDL_gpu_matrix.c:693
DECLSPEC float *SDLCALL GPU_GetView(void)
Definition: SDL_gpu_matrix.c:511
DECLSPEC void SDLCALL GPU_SetProjection(const float *A)
Definition: SDL_gpu_matrix.c:619
DECLSPEC const char *SDLCALL GPU_GetMatrixString(const float *A)
Definition: SDL_gpu_matrix.c:469
DECLSPEC void SDLCALL GPU_LoadIdentity(void)
Definition: SDL_gpu_matrix.c:683
DECLSPEC void SDLCALL GPU_VectorApplyMatrix(float *vec3, const float *matrix_4x4)
Definition: SDL_gpu_matrix.c:179
DECLSPEC float SDLCALL GPU_VectorLength(const float *vec3)
Definition: SDL_gpu_matrix.c:147
DECLSPEC void SDLCALL GPU_MatrixPerspective(float *result, float fovy, float aspect, float z_near, float z_far)
Definition: SDL_gpu_matrix.c:290
DECLSPEC void SDLCALL GPU_ClearMatrixStack(GPU_MatrixStack *stack)
Definition: SDL_gpu_matrix.c:112
DECLSPEC void SDLCALL GPU_SetView(const float *A)
Definition: SDL_gpu_matrix.c:639
DECLSPEC void SDLCALL GPU_LookAt(float eye_x, float eye_y, float eye_z, float target_x, float target_y, float target_z, float up_x, float up_y, float up_z)
Definition: SDL_gpu_matrix.c:720
DECLSPEC float *SDLCALL GPU_GetCurrentMatrix(void)
Definition: SDL_gpu_matrix.c:527
DECLSPEC void SDLCALL GPU_Perspective(float fovy, float aspect, float z_near, float z_far)
Definition: SDL_gpu_matrix.c:714
DECLSPEC void SDLCALL GPU_SetProjectionFromStack(GPU_MatrixStack *stack)
Definition: SDL_gpu_matrix.c:649
DECLSPEC void SDLCALL GPU_SetViewFromStack(GPU_MatrixStack *stack)
Definition: SDL_gpu_matrix.c:667
DECLSPEC void SDLCALL GPU_FreeMatrixStack(GPU_MatrixStack *stack)
Definition: SDL_gpu_matrix.c:73
DECLSPEC float *SDLCALL GPU_GetModel(void)
Definition: SDL_gpu_matrix.c:503
DECLSPEC void SDLCALL GPU_PushMatrix(void)
Definition: SDL_gpu_matrix.c:543
DECLSPEC void SDLCALL GPU_VectorNormalize(float *vec3)
Definition: SDL_gpu_matrix.c:152
DECLSPEC void SDLCALL GPU_MatrixTranslate(float *result, float x, float y, float z)
Definition: SDL_gpu_matrix.c:342
DECLSPEC void SDLCALL GPU_Scale(float sx, float sy, float sz)
Definition: SDL_gpu_matrix.c:733
DECLSPEC void SDLCALL GPU_MatrixFrustum(float *result, float left, float right, float bottom, float top, float z_near, float z_far)
Definition: SDL_gpu_matrix.c:272
DECLSPEC void SDLCALL GPU_MultMatrix(const float *matrix4x4)
Definition: SDL_gpu_matrix.c:745
DECLSPEC void SDLCALL GPU_VectorCopy(float *result, const float *A)
Definition: SDL_gpu_matrix.c:172
DECLSPEC void SDLCALL GPU_CopyMatrixStack(const GPU_MatrixStack *source, GPU_MatrixStack *dest)
Definition: SDL_gpu_matrix.c:95
DECLSPEC void SDLCALL GPU_Vector4ApplyMatrix(float *vec4, const float *matrix_4x4)
Definition: SDL_gpu_matrix.c:190
DECLSPEC void SDLCALL GPU_Translate(float x, float y, float z)
Definition: SDL_gpu_matrix.c:727
DECLSPEC void SDLCALL GPU_GetDefaultAnchor(float *anchor_x, float *anchor_y)
Definition: SDL_gpu.c:1992
DECLSPEC void SDLCALL GPU_GetActiveRendererList(GPU_RendererID *renderers_array)
Definition: SDL_gpu_renderer.c:63
DECLSPEC GPU_RendererEnum SDLCALL GPU_ReserveNextRendererEnum(void)
Definition: SDL_gpu_renderer.c:41
DECLSPEC void SDLCALL GPU_SetCoordinateMode(GPU_bool use_math_coords)
Definition: SDL_gpu.c:102
DECLSPEC void SDLCALL GPU_SetDefaultAnchor(float anchor_x, float anchor_y)
Definition: SDL_gpu.c:1983
DECLSPEC void SDLCALL GPU_SetCurrentRenderer(GPU_RendererID id)
Definition: SDL_gpu.c:86
DECLSPEC int SDLCALL GPU_GetNumActiveRenderers(void)
Definition: SDL_gpu_renderer.c:47
DECLSPEC GPU_Renderer *SDLCALL GPU_GetRenderer(GPU_RendererID id)
Definition: SDL_gpu_renderer.c:415
DECLSPEC void SDLCALL GPU_ResetRendererState(void)
Definition: SDL_gpu.c:94
DECLSPEC GPU_Renderer *SDLCALL GPU_GetCurrentRenderer(void)
Definition: SDL_gpu.c:118
DECLSPEC void SDLCALL GPU_GetRegisteredRendererList(GPU_RendererID *renderers_array)
Definition: SDL_gpu_renderer.c:98
DECLSPEC GPU_RendererID SDLCALL GPU_MakeRendererID(const char *name, GPU_RendererEnum renderer, int major_version, int minor_version)
Definition: SDL_gpu.c:896
DECLSPEC GPU_RendererID SDLCALL GPU_GetRendererID(GPU_RendererEnum renderer)
Definition: SDL_gpu_renderer.c:117
DECLSPEC int SDLCALL GPU_GetNumRegisteredRenderers(void)
Definition: SDL_gpu_renderer.c:82
DECLSPEC void SDLCALL GPU_RegisterRenderer(GPU_RendererID id, GPU_Renderer *(SDLCALL *create_renderer)(GPU_RendererID request), void(SDLCALL *free_renderer)(GPU_Renderer *renderer))
DECLSPEC void SDLCALL GPU_BlitTransformX(GPU_Image *image, GPU_Rect *src_rect, GPU_Target *target, float x, float y, float pivot_x, float pivot_y, float degrees, float scaleX, float scaleY)
Definition: SDL_gpu.c:1465
DECLSPEC void SDLCALL GPU_Clear(GPU_Target *target)
Definition: SDL_gpu.c:2076
DECLSPEC void SDLCALL GPU_ClearColor(GPU_Target *target, SDL_Color color)
Definition: SDL_gpu.c:2087
DECLSPEC void SDLCALL GPU_TriangleBatch(GPU_Image *image, GPU_Target *target, unsigned short num_vertices, float *values, unsigned int num_indices, unsigned short *indices, GPU_BatchFlagEnum flags)
Definition: SDL_gpu.c:1558
DECLSPEC void SDLCALL GPU_ClearRGBA(GPU_Target *target, Uint8 r, Uint8 g, Uint8 b, Uint8 a)
Definition: SDL_gpu.c:2109
DECLSPEC void SDLCALL GPU_Flip(GPU_Target *target)
Definition: SDL_gpu.c:2128
DECLSPEC void SDLCALL GPU_PrimitiveBatch(GPU_Image *image, GPU_Target *target, GPU_PrimitiveEnum primitive_type, unsigned short num_vertices, float *values, unsigned int num_indices, unsigned short *indices, GPU_BatchFlagEnum flags)
Definition: SDL_gpu.c:1568
DECLSPEC void SDLCALL GPU_BlitRotate(GPU_Image *image, GPU_Rect *src_rect, GPU_Target *target, float x, float y, float degrees)
Definition: SDL_gpu.c:1417
Uint32 GPU_PrimitiveEnum
Definition: SDL_gpu.h:588
DECLSPEC void SDLCALL GPU_BlitTransform(GPU_Image *image, GPU_Rect *src_rect, GPU_Target *target, float x, float y, float degrees, float scaleX, float scaleY)
Definition: SDL_gpu.c:1449
DECLSPEC void SDLCALL GPU_TriangleBatchX(GPU_Image *image, GPU_Target *target, unsigned short num_vertices, void *values, unsigned int num_indices, unsigned short *indices, GPU_BatchFlagEnum flags)
Definition: SDL_gpu.c:1563
DECLSPEC void SDLCALL GPU_PrimitiveBatchV(GPU_Image *image, GPU_Target *target, GPU_PrimitiveEnum primitive_type, unsigned short num_vertices, void *values, unsigned int num_indices, unsigned short *indices, GPU_BatchFlagEnum flags)
Definition: SDL_gpu.c:1573
DECLSPEC void SDLCALL GPU_FlushBlitBuffer(void)
Definition: SDL_gpu.c:2120
DECLSPEC void SDLCALL GPU_BlitRect(GPU_Image *image, GPU_Rect *src_rect, GPU_Target *target, GPU_Rect *dest_rect)
Definition: SDL_gpu.c:1481
DECLSPEC void SDLCALL GPU_ClearRGB(GPU_Target *target, Uint8 r, Uint8 g, Uint8 b)
Definition: SDL_gpu.c:2098
DECLSPEC void SDLCALL GPU_BlitScale(GPU_Image *image, GPU_Rect *src_rect, GPU_Target *target, float x, float y, float scaleX, float scaleY)
Definition: SDL_gpu.c:1433
DECLSPEC void SDLCALL GPU_Blit(GPU_Image *image, GPU_Rect *src_rect, GPU_Target *target, float x, float y)
Definition: SDL_gpu.c:1400
DECLSPEC void SDLCALL GPU_BlitRectX(GPU_Image *image, GPU_Rect *src_rect, GPU_Target *target, GPU_Rect *dest_rect, float degrees, float pivot_x, float pivot_y, GPU_FlipEnum flip_direction)
Definition: SDL_gpu.c:1503
GPU_ShaderEnum
Definition: SDL_gpu.h:664
DECLSPEC void SDLCALL GPU_DetachShader(Uint32 program_object, Uint32 shader_object)
Definition: SDL_gpu.c:2264
DECLSPEC void SDLCALL GPU_DeactivateShaderProgram(void)
Definition: SDL_gpu.c:2291
Uint32 GPU_TypeEnum
Definition: SDL_gpu.h:642
DECLSPEC void SDLCALL GPU_FreeShader(Uint32 shader_object)
Definition: SDL_gpu.c:2240
DECLSPEC GPU_ShaderBlock SDLCALL GPU_GetShaderBlock(void)
Definition: SDL_gpu.c:2367
DECLSPEC GPU_ShaderBlock SDLCALL GPU_LoadShaderBlock(Uint32 program_object, const char *position_name, const char *texcoord_name, const char *color_name, const char *modelViewMatrix_name)
Definition: SDL_gpu.c:2344
DECLSPEC void SDLCALL GPU_SetShaderBlock(GPU_ShaderBlock block)
Definition: SDL_gpu.c:2359
DECLSPEC void SDLCALL GPU_SetAttributeSource(int num_values, GPU_Attribute source)
Definition: SDL_gpu.c:2530
DECLSPEC void SDLCALL GPU_SetAttributefv(int location, int num_elements, float *value)
Definition: SDL_gpu.c:2506
DECLSPEC void SDLCALL GPU_SetUniformiv(int location, int num_elements_per_value, int num_values, int *values)
Definition: SDL_gpu.c:2406
DECLSPEC const char *SDLCALL GPU_GetShaderMessage(void)
Definition: SDL_gpu.c:2299
DECLSPEC Uint32 SDLCALL GPU_CompileShader(GPU_ShaderEnum shader_type, const char *shader_source)
Definition: SDL_gpu.c:2185
DECLSPEC void SDLCALL GPU_SetAttributeiv(int location, int num_elements, int *value)
Definition: SDL_gpu.c:2514
DECLSPEC void SDLCALL GPU_SetUniformfv(int location, int num_elements_per_value, int num_values, float *values)
Definition: SDL_gpu.c:2456
DECLSPEC Uint32 SDLCALL GPU_LinkShaders(Uint32 shader_object1, Uint32 shader_object2)
Definition: SDL_gpu.c:2209
DECLSPEC GPU_AttributeFormat SDLCALL GPU_MakeAttributeFormat(int num_elems_per_vertex, GPU_TypeEnum type, GPU_bool normalize, int stride_bytes, int offset_bytes)
Definition: SDL_gpu.c:2315
DECLSPEC void SDLCALL GPU_SetAttributeui(int location, unsigned int value)
Definition: SDL_gpu.c:2498
DECLSPEC void SDLCALL GPU_AttachShader(Uint32 program_object, Uint32 shader_object)
Definition: SDL_gpu.c:2256
DECLSPEC int SDLCALL GPU_GetAttributeLocation(Uint32 program_object, const char *attrib_name)
Definition: SDL_gpu.c:2307
DECLSPEC void SDLCALL GPU_SetUniformMatrixfv(int location, int num_matrices, int num_rows, int num_columns, GPU_bool transpose, float *values)
Definition: SDL_gpu.c:2473
DECLSPEC int SDLCALL GPU_GetUniformLocation(Uint32 program_object, const char *uniform_name)
Definition: SDL_gpu.c:2336
DECLSPEC GPU_Attribute SDLCALL GPU_MakeAttribute(int location, void *values, GPU_AttributeFormat format)
Definition: SDL_gpu.c:2327
DECLSPEC GPU_bool SDLCALL GPU_IsDefaultShaderProgram(Uint32 program_object)
Definition: SDL_gpu.c:2272
DECLSPEC Uint32 SDLCALL GPU_LoadShader(GPU_ShaderEnum shader_type, const char *filename)
Definition: SDL_gpu.c:2165
DECLSPEC void SDLCALL GPU_SetAttributeuiv(int location, int num_elements, unsigned int *value)
Definition: SDL_gpu.c:2522
DECLSPEC void SDLCALL GPU_GetUniformfv(Uint32 program_object, int location, float *values)
Definition: SDL_gpu.c:2440
DECLSPEC void SDLCALL GPU_GetUniformMatrixfv(Uint32 program_object, int location, float *values)
Definition: SDL_gpu.c:2465
DECLSPEC void SDLCALL GPU_SetUniformui(int location, unsigned int value)
Definition: SDL_gpu.c:2423
DECLSPEC void SDLCALL GPU_SetAttributef(int location, float value)
Definition: SDL_gpu.c:2482
DECLSPEC Uint32 SDLCALL GPU_LinkManyShaders(Uint32 *shader_objects, int count)
Definition: SDL_gpu.c:2217
DECLSPEC Uint32 SDLCALL GPU_CreateShaderProgram(void)
Definition: SDL_gpu.c:2201
GPU_ShaderLanguageEnum
Definition: SDL_gpu.h:676
DECLSPEC Uint32 SDLCALL GPU_CompileShader_RW(GPU_ShaderEnum shader_type, SDL_RWops *shader_source, GPU_bool free_rwops)
Definition: SDL_gpu.c:2153
DECLSPEC void SDLCALL GPU_SetShaderImage(GPU_Image *image, int location, int image_unit)
Definition: SDL_gpu.c:2382
DECLSPEC void SDLCALL GPU_SetUniformf(int location, float value)
Definition: SDL_gpu.c:2448
DECLSPEC void SDLCALL GPU_SetUniformuiv(int location, int num_elements_per_value, int num_values, unsigned int *values)
Definition: SDL_gpu.c:2431
DECLSPEC Uint32 SDLCALL GPU_GetCurrentShaderProgram(void)
Definition: SDL_gpu.c:123
DECLSPEC void SDLCALL GPU_GetUniformuiv(Uint32 program_object, int location, unsigned int *values)
Definition: SDL_gpu.c:2415
DECLSPEC void SDLCALL GPU_ActivateShaderProgram(Uint32 program_object, GPU_ShaderBlock *block)
Definition: SDL_gpu.c:2283
DECLSPEC void SDLCALL GPU_SetAttributei(int location, int value)
Definition: SDL_gpu.c:2490
DECLSPEC void SDLCALL GPU_FreeShaderProgram(Uint32 program_object)
Definition: SDL_gpu.c:2248
DECLSPEC void SDLCALL GPU_GetUniformiv(Uint32 program_object, int location, int *values)
Definition: SDL_gpu.c:2390
DECLSPEC GPU_bool SDLCALL GPU_LinkShaderProgram(Uint32 program_object)
Definition: SDL_gpu.c:2193
DECLSPEC void SDLCALL GPU_SetUniformi(int location, int value)
Definition: SDL_gpu.c:2398
DECLSPEC void SDLCALL GPU_RectangleRoundFilled(GPU_Target *target, float x1, float y1, float x2, float y2, float radius, SDL_Color color)
Definition: SDL_gpu_shapes.c:145
DECLSPEC void SDLCALL GPU_RectangleFilled(GPU_Target *target, float x1, float y1, float x2, float y2, SDL_Color color)
Definition: SDL_gpu_shapes.c:121
DECLSPEC void SDLCALL GPU_Tri(GPU_Target *target, float x1, float y1, float x2, float y2, float x3, float y3, SDL_Color color)
Definition: SDL_gpu_shapes.c:97
DECLSPEC void SDLCALL GPU_PolygonFilled(GPU_Target *target, unsigned int num_vertices, float *vertices, SDL_Color color)
Definition: SDL_gpu_shapes.c:169
DECLSPEC void SDLCALL GPU_Ellipse(GPU_Target *target, float x, float y, float rx, float ry, float degrees, SDL_Color color)
Definition: SDL_gpu_shapes.c:73
DECLSPEC void SDLCALL GPU_Arc(GPU_Target *target, float x, float y, float radius, float start_angle, float end_angle, SDL_Color color)
Definition: SDL_gpu_shapes.c:48
DECLSPEC void SDLCALL GPU_Rectangle(GPU_Target *target, float x1, float y1, float x2, float y2, SDL_Color color)
Definition: SDL_gpu_shapes.c:109
DECLSPEC void SDLCALL GPU_RectangleFilled2(GPU_Target *target, GPU_Rect rect, SDL_Color color)
Definition: SDL_gpu_shapes.c:127
DECLSPEC void SDLCALL GPU_SectorFilled(GPU_Target *target, float x, float y, float inner_radius, float outer_radius, float start_angle, float end_angle, SDL_Color color)
Definition: SDL_gpu_shapes.c:91
DECLSPEC void SDLCALL GPU_Sector(GPU_Target *target, float x, float y, float inner_radius, float outer_radius, float start_angle, float end_angle, SDL_Color color)
Definition: SDL_gpu_shapes.c:85
DECLSPEC void SDLCALL GPU_RectangleRound2(GPU_Target *target, GPU_Rect rect, float radius, SDL_Color color)
Definition: SDL_gpu_shapes.c:139
DECLSPEC void SDLCALL GPU_EllipseFilled(GPU_Target *target, float x, float y, float rx, float ry, float degrees, SDL_Color color)
Definition: SDL_gpu_shapes.c:79
DECLSPEC void SDLCALL GPU_Rectangle2(GPU_Target *target, GPU_Rect rect, SDL_Color color)
Definition: SDL_gpu_shapes.c:115
DECLSPEC void SDLCALL GPU_Circle(GPU_Target *target, float x, float y, float radius, SDL_Color color)
Definition: SDL_gpu_shapes.c:61
DECLSPEC void SDLCALL GPU_Polygon(GPU_Target *target, unsigned int num_vertices, float *vertices, SDL_Color color)
Definition: SDL_gpu_shapes.c:157
DECLSPEC void SDLCALL GPU_RectangleRound(GPU_Target *target, float x1, float y1, float x2, float y2, float radius, SDL_Color color)
Definition: SDL_gpu_shapes.c:133
DECLSPEC void SDLCALL GPU_Polyline(GPU_Target *target, unsigned int num_vertices, float *vertices, SDL_Color color, GPU_bool close_loop)
Definition: SDL_gpu_shapes.c:163
DECLSPEC void SDLCALL GPU_Pixel(GPU_Target *target, float x, float y, SDL_Color color)
Definition: SDL_gpu_shapes.c:35
DECLSPEC void SDLCALL GPU_Line(GPU_Target *target, float x1, float y1, float x2, float y2, SDL_Color color)
Definition: SDL_gpu_shapes.c:41
DECLSPEC void SDLCALL GPU_TriFilled(GPU_Target *target, float x1, float y1, float x2, float y2, float x3, float y3, SDL_Color color)
Definition: SDL_gpu_shapes.c:103
DECLSPEC void SDLCALL GPU_ArcFilled(GPU_Target *target, float x, float y, float radius, float start_angle, float end_angle, SDL_Color color)
Definition: SDL_gpu_shapes.c:55
DECLSPEC void SDLCALL GPU_CircleFilled(GPU_Target *target, float x, float y, float radius, SDL_Color color)
Definition: SDL_gpu_shapes.c:67
DECLSPEC void SDLCALL GPU_RectangleRoundFilled2(GPU_Target *target, GPU_Rect rect, float radius, SDL_Color color)
Definition: SDL_gpu_shapes.c:151
DECLSPEC SDL_Surface *SDLCALL GPU_LoadSurface_RW(SDL_RWops *rwops, GPU_bool free_rwops)
Definition: SDL_gpu.c:1148
DECLSPEC GPU_bool SDLCALL GPU_SaveSurface_RW(SDL_Surface *surface, SDL_RWops *rwops, GPU_bool free_rwops, GPU_FileFormatEnum format)
Definition: SDL_gpu.c:1263
DECLSPEC SDL_Surface *SDLCALL GPU_LoadSurface(const char *filename)
Definition: SDL_gpu.c:1194
DECLSPEC GPU_bool SDLCALL GPU_SaveSurface(SDL_Surface *surface, const char *filename, GPU_FileFormatEnum format)
Definition: SDL_gpu.c:1208
DECLSPEC void SDLCALL GPU_SetDepthTest(GPU_Target *target, GPU_bool enable)
Definition: SDL_gpu.c:561
DECLSPEC void SDLCALL GPU_GetVirtualResolution(GPU_Target *target, Uint16 *w, Uint16 *h)
Definition: SDL_gpu.c:588
DECLSPEC void SDLCALL GPU_GetVirtualCoords(GPU_Target *target, float *x, float *y, float displayX, float displayY)
Definition: SDL_gpu.c:840
DECLSPEC void SDLCALL GPU_SetViewport(GPU_Target *target, GPU_Rect viewport)
Definition: SDL_gpu.c:907
DECLSPEC void SDLCALL GPU_SetTargetColor(GPU_Target *target, SDL_Color color)
Definition: SDL_gpu.c:1745
DECLSPEC GPU_Rect SDLCALL GPU_MakeRect(float x, float y, float w, float h)
Definition: SDL_gpu.c:874
DECLSPEC void SDLCALL GPU_UnsetViewport(GPU_Target *target)
Definition: SDL_gpu.c:913
DECLSPEC GPU_Camera SDLCALL GPU_GetDefaultCamera(void)
Definition: SDL_gpu.c:919
DECLSPEC SDL_Color SDLCALL GPU_GetPixel(GPU_Target *target, Sint16 x, Sint16 y)
Definition: SDL_gpu.c:2059
DECLSPEC SDL_Color SDLCALL GPU_MakeColor(Uint8 r, Uint8 g, Uint8 b, Uint8 a)
Definition: SDL_gpu.c:885
DECLSPEC GPU_bool SDLCALL GPU_AddDepthBuffer(GPU_Target *target)
Definition: SDL_gpu.c:553
DECLSPEC void SDLCALL GPU_UnsetClip(GPU_Target *target)
Definition: SDL_gpu.c:1627
DECLSPEC GPU_bool SDLCALL GPU_IntersectRect(GPU_Rect A, GPU_Rect B, GPU_Rect *result)
Definition: SDL_gpu.c:1636
DECLSPEC GPU_bool SDLCALL GPU_IntersectClipRect(GPU_Target *target, GPU_Rect B, GPU_Rect *result)
Definition: SDL_gpu.c:1685
DECLSPEC GPU_Rect SDLCALL GPU_SetClipRect(GPU_Target *target, GPU_Rect rect)
Definition: SDL_gpu.c:1605
DECLSPEC void SDLCALL GPU_UnsetVirtualResolution(GPU_Target *target)
Definition: SDL_gpu.c:615
DECLSPEC GPU_bool SDLCALL GPU_IsCameraEnabled(GPU_Target *target)
Definition: SDL_gpu.c:951
DECLSPEC GPU_Camera SDLCALL GPU_GetCamera(GPU_Target *target)
Definition: SDL_gpu.c:925
DECLSPEC GPU_Camera SDLCALL GPU_SetCamera(GPU_Target *target, GPU_Camera *cam)
Definition: SDL_gpu.c:932
DECLSPEC void SDLCALL GPU_SetDepthFunction(GPU_Target *target, GPU_ComparisonEnum compare_operation)
Definition: SDL_gpu.c:573
DECLSPEC void SDLCALL GPU_FreeTarget(GPU_Target *target)
Definition: SDL_gpu.c:1390
DECLSPEC GPU_Rect SDLCALL GPU_SetClip(GPU_Target *target, Sint16 x, Sint16 y, Uint16 w, Uint16 h)
Definition: SDL_gpu.c:1616
DECLSPEC GPU_Target *SDLCALL GPU_GetTarget(GPU_Image *image)
Definition: SDL_gpu.c:1380
DECLSPEC void SDLCALL GPU_EnableCamera(GPU_Target *target, GPU_bool use_camera)
Definition: SDL_gpu.c:943
DECLSPEC GPU_Target *SDLCALL GPU_CreateAliasTarget(GPU_Target *target)
Definition: SDL_gpu.c:493
DECLSPEC void SDLCALL GPU_SetDepthWrite(GPU_Target *target, GPU_bool enable)
Definition: SDL_gpu.c:567
DECLSPEC void SDLCALL GPU_SetVirtualResolution(GPU_Target *target, Uint16 w, Uint16 h)
Definition: SDL_gpu.c:602
DECLSPEC void SDLCALL GPU_SetTargetRGB(GPU_Target *target, Uint8 r, Uint8 g, Uint8 b)
Definition: SDL_gpu.c:1754
DECLSPEC void SDLCALL GPU_SetTargetRGBA(GPU_Target *target, Uint8 r, Uint8 g, Uint8 b, Uint8 a)
Definition: SDL_gpu.c:1769
GPU_ComparisonEnum
Definition: SDL_gpu.h:183
DECLSPEC GPU_Target *SDLCALL GPU_LoadTarget(GPU_Image *image)
Definition: SDL_gpu.c:1369
DECLSPEC void SDLCALL GPU_UnsetTargetColor(GPU_Target *target)
Definition: SDL_gpu.c:1784
Definition: SDL_gpu.h:710
Definition: SDL_gpu.h:700
Definition: SDL_gpu.h:227
Definition: SDL_gpu.h:380
Definition: SDL_gpu.h:427
int stored_window_w
Definition: SDL_gpu.h:451
GPU_Target * active_target
Definition: SDL_gpu.h:432
int drawable_w
Definition: SDL_gpu.h:447
Uint32 windowID
Definition: SDL_gpu.h:440
Uint32 default_textured_vertex_shader_id
Definition: SDL_gpu.h:455
Uint32 current_shader_program
Definition: SDL_gpu.h:463
int window_w
Definition: SDL_gpu.h:443
void * context
Definition: SDL_gpu.h:429
Definition: SDL_gpu.h:743
Definition: SDL_gpu.h:334
Definition: SDL_gpu.h:417
Definition: SDL_gpu.h:138
Definition: SDL_gpu.h:168
Definition: SDL_gpu_RendererImpl.h:17
Uint32(SDLCALL *CreateShaderProgram)(GPU_Renderer *renderer)
SDL_Color(SDLCALL *GetPixel)(GPU_Renderer *renderer
Definition: SDL_gpu.h:782
GPU_bool coordinate_mode
Definition: SDL_gpu.h:804
float default_image_anchor_x
Definition: SDL_gpu.h:798
GPU_Target * current_context_target
Definition: SDL_gpu.h:795
GPU_RendererID id
Definition: SDL_gpu.h:784
Definition: SDL_gpu.h:397
Definition: SDL_gpu.h:493
int matrix_mode
Definition: SDL_gpu.h:506
GPU_Context * context
Definition: SDL_gpu.h:522