Browse Source

Hide fallback texture storage implementation from ES3 builds.

Not needed there.
pull/107/head
Vladimír Vondruš 11 years ago
parent
commit
edb7d680fc
  1. 6
      src/Magnum/AbstractTexture.cpp
  2. 6
      src/Magnum/AbstractTexture.h

6
src/Magnum/AbstractTexture.cpp

@ -467,6 +467,7 @@ void AbstractTexture::bindInternal() {
glBindTexture(_target, _id);
}
#if !defined(MAGNUM_TARGET_GLES) || defined(MAGNUM_TARGET_GLES2)
ColorFormat AbstractTexture::imageFormatForInternalFormat(const TextureFormat internalFormat) {
switch(internalFormat) {
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
@ -971,6 +972,7 @@ ColorType AbstractTexture::imageTypeForInternalFormat(const TextureFormat intern
CORRADE_ASSERT_UNREACHABLE();
}
#endif
void AbstractTexture::parameterImplementationDefault(GLenum parameter, GLint value) {
bindInternal();
@ -1131,7 +1133,7 @@ void AbstractTexture::storageImplementationDSAEXT(GLsizei levels, TextureFormat
}
#endif
#if !defined(MAGNUM_TARGET_WEBGL) || defined(MAGNUM_TARGET_GLES2)
#if !defined(MAGNUM_TARGET_GLES) || defined(MAGNUM_TARGET_GLES2)
void AbstractTexture::storageImplementationFallback(const GLsizei levels, const TextureFormat internalFormat, const Vector2i& size) {
const ColorFormat format = imageFormatForInternalFormat(internalFormat);
const ColorType type = imageTypeForInternalFormat(internalFormat);
@ -1200,7 +1202,7 @@ void AbstractTexture::storageImplementationDSAEXT(GLsizei levels, TextureFormat
}
#endif
#ifndef MAGNUM_TARGET_WEBGL
#if !defined(MAGNUM_TARGET_GLES) || (defined(MAGNUM_TARGET_GLES2) && !defined(MAGNUM_TARGET_WEBGL))
void AbstractTexture::storageImplementationFallback(GLsizei levels, TextureFormat internalFormat, const Vector3i& size) {
const ColorFormat format = imageFormatForInternalFormat(internalFormat);
const ColorType type = imageTypeForInternalFormat(internalFormat);

6
src/Magnum/AbstractTexture.h

@ -487,7 +487,7 @@ class MAGNUM_EXPORT AbstractTexture: public AbstractObject {
void MAGNUM_LOCAL storageImplementationDSAEXT(GLsizei levels, TextureFormat internalFormat, const Math::Vector<1, GLsizei>& size);
#endif
#if !defined(MAGNUM_TARGET_WEBGL) || defined(MAGNUM_TARGET_GLES2)
#if !defined(MAGNUM_TARGET_GLES) || defined(MAGNUM_TARGET_GLES2)
void MAGNUM_LOCAL storageImplementationFallback(GLsizei levels, TextureFormat internalFormat, const Vector2i& size);
#endif
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
@ -498,7 +498,7 @@ class MAGNUM_EXPORT AbstractTexture: public AbstractObject {
void MAGNUM_LOCAL storageImplementationDSAEXT(GLsizei levels, TextureFormat internalFormat, const Vector2i& size);
#endif
#ifndef MAGNUM_TARGET_WEBGL
#if !defined(MAGNUM_TARGET_GLES) || (defined(MAGNUM_TARGET_GLES2) && !defined(MAGNUM_TARGET_WEBGL))
void MAGNUM_LOCAL storageImplementationFallback(GLsizei levels, TextureFormat internalFormat, const Vector3i& size);
#endif
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
@ -576,8 +576,10 @@ class MAGNUM_EXPORT AbstractTexture: public AbstractObject {
void MAGNUM_LOCAL invalidateSubImageImplementationARB(GLint level, const Vector3i& offset, const Vector3i& size);
#endif
#if !defined(MAGNUM_TARGET_GLES) || defined(MAGNUM_TARGET_GLES2)
ColorFormat MAGNUM_LOCAL imageFormatForInternalFormat(TextureFormat internalFormat);
ColorType MAGNUM_LOCAL imageTypeForInternalFormat(TextureFormat internalFormat);
#endif
GLuint _id;
ObjectFlags _flags;

Loading…
Cancel
Save