Classes | |
class | Texture2D |
class | Texture3D |
Typedefs | |
typedef boost::shared_ptr < Texture2D > | texture2D_pointer |
typedef boost::shared_ptr < Texture3D > | texture3D_pointer |
Functions | |
texture2D_pointer | create_float_texture (unsigned int width, unsigned int height, unsigned int components, float const *pixels) |
texture2D_pointer | create_float_texture_rectangle (unsigned int width, unsigned int height, unsigned int components, float const *pixels) |
texture2D_pointer | create_unsigned_byte_texture_rectangle (unsigned int width, unsigned int height, unsigned int components, unsigned char const *pixels) |
texture2D_pointer | create_unsigned_byte_texture (unsigned int width, unsigned int height, unsigned int components, const unsigned char *pixels) |
template<typename grid_type > | |
texture3D_pointer | create_texture3D_from_grid (grid_type &grid) |
template<typename T > | |
texture3D_pointer | create_texture3D (int texture_size_i, int texture_size_j, int texture_size_k) |
template<> | |
texture3D_pointer | create_texture3D< unsigned short > (int texture_size_i, int texture_size_j, int texture_size_k) |
template<typename texture2D_pointer > | |
void | show_texture2D (texture2D_pointer texture) |
unsigned int | external_format (unsigned int channels) |
template<typename T > | |
unsigned int | external_type () |
template<> | |
unsigned int | external_type< double > () |
template<> | |
unsigned int | external_type< float > () |
template<> | |
unsigned int | external_type< int > () |
template<> | |
unsigned int | external_type< unsigned int > () |
template<> | |
unsigned int | external_type< unsigned short > () |
template<> | |
unsigned int | external_type< short > () |
template<> | |
unsigned int | external_type< char > () |
template<> | |
unsigned int | external_type< unsigned char > () |
template<typename T > | |
unsigned int | internal_format (int channels) |
template<> | |
unsigned int | internal_format< unsigned char > (int channels) |
template<> | |
unsigned int | internal_format< char > (int channels) |
template<> | |
unsigned int | internal_format< short > (int channels) |
template<> | |
unsigned int | internal_format< unsigned short > (int channels) |
template<> | |
unsigned int | internal_format< int > (int channels) |
template<> | |
unsigned int | internal_format< unsigned int > (int channels) |
template<> | |
unsigned int | internal_format< float > (int channels) |
typedef boost::shared_ptr<Texture2D> OpenTissue::texture::texture2D_pointer |
typedef boost::shared_ptr<Texture3D> OpenTissue::texture::texture3D_pointer |
texture2D_pointer OpenTissue::texture::create_float_texture | ( | unsigned int | width, | |
unsigned int | height, | |||
unsigned int | components, | |||
float const * | pixels | |||
) | [inline] |
Create 2D Float Texture.
width | ||
height | ||
components | ||
pixels |
texture2D_pointer OpenTissue::texture::create_float_texture_rectangle | ( | unsigned int | width, | |
unsigned int | height, | |||
unsigned int | components, | |||
float const * | pixels | |||
) | [inline] |
Create 2D Float Texture RECT.
width | ||
height | ||
components | ||
pixels |
texture3D_pointer OpenTissue::texture::create_texture3D | ( | int | texture_size_i, | |
int | texture_size_j, | |||
int | texture_size_k | |||
) | [inline] |
Create Empty Texture. Example usage:
texture3D_poitner tex = create_texture3D<unsigned short>(32,32,32);
texture_size_i | The number of pixels in a row of the texture. | |
texture_size_j | The number of rows in an image of the texture. | |
texture_size_k | The number of images in the texture. |
texture3D_pointer OpenTissue::texture::create_texture3D< unsigned short > | ( | int | texture_size_i, | |
int | texture_size_j, | |||
int | texture_size_k | |||
) | [inline] |
texture3D_pointer OpenTissue::texture::create_texture3D_from_grid | ( | grid_type & | grid | ) | [inline] |
Create 3D texture from Grid. This function choices the lowest power-of 2 texture fitting the grid-dimensions best.
grid | The grid from which texture data should be loaded. |
texture2D_pointer OpenTissue::texture::create_unsigned_byte_texture | ( | unsigned int | width, | |
unsigned int | height, | |||
unsigned int | components, | |||
const unsigned char * | pixels | |||
) | [inline] |
Create Unsigned Byte 2D Texture Rect.
width | ||
height | ||
components | ||
pixels |
texture2D_pointer OpenTissue::texture::create_unsigned_byte_texture_rectangle | ( | unsigned int | width, | |
unsigned int | height, | |||
unsigned int | components, | |||
unsigned char const * | pixels | |||
) | [inline] |
Create Unsigned Byte 2D Texture.
width | ||
height | ||
components | ||
pixels |
unsigned int OpenTissue::texture::external_format | ( | unsigned int | channels | ) | [inline] |
Determine External Pixel Format. External refers to CPU side, whereas internal refers to GPU side.
channels | The number of channels in the external pixel data. |
unsigned int OpenTissue::texture::external_type | ( | ) | [inline] |
Determine External Pixel Type. External refers to CPU side, whereas internal refers to GPU side. This function is implemented using specialization, Example usage:
unsigned int type = external_type<unsigned char>();
unsigned int OpenTissue::texture::external_type< char > | ( | ) | [inline] |
unsigned int OpenTissue::texture::external_type< double > | ( | ) | [inline] |
unsigned int OpenTissue::texture::external_type< float > | ( | ) | [inline] |
unsigned int OpenTissue::texture::external_type< int > | ( | ) | [inline] |
unsigned int OpenTissue::texture::external_type< short > | ( | ) | [inline] |
unsigned int OpenTissue::texture::external_type< unsigned char > | ( | ) | [inline] |
unsigned int OpenTissue::texture::external_type< unsigned int > | ( | ) | [inline] |
unsigned int OpenTissue::texture::external_type< unsigned short > | ( | ) | [inline] |
unsigned int OpenTissue::texture::internal_format | ( | int | channels | ) | [inline] |
Determine Internal Pixel Type. External refers to CPU side, whereas internal refers to GPU side. This function is implemented using specialization, Example usage:
unsigned int format = internal_format<unsigned char>(4);
The specialization types indicates the number of bits in each color component (or if a float texture is wanted). The channels parameter indicates how many color components that is wanted.
channels | The number of channels in the internal pixel format. |
unsigned int OpenTissue::texture::internal_format< char > | ( | int | channels | ) | [inline] |
unsigned int OpenTissue::texture::internal_format< float > | ( | int | channels | ) | [inline] |
unsigned int OpenTissue::texture::internal_format< int > | ( | int | channels | ) | [inline] |
unsigned int OpenTissue::texture::internal_format< short > | ( | int | channels | ) | [inline] |
unsigned int OpenTissue::texture::internal_format< unsigned char > | ( | int | channels | ) | [inline] |
unsigned int OpenTissue::texture::internal_format< unsigned int > | ( | int | channels | ) | [inline] |
unsigned int OpenTissue::texture::internal_format< unsigned short > | ( | int | channels | ) | [inline] |
void OpenTissue::texture::show_texture2D | ( | texture2D_pointer | texture | ) | [inline] |
Show 2D Texture This function displays the specified texture as a full-screen image.
texture | A pointer to the 2D texture that should be displayed. |