8#ifndef META_OCEAN_RENDERING_GLES_TEXTURE_FRAMEBUFFER_H
9#define META_OCEAN_RENDERING_GLES_TEXTURE_FRAMEBUFFER_H
19#ifdef OCEAN_PLATFORM_BUILD_APPLE_IOS_ANY
20 #include <CoreVideo/CoreVideo.h>
72 inline unsigned int width()
const;
78 inline unsigned int height()
const;
190#ifdef OCEAN_PLATFORM_BUILD_APPLE_IOS_ANY
249#ifdef OCEAN_PLATFORM_BUILD_APPLE_IOS_ANY
262#ifdef OCEAN_PLATFORM_BUILD_WINDOWS
This class implements Ocean's image class.
Definition Frame.h:1969
PixelFormat
Definition of all pixel formats available in the Ocean framework.
Definition Frame.h:183
@ FORMAT_RGBA32
Pixel format with byte order RGBA and 32 bits per pixel.
Definition Frame.h:382
This class implements a container for an OpenGL ES shader program.
Definition GLESShaderProgram.h:53
bool setWrapTypeT(const WrapType type) override
Sets the texture wrap type in t direction.
bool bindFramebuffer()
Binds the framebuffer.
GLint majorVersion_
The major OpenGL version.
Definition GLESTextureFramebuffer.h:270
friend class GLESFactory
Definition GLESTextureFramebuffer.h:40
bool setPixelFormat(const FrameType::PixelFormat pixelFormat) override
Sets the texture framebuffer's internal pixel format.
GLuint depthTextureId_
The id of the depth texture.
Definition GLESTextureFramebuffer.h:214
std::string textureName_
The name of the texture in the shader.
Definition GLESTextureFramebuffer.h:247
bool setWrapTypeS(const WrapType type) override
Sets the texture wrap type in s direction.
ShaderProgramRef shaderProgramForOneSample_
The optional shader program object, needed when copying the content of the multi sample framebuffer (...
Definition GLESTextureFramebuffer.h:238
GLuint colorTextureId() const
Returns the id of the color texture.
Definition GLESTextureFramebuffer.h:283
VertexSetRef vertexSetForOneSample_
The optional vertex set object, needed when copying the content of the multi sample framebuffer (or d...
Definition GLESTextureFramebuffer.h:241
GLESTextureFramebuffer()
Creates a new GLESceneGraph texture object.
unsigned int height() const
Returns the height of this framebuffer.
Definition GLESTextureFramebuffer.h:278
CVOpenGLESTextureCacheRef iosTextureCache_
The texture cache on iOS platforms, if supported.
Definition GLESTextureFramebuffer.h:252
unsigned int width_
The width of the texture framebuffer in pixel, with range [0, infinity).
Definition GLESTextureFramebuffer.h:217
bool copyDepthTextureToFrame(Frame &frame, const CV::PixelBoundingBox &subRegion=CV::PixelBoundingBox()) override
Copies the image content of the depth texture to a given frame.
void unbindFramebuffer()
Unbinds the framebuffer.
TextureFramebufferRef textureFramebufferOneSample_
The optional texture with one samples, needed when copying the content of the multi sample framebuffe...
Definition GLESTextureFramebuffer.h:235
CVPixelBufferRef iosPixelBuffer_
The pixel buffer on iOS platforms, if supported.
Definition GLESTextureFramebuffer.h:255
unsigned int framebufferMultisamples_
The number of multi samples the framebuffer will apply, with range [1, infinity).
Definition GLESTextureFramebuffer.h:223
FrameType::PixelFormat pixelFormat() const override
Returns the texture framebuffer's internal pixel format.
WrapType wrapTypeT() const override
Returns the texture wrap type in t direction.
FrameType::PixelFormat pixelFormat_
The texture's pixel format.
Definition GLESTextureFramebuffer.h:226
unsigned int width() const
Returns the width of this framebuffer.
Definition GLESTextureFramebuffer.h:273
GLuint depthTextureId() const
Returns the id of the depth texture.
Definition GLESTextureFramebuffer.h:288
WrapType wrapTypeS() const override
Returns the texture wrap type in s direction.
GLuint colorTextureId_
The id of the color texture.
Definition GLESTextureFramebuffer.h:211
std::string textureName() const override
Returns the name of the texture e.g., in a shader.
~GLESTextureFramebuffer() override
Destructs a GLESceneGraph texture object.
unsigned int bindTexture(GLESShaderProgram &shaderProgram, const unsigned int id) override
Binds this texture.
WrapType wrapTypeS_
The texture wrap s type.
Definition GLESTextureFramebuffer.h:229
bool copyColorTextureToFrame(Frame &frame, const CV::PixelBoundingBox &subRegion=CV::PixelBoundingBox()) override
Copies the image content of the color texture to a given frame.
CVOpenGLESTextureRef iosTexture_
The texture on iOS platforms, if supported.
Definition GLESTextureFramebuffer.h:258
bool createTextureForFramebufferAppleIOS(const unsigned int width, const unsigned int height, const GLint textureInternalFormat, const GLenum textureFormat, const GLenum textureType)
Creates a texture for the framebuffer on iOS platforms.
TrianglesRef trianglesForOneSample_
The optional triangles object, needed when copying the content of the multi sample framebuffer (or de...
Definition GLESTextureFramebuffer.h:244
bool isValid() const override
Returns whether the texture framebuffer is ready for use.
bool setMultisamples(const unsigned int multisamples)
Sets the number of multi-samples.
PFNGLBLITFRAMEBUFFERPROC glBlitFramebuffer_
The function pointer to glBlitFramebuffer.
Definition GLESTextureFramebuffer.h:265
GLuint framebufferObjectId_
The id of the framebuffer object.
Definition GLESTextureFramebuffer.h:208
WrapType wrapTypeT_
The texture wrap t type.
Definition GLESTextureFramebuffer.h:232
bool setTextureName(const std::string &name) override
Sets the name of the texture e.g., in a shader.
void createMipmap() override
Updates the mipmap for this texture.
bool resize(const unsigned int width, const unsigned int height) override
Resizes the texture framebuffer.
unsigned int height_
The height of the texture framebuffer in pixel, with range [0, infinity).
Definition GLESTextureFramebuffer.h:220
void release()
Releases this texture framebuffer.
GLESTexture()
Creates a new GLESceneGraph texture object.
std::string name() const
Returns the name of this object.
Definition Object.h:323
TextureFramebuffer()=default
Creates a new texture object.
ObjectType type() const override
Returns the type of this object.
Definition rendering/TextureFramebuffer.h:133
WrapType
Definition of different texture wrapping types.
Definition rendering/Texture.h:96
@ WRAP_CLAMP
The texture will be clamped at the border.
Definition rendering/Texture.h:100
PixelBoundingBoxT< unsigned int > PixelBoundingBox
Definition of the default PixelBoundingBox object with data type allowing only positive coordinate va...
Definition PixelBoundingBox.h:28
SmartObjectRef< TextureFramebuffer > TextureFramebufferRef
Definition of a smart object reference holding a texture framebuffer.
Definition rendering/TextureFramebuffer.h:32
SmartObjectRef< Triangles > TrianglesRef
Definition of a smart object reference holding a triangles node.
Definition Triangles.h:29
SmartObjectRef< VertexSet > VertexSetRef
Definition of a smart object reference holding a vertex set node.
Definition VertexSet.h:31
SmartObjectRef< ShaderProgram > ShaderProgramRef
Definition of a smart object reference holding a shader program object.
Definition rendering/ShaderProgram.h:37
Namespace of the Rendering GLESceneGraph library.
Definition rendering/glescenegraph/android/Android.h:20
Namespace of the Rendering library.
Definition AbsoluteTransform.h:18
The namespace covering the entire Ocean framework.
Definition Accessor.h:15