diff --git a/include/osg/BufferIndexBinding b/include/osg/BufferIndexBinding index 782022837..eb1d30228 100644 --- a/include/osg/BufferIndexBinding +++ b/include/osg/BufferIndexBinding @@ -201,29 +201,6 @@ class OSG_EXPORT ShaderStorageBufferBinding : public BufferIndexBinding } }; -class OSG_EXPORT DrawIndirectBufferBinding : public BufferIndexBinding -{ - public: - DrawIndirectBufferBinding(); - /** Create a binding for a uniform buffer index target. - * @param bo associated buffer object - */ - DrawIndirectBufferBinding( BufferObject* bo); - void apply(State& state) const; - DrawIndirectBufferBinding(const DrawIndirectBufferBinding& rhs, const CopyOp& copyop=CopyOp::SHALLOW_COPY); - - META_StateAttribute(osg, DrawIndirectBufferBinding, INDIRECTDRAWBUFFERBINDING); - - virtual int compare(const StateAttribute& bb) const - { - COMPARE_StateAttribute_Types(DrawIndirectBufferBinding, bb) - COMPARE_StateAttribute_Parameter(_target) - COMPARE_StateAttribute_Parameter(_bufferObject) - return 0; - } -}; - - } // namespace osg #endif diff --git a/src/osg/BufferIndexBinding.cpp b/src/osg/BufferIndexBinding.cpp index 739025fc0..ffbf451a1 100644 --- a/src/osg/BufferIndexBinding.cpp +++ b/src/osg/BufferIndexBinding.cpp @@ -18,10 +18,6 @@ #include // for memcpy -#ifndef GL_DRAW_INDIRECT_BUFFER - #define GL_DRAW_INDIRECT_BUFFER 0x8F3F -#endif - namespace osg { BufferIndexBinding::BufferIndexBinding(GLenum target, GLuint index) @@ -172,37 +168,4 @@ ShaderStorageBufferBinding::ShaderStorageBufferBinding(const ShaderStorageBuffer { } - - - - -DrawIndirectBufferBinding::DrawIndirectBufferBinding( ) - : BufferIndexBinding(GL_DRAW_INDIRECT_BUFFER, 0) -{ -} -void DrawIndirectBufferBinding::apply(State& state) const -{ - if (_bufferObject.valid()) - { - GLBufferObject* glObject - = _bufferObject->getOrCreateGLBufferObject(state.getContextID()); - if (!glObject->_extensions->isUniformBufferObjectSupported) - return; - // if (glObject->isDirty()) glObject->compileBuffer(); - glObject->_extensions->glBindBuffer (_target, glObject->getGLObjectID()); - } -} -DrawIndirectBufferBinding::DrawIndirectBufferBinding( BufferObject* bo) - : BufferIndexBinding(GL_DRAW_INDIRECT_BUFFER, 0, bo, 0, 0) -{ - -} - -DrawIndirectBufferBinding::DrawIndirectBufferBinding(const DrawIndirectBufferBinding& rhs, - const CopyOp& copyop) - : BufferIndexBinding(rhs, copyop) -{ -} - - } // namespace osg