mirror of
https://github.com/lubosz/overte.git
synced 2025-08-07 17:41:12 +02:00
Revert max input slot changes
This commit is contained in:
parent
38a223b270
commit
9e8a3f19e9
4 changed files with 7 additions and 3 deletions
|
@ -193,7 +193,7 @@ public:
|
||||||
|
|
||||||
|
|
||||||
static const int MAX_NUM_ATTRIBUTES = Stream::NUM_INPUT_SLOTS;
|
static const int MAX_NUM_ATTRIBUTES = Stream::NUM_INPUT_SLOTS;
|
||||||
static const int MAX_NUM_INPUT_BUFFERS = Stream::NUM_INPUT_SLOTS;
|
static const int MAX_NUM_INPUT_BUFFERS = 16;
|
||||||
|
|
||||||
size_t getNumInputBuffers() const { return _input._invalidBuffers.size(); }
|
size_t getNumInputBuffers() const { return _input._invalidBuffers.size(); }
|
||||||
|
|
||||||
|
|
|
@ -103,6 +103,8 @@ void makeBindings(GLBackend::GLShader* shader) {
|
||||||
glUniformBlockBinding(glprogram, loc, gpu::TRANSFORM_CAMERA_SLOT);
|
glUniformBlockBinding(glprogram, loc, gpu::TRANSFORM_CAMERA_SLOT);
|
||||||
shader->_transformCameraSlot = gpu::TRANSFORM_CAMERA_SLOT;
|
shader->_transformCameraSlot = gpu::TRANSFORM_CAMERA_SLOT;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
(void)CHECK_GL_ERROR();
|
||||||
}
|
}
|
||||||
|
|
||||||
GLBackend::GLShader* compileShader(const Shader& shader) {
|
GLBackend::GLShader* compileShader(const Shader& shader) {
|
||||||
|
|
|
@ -173,7 +173,7 @@ void GLBackend::TransformStageState::update(size_t commandIndex, const StereoSta
|
||||||
offset += _cameraUboSize;
|
offset += _cameraUboSize;
|
||||||
}
|
}
|
||||||
glBindBufferRange(GL_UNIFORM_BUFFER, TRANSFORM_CAMERA_SLOT,
|
glBindBufferRange(GL_UNIFORM_BUFFER, TRANSFORM_CAMERA_SLOT,
|
||||||
_cameraBuffer, offset, sizeof(Backend::TransformCamera));
|
_cameraBuffer, offset, sizeof(Backend::TransformCamera));
|
||||||
}
|
}
|
||||||
|
|
||||||
glBindBufferBase(GL_SHADER_STORAGE_BUFFER, TRANSFORM_OBJECT_SLOT, _objectBuffer);
|
glBindBufferBase(GL_SHADER_STORAGE_BUFFER, TRANSFORM_OBJECT_SLOT, _objectBuffer);
|
||||||
|
@ -196,6 +196,8 @@ void GLBackend::updateTransform(const Batch& batch) {
|
||||||
_transform._drawCallInfoOffsets[batch._currentNamedCall]);
|
_transform._drawCallInfoOffsets[batch._currentNamedCall]);
|
||||||
glVertexAttribDivisor(gpu::Stream::DRAW_CALL_INFO, 1);
|
glVertexAttribDivisor(gpu::Stream::DRAW_CALL_INFO, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
(void)CHECK_GL_ERROR();
|
||||||
}
|
}
|
||||||
|
|
||||||
void GLBackend::resetTransformStage() {
|
void GLBackend::resetTransformStage() {
|
||||||
|
|
|
@ -39,10 +39,10 @@ public:
|
||||||
TEXCOORD1 = 7,
|
TEXCOORD1 = 7,
|
||||||
INSTANCE_SCALE = 8,
|
INSTANCE_SCALE = 8,
|
||||||
INSTANCE_TRANSLATE = 9,
|
INSTANCE_TRANSLATE = 9,
|
||||||
|
NUM_INPUT_SLOTS = INSTANCE_TRANSLATE + 1,
|
||||||
|
|
||||||
|
|
||||||
DRAW_CALL_INFO = 15, // Reserve last input slot for draw call infos
|
DRAW_CALL_INFO = 15, // Reserve last input slot for draw call infos
|
||||||
NUM_INPUT_SLOTS = DRAW_CALL_INFO
|
|
||||||
};
|
};
|
||||||
|
|
||||||
typedef uint8 Slot;
|
typedef uint8 Slot;
|
||||||
|
|
Loading…
Reference in a new issue