X-Git-Url: https://harrygodden.com/git/?a=blobdiff_plain;f=fishladder_resources.h;h=4e48534bc82bcf2f6ff0a00d2eb891924d135f67;hb=5276db4a15a6565813bdde22198f8aee4030e56f;hp=e3abf07bd3da513c1a24328f5244fc3829468b97;hpb=313de221328d756742ddc6f52386d9ddae067e7c;p=fishladder.git diff --git a/fishladder_resources.h b/fishladder_resources.h index e3abf07..4e48534 100644 --- a/fishladder_resources.h +++ b/fishladder_resources.h @@ -4,11 +4,10 @@ vg_tex2d tex_tile_data = { .path = "textures/tileset.qoi" }; vg_tex2d tex_tile_detail = { .path = "textures/tile_overlays.qoi" }; vg_tex2d tex_wood = { .path = "textures/wood.qoi" }; -vg_tex2d tex_ball = { .path = "textures/ball.qoi", .flags = VG_TEXTURE_CLAMP }; vg_tex2d tex_background = { .path = "textures/background.qoi" }; vg_tex2d tex_ball_noise = { .path = "textures/bnoise.qoi" }; -vg_tex2d *texture_list[] = { &tex_tile_detail, &tex_tile_data, &tex_wood, &tex_ball, &tex_background, &tex_ball_noise }; +vg_tex2d *texture_list[] = { &tex_tile_detail, &tex_tile_data, &tex_wood, &tex_background, &tex_ball_noise }; // AUDIO // =========================================================================================================== @@ -139,43 +138,6 @@ SHADER_DEFINE( shader_tile_colour, UNIFORMS({ "uPv", "uOffset", "uColour" }) ) -/* -SHADER_DEFINE( shader_ball, - // VERTEX - "layout (location=0) in vec2 a_co;" - "uniform vec2 uOffset;" - "uniform mat3 uPv;" - "" - "out vec2 aTexCoords;" - "" - "void main()" - "{" - // Create texture coords - "aTexCoords = a_co;" - - // Vertex transform - "vec3 worldpos = vec3( a_co * 0.5 - 0.25 + uOffset, 1.0 );" - "gl_Position = vec4( uPv * worldpos, 1.0 );" - "}", - - // FRAGMENT - "out vec4 FragColor;" - "" - "uniform sampler2D uTexMain;" - "uniform vec3 uColour;" - "" - "in vec2 aTexCoords;" - "" - "void main()" - "{" - "vec4 glyph = texture( uTexMain, aTexCoords );" - "FragColor = vec4( uColour + glyph.rgb * 0.2, glyph.a );" - "}" - , - UNIFORMS({ "uTexMain", "uColour", "uOffset", "uPv" }) -) -*/ - SHADER_DEFINE( shader_ball, // VERTEX "layout (location=0) in vec2 a_co;" @@ -217,7 +179,6 @@ SHADER_DEFINE( shader_ball, "vec2 shadow_coords = center_coords + vec2(0.02,0.07);" "vec2 shadow_coords_sqr = shadow_coords*shadow_coords;" - //"float shadow = exp(-abs(shadow_coords_sqr.x+shadow_coords_sqr.y)*20.0);" "float shadow = exp(-((shadow_coords_sqr.x+shadow_coords_sqr.y)-0.0125)*15.0);" "vec3 marble_comp = uColour*0.9 + (noise_sample.x*0.7+pow(rim_light,3.0)*2.0) * 0.1;"