Dali 3D User Interface Engine
List of all members | Public Member Functions | Static Public Member Functions
Dali::NativeImage Class Reference

NativeImage represents a platform specific image resource. More...

#include <native-image.h>

Inheritance diagram for Dali::NativeImage:
Inheritance graph
[legend]
Collaboration diagram for Dali::NativeImage:
Collaboration graph
[legend]

Public Member Functions

 NativeImage ()
 Constructor with creates an uninitialized NativeImage object. More...
 
 ~NativeImage ()
 Destructor. More...
 
 NativeImage (const NativeImage &handle)
 This copy constructor is required for (smart) pointer semantics. More...
 
NativeImageoperator= (const NativeImage &rhs)
 This assignment operator is required for (smart) pointer semantics. More...
 
void CreateGlTexture ()
 Trigger asynchronous creation of backing GL texture immediately. More...
 
const char * GetCustomFragmentPreFix ()
 Get custom fragment prefix for rendering a native image. More...
 
const char * GetCustomSamplerTypename ()
 Get custom sampler type name for rendering a native image. More...
 
DALI_INTERNAL NativeImage (Internal::NativeImage *)
 
- Public Member Functions inherited from Dali::Image
 Image ()
 Constructor which creates an empty Image handle. More...
 
 ~Image ()
 Destructor. More...
 
 Image (const Image &handle)
 This copy constructor is required for (smart) pointer semantics. More...
 
Imageoperator= (const Image &rhs)
 This assignment operator is required for (smart) pointer semantics. More...
 
ReleasePolicy GetReleasePolicy () const
 .3 More...
 
unsigned int GetWidth () const
 Returns the width of the image. More...
 
unsigned int GetHeight () const
 Returns the height of the image. More...
 
ImageSignalTypeUploadedSignal ()
 This signal is emitted when the image data gets uploaded to GL. More...
 
DALI_INTERNAL Image (Internal::Image *)
 
- Public Member Functions inherited from Dali::BaseHandle
 BaseHandle (Dali::BaseObject *handle)
 This constructor is used by Dali New() methods. More...
 
 BaseHandle ()
 This constructor provides an uninitialized Dali::BaseHandle. More...
 
 ~BaseHandle ()
 Dali::BaseHandle is intended as a base class. More...
 
 BaseHandle (const BaseHandle &handle)
 This copy constructor is required for (smart) pointer semantics. More...
 
BaseHandleoperator= (const BaseHandle &rhs)
 This assignment operator is required for (smart) pointer semantics. More...
 
template<class T >
bool ConnectSignal (ConnectionTrackerInterface *connectionTracker, const std::string &signalName, const T &functor)
 Connects a void() functor to a specified signal. More...
 
bool DoAction (const std::string &actionName, const Property::Map &attributes)
 Perform action on this object with the given action name and attributes. More...
 
const std::string & GetTypeName () const
 Returns the type name for the Handle. More...
 
bool GetTypeInfo (Dali::TypeInfo &info) const
 Returns the type info for the Handle. More...
 
BaseObjectGetBaseObject ()
 Retrieve the internal Dali resource. More...
 
const BaseObjectGetBaseObject () const
 Retrieve the internal Dali resource. More...
 
void Reset ()
 Resets the handle. More...
 
 operator BooleanType () const
 Converts an handle to a BooleanType. More...
 
bool operator== (const BaseHandle &rhs) const
 Equality operator overload. More...
 
bool operator!= (const BaseHandle &rhs) const
 Inequality operator overload. More...
 
Dali::RefObjectGetObjectPtr () const
 Get the reference counted object pointer. More...
 

Static Public Member Functions

static NativeImage New (NativeImageInterface &nativeImageInterface)
 Create a new NativeImage, which used native resources. More...
 
static NativeImage DownCast (BaseHandle handle)
 Downcast an Object handle to NativeImage handle. More...
 
- Static Public Member Functions inherited from Dali::Image
static Image DownCast (BaseHandle handle)
 Downcast an Object handle to Image handle. More...
 

Additional Inherited Members

- Public Types inherited from Dali::Image
enum  ReleasePolicy { UNUSED, NEVER }
 .3. More...
 
typedef Signal< void(Image) > ImageSignalType
 Type of signal for Image Uploaded. More...
 
- Protected Member Functions inherited from Dali::BaseHandle
void ThisIsSaferThanReturningVoidStar () const
 Used by the safe bool idiom. More...
 

Detailed Description

NativeImage represents a platform specific image resource.

Its data is provided by native resources, such as shared bitmap memory or pixmap. .0

Definition at line 42 of file native-image.h.

Constructor & Destructor Documentation

Dali::NativeImage::NativeImage ( )

Constructor with creates an uninitialized NativeImage object.

Use NativeImage::New(...) to create an initialised object. .0

Definition at line 27 of file native-image.cpp.

Referenced by DownCast(), and New().

Here is the caller graph for this function:

Dali::NativeImage::~NativeImage ( )

Destructor.

This is non-virtual since derived Handle types must not contain data or virtual methods. .0

Definition at line 36 of file native-image.cpp.

Dali::NativeImage::NativeImage ( const NativeImage handle)

This copy constructor is required for (smart) pointer semantics.

.0

Parameters
[in]handleA reference to the copied handle

Definition at line 40 of file native-image.cpp.

Dali::NativeImage::NativeImage ( Internal::NativeImage internal)
explicit

Definition at line 31 of file native-image.cpp.

Member Function Documentation

void Dali::NativeImage::CreateGlTexture ( )

Trigger asynchronous creation of backing GL texture immediately.

The normal policy is for a GL texture to created lazily when needed. This function forces the allocation of a texture to happen at the earliest opportunity.

.0

Note
If the application loses its GL context, native images may lose their GL textures. This function can be called again after context regain to force the creation of the GL texture if still needed.

Definition at line 51 of file native-image.cpp.

References Dali::GetImplementation().

Referenced by UtcDaliNativeImageContextLoss(), UtcDaliNativeImageCreateGlTextureN(), and UtcDaliNativeImageCreateGlTextureP().

Here is the call graph for this function:

Here is the caller graph for this function:

NativeImage Dali::NativeImage::DownCast ( BaseHandle  handle)
static

Downcast an Object handle to NativeImage handle.

If handle points to a NativeImage object, the downcast produces valid handle. If not, the returned handle is left unintialized. .0

Parameters
[in]handleHandle to an object.
Returns
Handle to a NativeImage or an uninitialized handle.

Definition at line 62 of file native-image.cpp.

References Dali::BaseHandle::GetObjectPtr(), and NativeImage().

Referenced by Dali::Toolkit::Internal::ImageRenderer::DoInitialize(), Dali::Toolkit::Internal::ImageRenderer::SetImage(), and UtcDaliNativeImageDownCast().

Here is the call graph for this function:

Here is the caller graph for this function:

const char * Dali::NativeImage::GetCustomFragmentPreFix ( )

Get custom fragment prefix for rendering a native image.

Returns
String for custom fragment prefix

Definition at line 72 of file native-image.cpp.

References Dali::GetImplementation().

Referenced by Dali::Toolkit::Internal::ImageRenderer::SetNativeFragmentShaderCode(), and UtcDaliNativeImageGetCustomFragmentPreFixP().

Here is the call graph for this function:

Here is the caller graph for this function:

const char * Dali::NativeImage::GetCustomSamplerTypename ( )

Get custom sampler type name for rendering a native image.

Returns
String for custom sampler type name

Definition at line 67 of file native-image.cpp.

References Dali::GetImplementation().

Referenced by Dali::Toolkit::Internal::ImageRenderer::SetNativeFragmentShaderCode(), and UtcDaliNativeImageGetCustomSamplerTypenameP().

Here is the call graph for this function:

Here is the caller graph for this function:

NativeImage Dali::NativeImage::New ( NativeImageInterface nativeImageInterface)
static

Create a new NativeImage, which used native resources.

The maximum size of the image is limited by GL_MAX_TEXTURE_SIZE .0

Parameters
[in]nativeImageInterfaceAn reference to the object of the interface implementation.
Returns
A handle to a newly allocated object.

Definition at line 56 of file native-image.cpp.

References Dali::PropertyTypes::Get(), NativeImage(), and Dali::Internal::NativeImage::New().

Referenced by UtcDaliImageGetWidthHeight(), UtcDaliImageViewSetImageBufferImageToNativeImage(), UtcDaliImageViewSetImageBufferImageWithCustomShaderToNativeImage(), UtcDaliImageViewSetImageNativeImage(), UtcDaliImageViewSetImageNativeImageToBufferImage(), UtcDaliImageViewSetImageNativeImageWithCustomShader(), UtcDaliNativeImageContextLoss(), UtcDaliNativeImageCopyConstructor(), UtcDaliNativeImageCreateGlTextureP(), UtcDaliNativeImageDownCast(), UtcDaliNativeImageGetCustomFragmentPreFixP(), UtcDaliNativeImageGetCustomSamplerTypenameP(), and UtcDaliNativeImageNew().

Here is the call graph for this function:

Here is the caller graph for this function:

NativeImage & Dali::NativeImage::operator= ( const NativeImage rhs)

This assignment operator is required for (smart) pointer semantics.

.0

Parameters
[in]rhsA reference to the copied handle.
Returns
A reference to this.

Definition at line 45 of file native-image.cpp.

References Dali::BaseHandle::operator=().

Here is the call graph for this function:


The documentation for this class was generated from the following files:
Dali Docs Home
Read more about Dali