OpenGL2: Misc fixes and cleanup
Fix two constants in GLSL shaders. Remove f suffix from float and fix int to float assignment. They were causing shader compile errors in OpenGL ES 2 context. Remove disabling clip plane. Clip plane is unused and never enabled in the opengl2 renderer. Remove disabling it to avoid causing a GL error when using OpenGL 3.2 core profile or OpenGL ES. Make VAO cache vertex stride be size of srfVert_t since that is what is uploaded to the GPU. No behavior change. There is a disabled debug id in srfVert_t though which if enabled changes srfVert_t size.
This commit is contained in:
parent
14cc4cc6cb
commit
39e2113c73
11 changed files with 28 additions and 53 deletions
|
@ -56,5 +56,5 @@ void main()
|
|||
current.y *= 0.0625;
|
||||
#endif
|
||||
|
||||
gl_FragColor = vec4(current, 1.0f);
|
||||
gl_FragColor = vec4(current, 1.0);
|
||||
}
|
||||
|
|
|
@ -61,7 +61,7 @@ float ambientOcclusion(sampler2D depthMap, const vec2 tex, const float zFarDivZN
|
|||
poissonDisc[7] = vec2(-0.5579782, 0.7491854);
|
||||
poissonDisc[8] = vec2(0.7320465, 0.6317794);
|
||||
|
||||
float result = 0;
|
||||
float result = 0.0;
|
||||
|
||||
float sampleZ = getLinearDepth(depthMap, tex, zFarDivZNear);
|
||||
float scaleZ = zFarDivZNear * sampleZ;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue