mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-05-06 01:50:38 +00:00
@@ -1210,7 +1210,7 @@ void GLReplay::FillCBufferVariables(WrappedOpenGL &gl, GLuint prog, bool bufferB
|
||||
|
||||
if(variables[i].type.members.count > 0)
|
||||
{
|
||||
if(desc.elements == 1)
|
||||
if(desc.elements == 0)
|
||||
{
|
||||
vector<ShaderVariable> ov;
|
||||
FillCBufferVariables(gl, prog, bufferBacked, prefix + var.name.elems + ".", variables[i].type.members, ov, data);
|
||||
@@ -1265,7 +1265,7 @@ void GLReplay::FillCBufferVariables(WrappedOpenGL &gl, GLuint prog, bool bufferB
|
||||
values[2] = 1;
|
||||
}
|
||||
|
||||
if(desc.elements == 1)
|
||||
if(desc.elements == 0)
|
||||
{
|
||||
FillCBufferValue(gl, prog, bufferBacked, desc.rowMajorStorage ? true : false,
|
||||
values[0], values[1], data, var);
|
||||
|
||||
@@ -81,6 +81,7 @@ size_t GetByteSize(GLsizei w, GLsizei h, GLsizei d, GLenum format, GLenum type,
|
||||
case eGL_UNSIGNED_INT_10_10_10_2:
|
||||
case eGL_UNSIGNED_INT_2_10_10_10_REV:
|
||||
case eGL_UNSIGNED_INT_10F_11F_11F_REV:
|
||||
case eGL_UNSIGNED_INT_5_9_9_9_REV:
|
||||
return ((w*4 + alignAdd) & alignMask)*h*d;
|
||||
case eGL_DEPTH_COMPONENT16:
|
||||
return ((w*2 + alignAdd) & alignMask)*h*d;
|
||||
|
||||
@@ -203,7 +203,7 @@ void MakeShaderReflection(const GLHookSet &gl, GLenum shadType, GLuint sepProg,
|
||||
res.IsUAV = false;
|
||||
res.variableType.descriptor.rows = 1;
|
||||
res.variableType.descriptor.cols = 4;
|
||||
res.variableType.descriptor.elements = 1;
|
||||
res.variableType.descriptor.elements = 0;
|
||||
res.variableType.descriptor.rowMajorStorage = false;
|
||||
res.bindPoint = (int32_t)resources.size();
|
||||
|
||||
@@ -703,8 +703,10 @@ void MakeShaderReflection(const GLHookSet &gl, GLenum shadType, GLuint sepProg,
|
||||
int32_t c = values[1]-1;
|
||||
|
||||
// trim off trailing [0] if it's an array
|
||||
if(values[4] > 1 && var.name[c-3] == '[' && var.name[c-2] == '0' && var.name[c-1] == ']')
|
||||
if(var.name[c-3] == '[' && var.name[c-2] == '0' && var.name[c-1] == ']')
|
||||
var.name.resize(c-3);
|
||||
else
|
||||
var.type.descriptor.elements = 0;
|
||||
|
||||
vector<DynShaderConstant> *parentmembers = &globalUniforms;
|
||||
|
||||
@@ -769,7 +771,7 @@ void MakeShaderReflection(const GLHookSet &gl, GLenum shadType, GLuint sepProg,
|
||||
parentVar.reg.vec = var.reg.vec;
|
||||
parentVar.reg.comp = 0;
|
||||
parentVar.type.descriptor.name = "struct";
|
||||
parentVar.type.descriptor.elements = RDCMAX(1U, uint32_t(arrayIdx+1));
|
||||
parentVar.type.descriptor.elements = isarray ? RDCMAX(1U, uint32_t(arrayIdx+1)) : 0;
|
||||
|
||||
bool found = false;
|
||||
|
||||
|
||||
@@ -159,7 +159,7 @@ bool WrappedOpenGL::Serialise_glGenQueries(GLsizei n, GLuint* ids)
|
||||
if(m_State == READING)
|
||||
{
|
||||
GLuint real = 0;
|
||||
m_Real.glGenSamplers(1, &real);
|
||||
m_Real.glGenQueries(1, &real);
|
||||
|
||||
GLResource res = QueryRes(GetCtx(), real);
|
||||
|
||||
@@ -172,7 +172,7 @@ bool WrappedOpenGL::Serialise_glGenQueries(GLsizei n, GLuint* ids)
|
||||
|
||||
void WrappedOpenGL::glGenQueries(GLsizei count, GLuint *ids)
|
||||
{
|
||||
m_Real.glGenSamplers(count, ids);
|
||||
m_Real.glGenQueries(count, ids);
|
||||
|
||||
for(GLsizei i=0; i < count; i++)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user