Image Component Library (ICL)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Member Functions | Public Attributes
icl::geom::TexturePrimitive Struct Reference

Texture Primitive. More...

#include <Primitive.h>

Inheritance diagram for icl::geom::TexturePrimitive:
icl::geom::QuadPrimitive icl::geom::AlphaFuncProperty icl::math::FixedColVector< int, 8 > icl::geom::Primitive icl::math::FixedMatrix< int, 1, DIM > icl::utils::FixedArray< int, COLS *ROWS > icl::math::FixedMatrixBase icl::geom::TextPrimitive

List of all members.

Public Member Functions

 TexturePrimitive (int a, int b, int c, int d, const core::ImgBase *image=0, bool createTextureOnce=true, int na=-1, int nb=-1, int nc=-1, int nd=-1, core::scalemode sm=core::interpolateLIN)
 create with given texture that is either copied once or everytime the primitive is rendered
 TexturePrimitive (int a, int b, int c, int d, const core::Img8u &image, int na=-1, int nb=-1, int nc=-1, int nd=-1, core::scalemode sm=core::interpolateLIN)
 create with given texture, that is copied once
virtual ICLGeom_API void render (const Primitive::RenderContext &ctx)
 render method
virtual Primitivecopy () const
 deep copy

Public Attributes

qt::GLImg texture
 < internal texture
const core::ImgBaseimage
 < set if the texture shall be updated every time it is drawn

Detailed Description

Texture Primitive.

Texture Primitives hare two modes:

  1. createTextureOnce=true: In this case, the texture data that is given to the constructor is only copied once. This will result in a static texture, that is only transferred to the graphics card-memory once. This is very efficient, but the texture cannot be updated lateron automatically
  2. createTextureOnce=false: in this case, the texture data will always be updated before the texture is drawn. In this way, one can easily create video textures.

Constructor & Destructor Documentation

icl::geom::TexturePrimitive::TexturePrimitive ( int  a,
int  b,
int  c,
int  d,
const core::ImgBase image = 0,
bool  createTextureOnce = true,
int  na = -1,
int  nb = -1,
int  nc = -1,
int  nd = -1,
core::scalemode  sm = core::interpolateLIN 
) [inline]

create with given texture that is either copied once or everytime the primitive is rendered

icl::geom::TexturePrimitive::TexturePrimitive ( int  a,
int  b,
int  c,
int  d,
const core::Img8u image,
int  na = -1,
int  nb = -1,
int  nc = -1,
int  nd = -1,
core::scalemode  sm = core::interpolateLIN 
) [inline]

create with given texture, that is copied once


Member Function Documentation

virtual Primitive* icl::geom::TexturePrimitive::copy ( ) const [inline, virtual]

deep copy

Reimplemented from icl::geom::QuadPrimitive.

Reimplemented in icl::geom::TextPrimitive.

render method

Reimplemented from icl::geom::QuadPrimitive.

Reimplemented in icl::geom::TextPrimitive.


Member Data Documentation

< set if the texture shall be updated every time it is drawn

< internal texture

Reimplemented from icl::geom::Primitive.


The documentation for this struct was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines