Add texture seamless cubemap enabled state

This commit is contained in:
baldurk
2015-01-17 18:49:09 +00:00
parent 8b91c8540b
commit f607f9832e
3 changed files with 11 additions and 1 deletions
+2 -1
View File
@@ -117,7 +117,7 @@ struct GLPipelineState
{
Sampler()
: Samp(), MaxAniso(0.0f), MaxLOD(0.0f), MinLOD(0.0f), MipLODBias(0.0f)
, UseBorder(false), UseComparison(false)
, UseBorder(false), UseComparison(false), SeamlessCube(false)
{ BorderColor[0] = BorderColor[1] = BorderColor[2] = BorderColor[3] = 0.0f; }
ResourceId Samp;
rdctype::str AddressS, AddressT, AddressR;
@@ -127,6 +127,7 @@ struct GLPipelineState
rdctype::str MagFilter;
bool32 UseBorder;
bool32 UseComparison;
bool32 SeamlessCube;
float MaxAniso;
float MaxLOD;
float MinLOD;
+8
View File
@@ -1358,6 +1358,13 @@ void GLReplay::SavePipelineState()
pipe.Samplers[unit].AddressR = SamplerString((GLenum)v);
pipe.Samplers[unit].UseBorder |= (v == eGL_CLAMP_TO_BORDER);
v=0;
if(samp != 0)
gl.glGetSamplerParameteriv(samp, eGL_TEXTURE_CUBE_MAP_SEAMLESS, &v);
else
gl.glGetTexParameteriv(target, eGL_TEXTURE_CUBE_MAP_SEAMLESS, &v);
pipe.Samplers[unit].SeamlessCube = (v != 0 || rs.Enabled[GLRenderState::eEnabled_TexCubeSeamless]);
v=0;
if(samp != 0)
gl.glGetSamplerParameteriv(samp, eGL_TEXTURE_COMPARE_FUNC, &v);
@@ -1400,6 +1407,7 @@ void GLReplay::SavePipelineState()
pipe.Samplers[unit].MagFilter = "";
pipe.Samplers[unit].UseBorder = false;
pipe.Samplers[unit].UseComparison = false;
pipe.Samplers[unit].SeamlessCube = false;
pipe.Samplers[unit].MaxAniso = 0.0f;
pipe.Samplers[unit].MaxLOD = 0.0f;
pipe.Samplers[unit].MinLOD = 0.0f;
+1
View File
@@ -138,6 +138,7 @@ namespace renderdoc
public string MagFilter;
public bool UseBorder;
public bool UseComparison;
public bool SeamlessCube;
public float MaxAniso;
public float MaxLOD;
public float MinLOD;