All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | List of all members
SurgSim::Graphics::Texture2d Class Referenceabstract

Base class defining the interface for a 2D Graphics Texture. More...

#include <SurgSim/Graphics/Texture2d.h>

Inheritance diagram for SurgSim::Graphics::Texture2d:
Inheritance graph
[legend]
Collaboration diagram for SurgSim::Graphics::Texture2d:
Collaboration graph
[legend]

Public Member Functions

virtual void setSize (int width, int height)=0
 Sets the size of the texture. More...
 
virtual void getSize (int *width, int *height) const =0
 Gets the size of the texture. More...
 
- Public Member Functions inherited from SurgSim::Graphics::Texture
virtual ~Texture ()
 Destructor. More...
 
virtual bool loadImage (const std::string &filePath)=0
 Loads an image into the texture from a file. More...
 
virtual void clearImage ()=0
 Removes the image from the texture. More...
 

Detailed Description

Base class defining the interface for a 2D Graphics Texture.

A 2D Texture has width and height.

Note
Normalized texture coordinates are used to access this texture.

Member Function Documentation

virtual void SurgSim::Graphics::Texture2d::getSize ( int *  width,
int *  height 
) const
pure virtual

Gets the size of the texture.

Parameters
[out]widthWidth of the texture
[out]heightHeight of the texture

Implemented in SurgSim::Graphics::OsgTexture2d.

virtual void SurgSim::Graphics::Texture2d::setSize ( int  width,
int  height 
)
pure virtual

Sets the size of the texture.

Parameters
widthWidth of the texture
heightHeight of the texture
Note
Use this to setup a texture as a render target rather than loading from file.

Implemented in SurgSim::Graphics::OsgTexture2d.


The documentation for this class was generated from the following file: