mirror of
https://github.com/luanti-org/luanti.git
synced 2025-11-20 08:25:23 +01:00
Dynamic shadows with the ogles2 driver on OpenGL ES 3.0+ (#16661)
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
#else
|
||||
uniform sampler2D baseTexture;
|
||||
#endif
|
||||
varying vec4 tPos;
|
||||
VARYING_ vec4 tPos;
|
||||
|
||||
CENTROID_ VARYING_ mediump vec2 varTexCoord;
|
||||
CENTROID_ VARYING_ float varTexLayer; // actually int
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
uniform mat4 LightMVP; // world matrix
|
||||
uniform vec4 CameraPos; // camera position
|
||||
varying vec4 tPos;
|
||||
VARYING_ vec4 tPos;
|
||||
|
||||
uniform float xyPerspectiveBias0;
|
||||
uniform float xyPerspectiveBias1;
|
||||
|
||||
@@ -3,13 +3,13 @@
|
||||
#else
|
||||
uniform sampler2D baseTexture;
|
||||
#endif
|
||||
varying vec4 tPos;
|
||||
VARYING_ vec4 tPos;
|
||||
|
||||
CENTROID_ VARYING_ mediump vec2 varTexCoord;
|
||||
CENTROID_ VARYING_ float varTexLayer; // actually int
|
||||
|
||||
#ifdef COLORED_SHADOWS
|
||||
varying vec3 varColor;
|
||||
VARYING_ vec3 varColor;
|
||||
|
||||
// c_precision of 128 fits within 7 base-10 digits
|
||||
const float c_precision = 128.0;
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
uniform mat4 LightMVP; // world matrix
|
||||
uniform vec4 CameraPos;
|
||||
varying vec4 tPos;
|
||||
VARYING_ vec4 tPos;
|
||||
#ifdef COLORED_SHADOWS
|
||||
varying vec3 varColor;
|
||||
VARYING_ vec3 varColor;
|
||||
#endif
|
||||
|
||||
uniform float xyPerspectiveBias0;
|
||||
|
||||
@@ -4,11 +4,7 @@ uniform sampler2D ShadowMapClientMapTraslucent;
|
||||
#endif
|
||||
uniform sampler2D ShadowMapSamplerdynamic;
|
||||
|
||||
#ifdef GL_ES
|
||||
varying mediump vec2 varTexCoord;
|
||||
#else
|
||||
centroid varying vec2 varTexCoord;
|
||||
#endif
|
||||
CENTROID_ VARYING_ mediump vec2 varTexCoord;
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
@@ -1,8 +1,4 @@
|
||||
#ifdef GL_ES
|
||||
varying mediump vec2 varTexCoord;
|
||||
#else
|
||||
centroid varying vec2 varTexCoord;
|
||||
#endif
|
||||
CENTROID_ VARYING_ mediump vec2 varTexCoord;
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user