@ -2615,8 +2615,6 @@ template<FlatGL2D::Flag flag> void FlatGLTest::renderInstanced2D() {
. setSubImage ( 0 , { image - > size ( ) . x ( ) / 2 , 0 , 3 } , second )
. setSubImage ( 0 , { image - > size ( ) . x ( ) / 2 , 0 , 3 } , second )
. setSubImage ( 0 , { 0 , 0 , 4 } , third ) ;
. setSubImage ( 0 , { 0 , 0 , 4 } , third ) ;
shader . bindTexture ( textureArray ) ;
shader . bindTexture ( textureArray ) ;
if ( flag ! = FlatGL2D : : Flag : : UniformBuffers )
shader . setTextureLayer ( 2 ) ; /* base offset */
} else
} else
# endif
# endif
@ -2647,6 +2645,11 @@ template<FlatGL2D::Flag flag> void FlatGLTest::renderInstanced2D() {
Vector2 { 0.5f }
Vector2 { 0.5f }
) ) ;
) ) ;
# ifndef MAGNUM_TARGET_GLES2
if ( data . flags & FlatGL2D : : Flag : : TextureArrays )
shader . setTextureLayer ( 2 ) ; /* base offset */
# endif
# ifndef MAGNUM_TARGET_GLES2
# ifndef MAGNUM_TARGET_GLES2
if ( data . flags & FlatGL2D : : Flag : : ObjectId ) {
if ( data . flags & FlatGL2D : : Flag : : ObjectId ) {
/* Gets added to the per-instance ID, if that's enabled as well */
/* Gets added to the per-instance ID, if that's enabled as well */
@ -2879,8 +2882,6 @@ template<FlatGL3D::Flag flag> void FlatGLTest::renderInstanced3D() {
. setSubImage ( 0 , { image - > size ( ) . x ( ) / 2 , 0 , 3 } , second )
. setSubImage ( 0 , { image - > size ( ) . x ( ) / 2 , 0 , 3 } , second )
. setSubImage ( 0 , { 0 , 0 , 4 } , third ) ;
. setSubImage ( 0 , { 0 , 0 , 4 } , third ) ;
shader . bindTexture ( textureArray ) ;
shader . bindTexture ( textureArray ) ;
if ( flag ! = FlatGL2D : : Flag : : UniformBuffers )
shader . setTextureLayer ( 2 ) ; /* base offset */
} else
} else
# endif
# endif
@ -2912,6 +2913,11 @@ template<FlatGL3D::Flag flag> void FlatGLTest::renderInstanced3D() {
Vector2 { 0.5f }
Vector2 { 0.5f }
) ) ;
) ) ;
# ifndef MAGNUM_TARGET_GLES2
if ( data . flags & FlatGL3D : : Flag : : TextureArrays )
shader . setTextureLayer ( 2 ) ; /* base offset */
# endif
# ifndef MAGNUM_TARGET_GLES2
# ifndef MAGNUM_TARGET_GLES2
if ( data . flags & FlatGL3D : : Flag : : ObjectId ) {
if ( data . flags & FlatGL3D : : Flag : : ObjectId ) {
/* Gets added to the per-instance ID, if that's enabled as well */
/* Gets added to the per-instance ID, if that's enabled as well */