Skip to content

Commit

Permalink
Move back the spline uniforms
Browse files Browse the repository at this point in the history
  • Loading branch information
hrydgard committed Apr 1, 2017
1 parent 7a20652 commit 1380e70
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions GPU/Common/ShaderUniforms.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@ struct UB_VS_FS_Base {
float depthRange[4];
float fogCoef_stencil[4];
float matAmbient[4];
int spline_count_u;
int spline_count_v;
int spline_type_u;
int spline_type_v;
// Fragment data
float fogColor[4];
float texEnvColor[4];
Expand All @@ -39,10 +43,6 @@ struct UB_VS_FS_Base {
float blendFixB[4];
float texClamp[4];
float texClampOffset[4];
int spline_count_u;
int spline_count_v;
int spline_type_u;
int spline_type_v;
};

static const char *ub_baseStr =
Expand All @@ -55,6 +55,10 @@ R"( mat4 proj_mtx;
vec4 depthRange;
vec3 fogcoef_stencilreplace;
vec4 matambientalpha;
int spline_count_u;
int spline_count_v;
int spline_type_u;
int spline_type_v;
vec3 fogcolor; float nanValue;
vec3 texenv;
ivec4 alphacolorref;
Expand All @@ -63,10 +67,6 @@ R"( mat4 proj_mtx;
vec3 blendFixB;
vec4 texclamp;
vec2 texclampoff;
int spline_count_u;
int spline_count_v;
int spline_type_u;
int spline_type_v;
)";

// HLSL code is shared so these names are changed to match those in DX9.
Expand All @@ -80,6 +80,10 @@ R"( float4x4 u_proj;
float4 u_depthRange;
float3 u_fogcoef_stencilreplace;
float4 u_matambientalpha;
int u_spline_count_u;
int u_spline_count_v;
int u_spline_type_u;
int u_spline_type_v;
float3 u_fogcolor; float nanValue;
float3 u_texenv;
uint4 u_alphacolorref;
Expand All @@ -88,10 +92,6 @@ R"( float4x4 u_proj;
float3 u_blendFixB;
float4 u_texclamp;
float2 u_texclampoff;
int u_spline_count_u;
int u_spline_count_v;
int u_spline_type_u;
int u_spline_type_v;
)";

// 576 bytes. Can we get down to 512?
Expand Down

0 comments on commit 1380e70

Please sign in to comment.