Removed the mutable from the _image variable

This commit is contained in:
Robert Osfield
2008-04-23 20:49:19 +00:00
parent a59e93a0df
commit 77b98eb5f8
2 changed files with 1 additions and 9 deletions

View File

@@ -135,10 +135,6 @@ class OSG_EXPORT Texture2D : public Texture
void allocateMipmap(State& state) const;
/** It's not ideal that _image is mutable, but it's required since
* Image::ensureDimensionsArePowerOfTwo() can only be called in a
* valid OpenGL context, and therefore within Texture::apply, which
* is const. */
ref_ptr<Image> _image;
/** Subloaded images can have different texture and image sizes. */

View File

@@ -134,11 +134,7 @@ class OSG_EXPORT TextureRectangle : public Texture
void applyTexImage_load(GLenum target, Image* image, State& state, GLsizei& inwidth, GLsizei& inheight) const;
void applyTexImage_subload(GLenum target, Image* image, State& state, GLsizei& inwidth, GLsizei& inheight, GLint& inInternalFormat) const;
// not ideal that _image is mutable, but it's required since
// Image::ensureDimensionsArePowerOfTwo() can only be called
// in a valid OpenGL context, and therefore within an Texture::apply
// which is const...
mutable ref_ptr<Image> _image;
ref_ptr<Image> _image;
// subloaded images can have different texture and image sizes.
mutable GLsizei _textureWidth, _textureHeight;