@ -31,10 +31,10 @@
*/
*/
# include <cstddef>
# include <cstddef>
# include <utility>
# include <Corrade/Containers/ArrayView.h>
# include <Corrade/Containers/ArrayView.h>
# include <Corrade/Containers/EnumSet.h>
# include <Corrade/Containers/EnumSet.h>
# include <Corrade/Utility/Assert.h>
# include <Corrade/Utility/Assert.h>
# include <Corrade/Utility/StlForwardTuple.h>
# include "Magnum/Tags.h"
# include "Magnum/Tags.h"
# include "Magnum/GL/AbstractObject.h"
# include "Magnum/GL/AbstractObject.h"
@ -44,6 +44,8 @@
/* For label() / setLabel(), which used to be a std::string. Not ideal for the
/* For label() / setLabel(), which used to be a std::string. Not ideal for the
return type , but at least something . */
return type , but at least something . */
# include <Corrade/Containers/StringStl.h>
# include <Corrade/Containers/StringStl.h>
/* For deprecated bind(..., std::initializer_list<std::tuple>) */
# include <Corrade/Utility/StlForwardTuple.h>
# endif
# endif
namespace Magnum { namespace GL {
namespace Magnum { namespace GL {
@ -766,12 +768,18 @@ class MAGNUM_GL_EXPORT Buffer: public AbstractObject {
* WebGL 1.0 , see particular @ ref Target values for version
* WebGL 1.0 , see particular @ ref Target values for version
* requirements .
* requirements .
*/
*/
static void bind ( Target target , UnsignedInt firstIndex , Containers : : ArrayView < const std : : tu ple< Buffer * , GLintptr , GLsizeiptr > > buffers ) ;
static void bind ( Target target , UnsignedInt firstIndex , Containers : : ArrayView < const Container s: : Tri ple< Buffer * , GLintptr , GLsizeiptr > > buffers ) ;
/** @overload */
/** @overload */
static void bind ( Target target , UnsignedInt firstIndex , std : : initializer_list < std : : tuple < Buffer * , GLintptr , GLsizeiptr > > buffers ) {
static void bind ( Target target , UnsignedInt firstIndex , std : : initializer_list < Containers : : Triple < Buffer * , GLintptr , GLsizeiptr > > buffers ) ;
return bind ( target , firstIndex , Containers : : arrayView ( buffers ) ) ;
}
# ifdef MAGNUM_BUILD_DEPRECATED
/**
* @ m_deprecated_since_latest Use @ ref bind ( Target , UnsignedInt , std : : initializer_list < Containers : : Triple < Buffer * , GLintptr , GLsizeiptr > > )
* instead .
*/
static CORRADE_DEPRECATED ( " use the Containers::Triple overload instead " ) void bind ( Target target , UnsignedInt firstIndex , std : : initializer_list < std : : tuple < Buffer * , GLintptr , GLsizeiptr > > buffers ) ;
# endif
/**
/**
* @ brief Bind buffers to given range of indexed targets
* @ brief Bind buffers to given range of indexed targets
@ -1012,7 +1020,7 @@ class MAGNUM_GL_EXPORT Buffer: public AbstractObject {
* @ note This function is meant to be used only internally from
* @ note This function is meant to be used only internally from
* @ ref AbstractShaderProgram subclasses . See its documentation
* @ ref AbstractShaderProgram subclasses . See its documentation
* for more information .
* for more information .
* @ see @ ref bind ( Target , UnsignedInt , Containers : : ArrayView < const std : : tu ple< Buffer * , GLintptr , GLsizeiptr > > ) ,
* @ see @ ref bind ( Target , UnsignedInt , Containers : : ArrayView < const Container s: : Tri ple< Buffer * , GLintptr , GLsizeiptr > > ) ,
* @ ref maxAtomicCounterBindings ( ) , @ ref maxShaderStorageBindings ( ) ,
* @ ref maxAtomicCounterBindings ( ) , @ ref maxShaderStorageBindings ( ) ,
* @ ref maxUniformBindings ( ) , @ ref shaderStorageOffsetAlignment ( ) ,
* @ ref maxUniformBindings ( ) , @ ref shaderStorageOffsetAlignment ( ) ,
* @ ref uniformOffsetAlignment ( ) , @ ref TransformFeedback : : attachBuffer ( ) ,
* @ ref uniformOffsetAlignment ( ) , @ ref TransformFeedback : : attachBuffer ( ) ,
@ -1337,9 +1345,9 @@ class MAGNUM_GL_EXPORT Buffer: public AbstractObject {
static void MAGNUM_GL_LOCAL bindImplementationMulti ( Target target , GLuint firstIndex , Containers : : ArrayView < Buffer * const > buffers ) ;
static void MAGNUM_GL_LOCAL bindImplementationMulti ( Target target , GLuint firstIndex , Containers : : ArrayView < Buffer * const > buffers ) ;
# endif
# endif
static void MAGNUM_GL_LOCAL bindImplementationFallback ( Target target , GLuint firstIndex , Containers : : ArrayView < const std : : tu ple< Buffer * , GLintptr , GLsizeiptr > > buffers ) ;
static void MAGNUM_GL_LOCAL bindImplementationFallback ( Target target , GLuint firstIndex , Containers : : ArrayView < const Container s: : Tri ple< Buffer * , GLintptr , GLsizeiptr > > buffers ) ;
# ifndef MAGNUM_TARGET_GLES
# ifndef MAGNUM_TARGET_GLES
static void MAGNUM_GL_LOCAL bindImplementationMulti ( Target target , GLuint firstIndex , Containers : : ArrayView < const std : : tu ple< Buffer * , GLintptr , GLsizeiptr > > buffers ) ;
static void MAGNUM_GL_LOCAL bindImplementationMulti ( Target target , GLuint firstIndex , Containers : : ArrayView < const Container s: : Tri ple< Buffer * , GLintptr , GLsizeiptr > > buffers ) ;
# endif
# endif
static void MAGNUM_GL_LOCAL copyImplementationDefault ( Buffer & read , Buffer & write , GLintptr readOffset , GLintptr writeOffset , GLsizeiptr size ) ;
static void MAGNUM_GL_LOCAL copyImplementationDefault ( Buffer & read , Buffer & write , GLintptr readOffset , GLintptr writeOffset , GLsizeiptr size ) ;