Texture state class which encapsulates OpenGL texture functionality
Inheritance:
Public Methods
-
TextureRectangle()
-
TextureRectangle(const TextureRectangle& text, const CopyOp& copyop=CopyOp::SHALLOW_COPY)
- Copy constructor using CopyOp to manage deep vs shallow copy
-
META_StateAttribute(osg, TextureRectangle, TEXTURE)
-
virtual int compare(const StateAttribute& rhs) const
- return -1 if *this < *rhs, 0 if *this==*rhs, 1 if *this>*rhs
-
virtual void getAssociatedModes(std::vector<GLMode>& modes) const
-
void setImage(Image* image)
- Set the texture image.
-
Image* getImage()
- Get the texture image.
-
inline const Image* getImage() const
- Get the const texture image.
-
inline unsigned int& getModifiedTag(unsigned int contextID) const
-
inline void setTextureSize(int width, int height) const
- Set the texture width and height.
-
inline void getTextureSize(int& width, int& height) const
- Get the texture subload width.
-
void setSubloadCallback(SubloadCallback* cb)
-
SubloadCallback* getSubloadCallback()
-
const SubloadCallback* getSubloadCallback() const
-
virtual void apply(State& state) const
- On first apply (unless already compiled), create and bind the texture, subsequent apply will simple bind to texture
Public Members
-
class SubloadCallback: public Referenced
Protected Fields
-
mutable ref_ptr<Image> _image
-
mutable GLsizei _textureWidth
-
mutable GLsizei _textureHeight
-
ref_ptr<SubloadCallback> _subloadCallback
-
mutable ImageModifiedTag _modifiedTag
Protected Methods
-
virtual ~TextureRectangle()
-
virtual void computeInternalFormat() const
-
void applyTexParameters(GLenum target, State& state) const
-
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) const
Protected Members
-
typedef buffered_value<unsigned int> ImageModifiedTag
Inherited from Texture:
Public Fields
-
mutable TextureObjectBuffer _textureObjectBuffer
Public Methods
-
virtual osg::Object* cloneType() const
-
virtual osg::Object* clone(const CopyOp& copyop) const
-
virtual bool isSameKindAs(const osg::Object* obj) const
-
virtual const char* libraryName() const
-
virtual const char* className() const
-
virtual Type getType() const
-
virtual bool isTextureAttribute() const
-
void setWrap(WrapParameter which, WrapMode wrap)
-
WrapMode getWrap(WrapParameter which) const
-
void setBorderColor(const Vec4& color)
-
const Vec4& getBorderColor() const
-
void setFilter(FilterParameter which, FilterMode filter)
-
FilterMode getFilter(FilterParameter which) const
-
void setMaxAnisotropy(float anis)
-
inline float getMaxAnisotropy() const
-
inline void setUseHardwareMipMapGeneration(bool useHardwareMipMapGeneration)
-
inline bool getUseHardwareMipMapGeneration() const
-
inline void setUnRefImageDataAfterApply(bool flag)
-
inline bool getUnRefImageDataAfterApply() const
-
inline void setInternalFormatMode(InternalFormatMode mode)
-
inline InternalFormatMode getInternalFormatMode() const
-
inline void setInternalFormat(GLint internalFormat)
-
inline GLint getInternalFormat() const
-
bool isCompressedInternalFormat() const
-
inline TextureObject* getTextureObject(unsigned int contextID) const
-
void dirtyTextureObject()
-
bool areAllTextureObjectsLoaded() const
-
inline unsigned int& getTextureParameterDirty(unsigned int contextID) const
-
void dirtyTextureParameters()
-
virtual void compile(State& state) const
-
static Extensions* getExtensions(unsigned int contextID, bool createIfNotInitalized)
-
static void setExtensions(unsigned int contextID, Extensions* extensions)
-
void applyTexImage2D_load(State& state, GLenum target, const Image* image, GLsizei width, GLsizei height, GLsizei numMipmapLevels) const
-
void applyTexImage2D_subload(State& state, GLenum target, const Image* image, GLsizei width, GLsizei height, GLsizei numMipmapLevels) const
-
void takeTextureObjects(TextureObjectListMap& toblm)
-
static void setTextureObjectManager(TextureObjectManager* tom)
-
static TextureObjectManager* getTextureObjectManager()
-
static void flushTextureObjects(unsigned int contextID, double currentTime, double& availableTime)
Public Members
-
enum WrapParameter
-
enum WrapMode
-
enum FilterParameter
-
enum FilterMode
-
enum InternalFormatMode
-
class SG_EXPORT Extensions: public osg::Referenced
- Extensions class which encapsulates the querring of extensions and associated function pointers, and provide convinience wrappers to check for the extensions or use the associated functions
-
class TextureObject: public osg::Referenced
-
typedef std::list< ref_ptr<TextureObject> > TextureObjectList
-
typedef std::map<unsigned int, TextureObjectList > TextureObjectListMap
-
typedef buffered_object< ref_ptr<TextureObject> > TextureObjectBuffer
-
class SG_EXPORT TextureObjectManager: public osg::Referenced
Protected Fields
-
mutable TexParameterDirtyList _texParametersDirtyList
-
WrapMode _wrap_s
-
WrapMode _wrap_t
-
WrapMode _wrap_r
-
FilterMode _min_filter
-
FilterMode _mag_filter
-
float _maxAnisotropy
-
bool _useHardwareMipMapGeneration
-
bool _unrefImageDataAfterApply
-
Vec4 _borderColor
-
InternalFormatMode _internalFormatMode
-
mutable GLint _internalFormat
Protected Methods
-
void computeInternalFormatWithImage(const osg::Image& image) const
-
void computeRequiredTextureDimensions(State& state, const osg::Image& image, GLsizei& width, GLsizei& height, GLsizei& numMipmapLevels) const
-
bool isCompressedInternalFormat(GLint internalFormat) const
-
int compareTexture(const Texture& rhs) const
Protected Members
-
typedef buffered_value<unsigned int> TexParameterDirtyList
Public Methods
-
bool operator < (const StateAttribute& rhs) const
-
bool operator == (const StateAttribute& rhs) const
-
bool operator != (const StateAttribute& rhs) const
Public Members
-
typedef GLenum GLMode
-
typedef unsigned int GLModeValue
-
typedef unsigned int OverrideValue
-
enum Values
-
typedef unsigned int Type
-
enum Types
Inherited from Object:
Public Methods
-
inline void setDataVariance(DataVariance dv)
-
inline DataVariance getDataVariance() const
-
inline void setUserData(Referenced* obj)
-
inline Referenced* getUserData()
-
inline const Referenced* getUserData() const
Public Members
-
enum DataVariance
Protected Fields
-
DataVariance _dataVariance
-
ref_ptr<Referenced> _userData
Public Methods
-
inline Referenced& operator = (Referenced&)
-
static void setDeleteHandler(DeleteHandler* handler)
-
static DeleteHandler* getDeleteHandler()
-
inline void ref() const
-
inline void unref_nodelete() const
-
inline int referenceCount() const
-
inline void unref() const
Protected Fields
-
mutable int _refCount
Documentation
Texture state class which encapsulates OpenGL texture functionality
- TextureRectangle()
- TextureRectangle(const TextureRectangle& text, const CopyOp& copyop=CopyOp::SHALLOW_COPY)
- Copy constructor using CopyOp to manage deep vs shallow copy
- META_StateAttribute(osg, TextureRectangle, TEXTURE)
- virtual int compare(const StateAttribute& rhs) const
- return -1 if *this < *rhs, 0 if *this==*rhs, 1 if *this>*rhs
- virtual void getAssociatedModes(std::vector<GLMode>& modes) const
- void setImage(Image* image)
- Set the texture image.
- Image* getImage()
- Get the texture image.
- inline const Image* getImage() const
- Get the const texture image.
- inline unsigned int& getModifiedTag(unsigned int contextID) const
- inline void setTextureSize(int width, int height) const
- Set the texture width and height. If width or height are zero then
the repsective size value is calculated from the source image sizes.
- inline void getTextureSize(int& width, int& height) const
- Get the texture subload width.
- void setSubloadCallback(SubloadCallback* cb)
- SubloadCallback* getSubloadCallback()
- const SubloadCallback* getSubloadCallback() const
- virtual void apply(State& state) const
- On first apply (unless already compiled), create and bind the
texture, subsequent apply will simple bind to texture
- virtual ~TextureRectangle()
- virtual void computeInternalFormat() const
- void applyTexParameters(GLenum target, State& state) const
- 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) const
- mutable ref_ptr<Image> _image
- mutable GLsizei _textureWidth
- mutable GLsizei _textureHeight
- ref_ptr<SubloadCallback> _subloadCallback
- typedef buffered_value<unsigned int> ImageModifiedTag
- mutable ImageModifiedTag _modifiedTag
- This class has no child classes.
Alphabetic index HTML hierarchy of classes or Java
This page was generated with the help of DOC++.