Dali 3D User Interface Engine
List of all members | Public Member Functions
Dali::Integration::Bitmap::PackedPixelsProfile Class Referenceabstract

#include <bitmap.h>

Inheritance diagram for Dali::Integration::Bitmap::PackedPixelsProfile:
Inheritance graph
[legend]

Public Member Functions

virtual PixelBufferReserveBuffer (Pixel::Format pixelFormat, unsigned int width, unsigned int height, unsigned int bufferWidth=0, unsigned int bufferHeight=0)=0
 (Re-)Allocate pixel buffer for the Bitmap. More...
 
virtual void AssignBuffer (Pixel::Format pixelFormat, PixelBuffer *buffer, std::size_t bufferSize, unsigned int width, unsigned int height, unsigned int bufferWidth=0, unsigned int bufferHeight=0)=0
 Assign a pixel buffer. More...
 
virtual unsigned int GetBufferWidth () const =0
 Get the width of the buffer (stride) More...
 
virtual unsigned int GetBufferHeight () const =0
 Get the height of the buffer. More...
 
virtual unsigned int GetBufferStride () const =0
 Get the pixel buffer stride. More...
 
virtual void TestForTransparency ()=0
 Check the bitmap data and test whether it has any transparent pixels. More...
 

Detailed Description

Definition at line 185 of file bitmap.h.

Member Function Documentation

virtual void Dali::Integration::Bitmap::PackedPixelsProfile::AssignBuffer ( Pixel::Format  pixelFormat,
PixelBuffer buffer,
std::size_t  bufferSize,
unsigned int  width,
unsigned int  height,
unsigned int  bufferWidth = 0,
unsigned int  bufferHeight = 0 
)
pure virtual

Assign a pixel buffer.

Any previously allocated pixel buffer is deleted. Dali has ownership of the buffer, but it iss allowable to modify its contents after it is assigned, but before it is used. Bitmap stores the provided size information about the image.

The buffer must have been allocated with the C++ array new operator, not with malloc or as a local or static object. The precise form is as follows:

PixelBuffer * buffer = new PixelBuffer[bufSize];

Precondition
bufferWidth, bufferHeight have to be power of two
Parameters
[in]pixelFormatpixel format
[in]bufferthe pixel buffer
[in]bufferSizesize of the pixel buffer
[in]widthImage width in pixels
[in]heightImage height in pixels
[in]bufferWidthBuffer width (stride) in pixels
[in]bufferHeightBuffer height in pixels

Implemented in Dali::Internal::BitmapPackedPixel.

virtual unsigned int Dali::Integration::Bitmap::PackedPixelsProfile::GetBufferHeight ( ) const
pure virtual

Get the height of the buffer.

Returns
The height of the buffer in pixels

Implemented in Dali::Internal::BitmapPackedPixel.

Referenced by Dali::Internal::BitmapTexture::Update().

Here is the caller graph for this function:

virtual unsigned int Dali::Integration::Bitmap::PackedPixelsProfile::GetBufferStride ( ) const
pure virtual

Get the pixel buffer stride.

Returns
The buffer stride (in bytes) if this is bitmap of non-compressed packed pixels for which a stride is meaningful or 0 otherwise.

Implemented in Dali::Internal::BitmapPackedPixel.

Referenced by anonymous_namespace{utc-Dali-NinePatchImages.cpp}::AddChildRegionsToImage(), anonymous_namespace{utc-Dali-RendererFactory.cpp}::AddChildRegionsToImage(), Dali::Internal::NinePatchImage::CreateCroppedBufferImage(), and Dali::Internal::NinePatchImage::ParseBorders().

Here is the caller graph for this function:

virtual unsigned int Dali::Integration::Bitmap::PackedPixelsProfile::GetBufferWidth ( ) const
pure virtual

Get the width of the buffer (stride)

Returns
The width of the buffer in pixels

Implemented in Dali::Internal::BitmapPackedPixel.

Referenced by Dali::Internal::BitmapTexture::Update().

Here is the caller graph for this function:

virtual PixelBuffer* Dali::Integration::Bitmap::PackedPixelsProfile::ReserveBuffer ( Pixel::Format  pixelFormat,
unsigned int  width,
unsigned int  height,
unsigned int  bufferWidth = 0,
unsigned int  bufferHeight = 0 
)
pure virtual

(Re-)Allocate pixel buffer for the Bitmap.

Any previously allocated pixel buffer is deleted. Dali has ownership of the buffer, but its contents can be modified. Bitmap stores given size information about the image.

Precondition
bufferWidth, bufferHeight have to be power of two
Parameters
[in]pixelFormatpixel format
[in]widthImage width in pixels
[in]heightImage height in pixels
[in]bufferWidthBuffer width (stride) in pixels
[in]bufferHeightBuffer height in pixels
Returns
pixel buffer pointer

Implemented in Dali::Internal::BitmapPackedPixel.

Referenced by anonymous_namespace{utc-Dali-Internal-ResourceClient.cpp}::CheckLoadBitmap(), anonymous_namespace{utc-Dali-RenderTask.cpp}::CompleteImageLoad(), anonymous_namespace{utc-Dali-NinePatchImages.cpp}::CreateBitmap(), anonymous_namespace{utc-Dali-RendererFactory.cpp}::CreateBitmap(), anonymous_namespace{utc-Dali-ShaderEffect.cpp}::CreateBitmap(), Dali::Internal::BufferImage::CreateHostBitmap(), Dali::Internal::Platform::CropAndPadForFittingMode(), anonymous_namespace{utc-Dali-Internal-ImageFactory.cpp}::EmulateImageLoaded(), Dali::TizenPlatform::LoadBitmapFromBmp(), Dali::TizenPlatform::LoadBitmapFromIco(), Dali::TizenPlatform::LoadBitmapFromJpeg(), Dali::TizenPlatform::LoadBitmapFromPng(), Dali::TizenPlatform::LoadBitmapFromWbmp(), anonymous_namespace{utc-Dali-ResourceImage.cpp}::LoadBitmapResource(), anonymous_namespace{utc-Dali-Image.cpp}::LoadBitmapResource(), anonymous_namespace{utc-Dali-Internal-ResourceClient.cpp}::LoadImage(), Dali::Internal::Platform::anonymous_namespace{image-operations.cpp}::MakeEmptyBitmap(), PerformFittingTests(), anonymous_namespace{utc-Dali-Atlas.cpp}::PrepareResourceImage(), Dali::Internal::BufferImage::UploadArea(), UtcDaliImageActorGetCurrentSize02(), UtcDaliImageActorGetCurrentSize03(), UtcDaliImageActorGetCurrentSize04(), UtcDaliImageActorGetCurrentSize05(), UtcDaliImageActorNaturalPixelAreaSize01(), UtcDaliImageActorNaturalPixelAreaSize02(), UtcDaliImageActorNinePatch01(), UtcDaliImageActorNinePatch03(), UtcDaliImageSignalUploaded(), UtcDaliInternalAddBitmapImage01(), UtcDaliInternalRequestReloadBitmapRequests01(), UtcDaliInternalRequestReloadBitmapRequests02(), UtcDaliInternalRequestReloadBitmapRequests03(), and UtcDaliInternalRequestResourceBitmapRequests01().

Here is the caller graph for this function:

virtual void Dali::Integration::Bitmap::PackedPixelsProfile::TestForTransparency ( )
pure virtual

Check the bitmap data and test whether it has any transparent pixels.

This property can then be tested for with IsFullyOpaque().

Implemented in Dali::Internal::BitmapPackedPixel.


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