this repo has no description
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Added some more commentary to clarify common.c's load_shader().

+7 -1
+4 -1
common/common.c
··· 97 97 } 98 98 99 99 100 - // Loads a shader and prepends version/compatibility info before compiling it 100 + // Loads a shader and prepends version/compatibility info before compiling it. 101 + // Normally, you can just use GPU_LoadShader() for shader source files or GPU_CompileShader() for strings. 102 + // However, some hardware (certain ATI/AMD cards) does not let you put non-#version preprocessing at the top of the file. 103 + // Therefore, I need to prepend the version info here so I can support both GLSL and GLSLES with one shader file. 101 104 Uint32 load_shader(GPU_ShaderEnum shader_type, const char* filename) 102 105 { 103 106 SDL_RWops* rwops;
+2
common/common.h
··· 2 2 #define _COMMON_H__ 3 3 4 4 #include "SDL_gpu.h" 5 + #include <stdlib.h> 6 + #include <string.h> 5 7 6 8 void printRenderers(void); 7 9 void printCurrentRenderer(void);
+1
demos/tutorial-space/main.c
··· 1 1 #include "SDL_gpu.h" 2 + #include <stdlib.h> 2 3 #include <math.h> 3 4 4 5 #ifndef M_PI