some more GLES hackage

This commit is contained in:
aap
2020-05-13 20:46:27 +02:00
parent 582d202ce5
commit 6c7d811096
14 changed files with 278 additions and 17 deletions

View File

@@ -82,5 +82,5 @@ float DoFog(float w)
}
#define DIRECTIONALS
#define POINTLIGHTS
#define SPOTLIGHTS
//#define POINTLIGHTS
//#define SPOTLIGHTS

View File

@@ -83,6 +83,6 @@ const char *header_vert_src =
"}\n"
"#define DIRECTIONALS\n"
"#define POINTLIGHTS\n"
"#define SPOTLIGHTS\n"
"//#define POINTLIGHTS\n"
"//#define SPOTLIGHTS\n"
;

View File

@@ -12,6 +12,7 @@ void
main(void)
{
gl_Position = in_pos;
gl_Position.w = 1.0;
gl_Position.xy = gl_Position.xy * u_xform.xy + u_xform.zw;
v_fog = DoFog(gl_Position.z);
gl_Position.xyz *= gl_Position.w;

View File

@@ -13,6 +13,7 @@ const char *im2d_vert_src =
"main(void)\n"
"{\n"
" gl_Position = in_pos;\n"
" gl_Position.w = 1.0;\n"
" gl_Position.xy = gl_Position.xy * u_xform.xy + u_xform.zw;\n"
" v_fog = DoFog(gl_Position.z);\n"
" gl_Position.xyz *= gl_Position.w;\n"