Tizen Native API
Dali::NativeImageInterface Class Reference

Abstract interface to provide platform-specific support for handling image data. More...

Inheritance diagram for Dali::NativeImageInterface:
Dali::RefObject Dali::NativeImageSource

Public Member Functions

virtual bool GlExtensionCreate ()=0
 Forward declare future extension interface.
virtual void GlExtensionDestroy ()=0
 Destroy the GL resource for the NativeImage.
virtual unsigned int TargetTexture ()=0
 Use the NativeImage as a texture for rendering.
virtual void PrepareTexture ()=0
 Called in internal each NativeTexture::Bind() call to allow implementation specific operations.
virtual unsigned int GetWidth () const =0
 Returns the width of the NativeImage.
virtual unsigned int GetHeight () const =0
 Returns the height of the NativeImage.
virtual bool RequiresBlending () const =0
 Query whether blending is required.
virtual Extension * GetExtension ()
 Retrieve the extension for the interface.

Protected Member Functions

virtual ~NativeImageInterface ()
 A reference counted object may only be deleted by calling Unreference().

Detailed Description

Abstract interface to provide platform-specific support for handling image data.

For example, an implementation could use EGL extensions, etc.

Since :
2.4

Constructor & Destructor Documentation

virtual Dali::NativeImageInterface::~NativeImageInterface ( ) [protected, virtual]

A reference counted object may only be deleted by calling Unreference().

The implementation should destroy the NativeImage resources.

Since :
2.4

Member Function Documentation

virtual Extension* Dali::NativeImageInterface::GetExtension ( ) [virtual]

Retrieve the extension for the interface.

Since :
2.4
Returns:
The extension if available, NULL otherwise
virtual unsigned int Dali::NativeImageInterface::GetHeight ( ) const [pure virtual]

Returns the height of the NativeImage.

Since :
2.4
Returns:
Height
virtual unsigned int Dali::NativeImageInterface::GetWidth ( ) const [pure virtual]

Returns the width of the NativeImage.

Since :
2.4
Returns:
Width
virtual bool Dali::NativeImageInterface::GlExtensionCreate ( ) [pure virtual]

Forward declare future extension interface.

Create the GL resource for the NativeImage.

e.g. For the EglImageKHR extension, this corresponds to calling eglCreateImageKHR()

Since :
2.4
Returns:
False If the initialization fails.
Precondition:
There is a GL context for the current thread.
virtual void Dali::NativeImageInterface::GlExtensionDestroy ( ) [pure virtual]

Destroy the GL resource for the NativeImage.

e.g. For the EglImageKHR extension, this corresponds to calling eglDestroyImageKHR()

Since :
2.4
Precondition:
There is a GL context for the current thread.
virtual void Dali::NativeImageInterface::PrepareTexture ( ) [pure virtual]

Called in internal each NativeTexture::Bind() call to allow implementation specific operations.

The correct texture sampler has already been bound before the function gets called.

Since :
2.4
Precondition:
glAbstraction is being used by context in current thread
virtual bool Dali::NativeImageInterface::RequiresBlending ( ) const [pure virtual]

Query whether blending is required.

Since :
2.4
virtual unsigned int Dali::NativeImageInterface::TargetTexture ( ) [pure virtual]

Use the NativeImage as a texture for rendering.

Since :
2.4
Returns:
A GL error code
Precondition:
There is a GL context for the current thread.