Renesas / opencv-lib

Dependents:   RZ_A2M_Mbed_samples

Embed: (wiki syntax)

« Back to documentation index

Texture2D Class Reference

Smart pointer for OpenGL 2D texture memory with reference counting. More...

#include <opengl.hpp>

Public Types

enum  Format { , DEPTH_COMPONENT = 0x1902, RGB = 0x1907, RGBA = 0x1908 }
 

An Image Format describes the way that the images in Textures store their data.

More...

Public Member Functions

 Texture2D ()
 The constructors.
 Texture2D (int arows, int acols, Format aformat, unsigned int atexId, bool autoRelease=false)
 Texture2D (Size asize, Format aformat, unsigned int atexId, bool autoRelease=false)
 Texture2D (int arows, int acols, Format aformat, bool autoRelease=false)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 Texture2D (Size asize, Format aformat, bool autoRelease=false)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 Texture2D (InputArray arr, bool autoRelease=false)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
void create (int arows, int acols, Format aformat, bool autoRelease=false)
 Allocates memory for ogl::Texture2D object.
void create (Size asize, Format aformat, bool autoRelease=false)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
void release ()
 Decrements the reference counter and destroys the texture object if needed.
void setAutoRelease (bool flag)
 Sets auto release mode.
void copyFrom (InputArray arr, bool autoRelease=false)
 Copies from host/device memory to OpenGL texture.
void copyTo (OutputArray arr, int ddepth=CV_32F, bool autoRelease=false) const
 Copies from OpenGL texture to host/device memory or another OpenGL texture object.
void bind () const
 Binds texture to current active texture unit for GL_TEXTURE_2D target.
unsigned int texId () const
 get OpenGL opject id

Detailed Description

Smart pointer for OpenGL 2D texture memory with reference counting.

Definition at line 283 of file opengl.hpp.


Member Enumeration Documentation

enum Format

An Image Format describes the way that the images in Textures store their data.

Enumerator:
DEPTH_COMPONENT 

Depth.

RGB 

Red, Green, Blue.

RGBA 

Red, Green, Blue, Alpha.

Definition at line 288 of file opengl.hpp.