epoc32/include/mw/animationframe.h
author William Roberts <williamr@symbian.org>
Wed, 31 Mar 2010 12:33:34 +0100
branchSymbian3
changeset 4 837f303aceeb
parent 3 e1b950c65cb4
permissions -rw-r--r--
Current Symbian^3 public API header files (from PDK 3.0.h)
This is the epoc32/include tree with the "platform" subtrees removed, and
all but a selected few mbg and rsg files removed.
williamr@2
     1
// Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
williamr@2
     2
// All rights reserved.
williamr@2
     3
// This component and the accompanying materials are made available
williamr@4
     4
// under the terms of "Eclipse Public License v1.0"
williamr@2
     5
// which accompanies this distribution, and is available
williamr@4
     6
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
williamr@2
     7
//
williamr@2
     8
// Initial Contributors:
williamr@2
     9
// Nokia Corporation - initial contribution.
williamr@2
    10
//
williamr@2
    11
// Contributors:
williamr@2
    12
//
williamr@2
    13
// Description:
williamr@2
    14
//
williamr@2
    15
williamr@2
    16
#ifndef __ANIMATIONFRAME_H__
williamr@2
    17
#define __ANIMATIONFRAME_H__
williamr@2
    18
williamr@2
    19
#include <icl/imagedata.h>
williamr@2
    20
williamr@2
    21
class CFbsBitmap;
williamr@2
    22
williamr@2
    23
/**
williamr@2
    24
Data format for individual bitmap format animation frames.
williamr@2
    25
williamr@2
    26
Animators and data providers which use the "bitmap" data type use objects
williamr@2
    27
of this type to transfer data.
williamr@2
    28
williamr@2
    29
You do not need to instantiate an object of this type unless you are writing
williamr@2
    30
a new data provider.
williamr@2
    31
williamr@2
    32
@see CBitmapAnimator
williamr@2
    33
@see CICLAnimationDataProvider
williamr@2
    34
@publishedAll
williamr@2
    35
@released
williamr@2
    36
*/
williamr@2
    37
class CAnimationFrame : public CBase
williamr@2
    38
	{
williamr@2
    39
public:
williamr@2
    40
	/** Structure used for passing a CAnimationFrame safely over a
williamr@2
    41
	client/server connection.*/
williamr@2
    42
	struct THandles
williamr@2
    43
		{
williamr@2
    44
		/** A handle to the bitmap into which the decoded frame(s) are put */
williamr@2
    45
		TInt iBitmapHandle;
williamr@2
    46
		/**	The bitmap mask for the changed area for this frame */
williamr@2
    47
		TInt iMaskHandle;
williamr@2
    48
		/** General frame info provided by all plugins */
williamr@2
    49
		TFrameInfo iFrameInfo;
williamr@2
    50
		};
williamr@2
    51
public:
williamr@2
    52
	virtual ~CAnimationFrame();
williamr@2
    53
	IMPORT_C static CAnimationFrame* NewL();
williamr@2
    54
	IMPORT_C static CAnimationFrame* NewL(const THandles& aHandles);
williamr@2
    55
	IMPORT_C void GetHandles(THandles & aHandles) const;
williamr@2
    56
	IMPORT_C void SetHandlesL(const THandles & aHandles);
williamr@2
    57
	IMPORT_C void CreateL(const TFrameInfo& aFrameInfo);
williamr@2
    58
	/** Returns the bitmap image for the changed area for this frame
williamr@2
    59
	@return A pointer to a CFbsBitmap */
williamr@2
    60
	CFbsBitmap* Bitmap()				{ return iBitmap; }
williamr@2
    61
	/** Returns the bitmap image for the changed area for this frame
williamr@2
    62
	@return A pointer to a const CFbsBitmap */
williamr@2
    63
	const CFbsBitmap* Bitmap() const	{ return iBitmap; }
williamr@2
    64
	/** Returns the bitmap mask for the changed area for this frame
williamr@2
    65
	@return A pointer to a CFbsBitmap */
williamr@2
    66
	CFbsBitmap* Mask()					{ return iMask; }
williamr@2
    67
	/** Returns the bitmap mask for the changed area for this frame
williamr@2
    68
	@return A pointer to a const CFbsBitmap */
williamr@2
    69
	const CFbsBitmap* Mask() const		{ return iMask; }
williamr@2
    70
	/** Returns information about the frame.
williamr@2
    71
  	@return A TFrameInfo */
williamr@2
    72
  	TFrameInfo& FrameInfo() 			{ return iFrameInfo; }
williamr@2
    73
  	/** Returns information about the frame.	
williamr@2
    74
	@return A const TFrameInfo */
williamr@2
    75
	const TFrameInfo& FrameInfo() const	{ return iFrameInfo; }
williamr@2
    76
protected:
williamr@2
    77
	IMPORT_C virtual void CAnimationFrame_Reserved1();
williamr@2
    78
	IMPORT_C virtual void CAnimationFrame_Reserved2();
williamr@2
    79
private:
williamr@2
    80
	TInt iCAnimationFrame_Reserved;
williamr@2
    81
private:
williamr@2
    82
	CAnimationFrame() {};
williamr@2
    83
	CAnimationFrame(const CAnimationFrame&); // no implementation
williamr@2
    84
	CAnimationFrame& operator=(const CAnimationFrame&); // no implementation
williamr@2
    85
	void ConstructL();
williamr@2
    86
private:
williamr@2
    87
	CFbsBitmap* iBitmap;
williamr@2
    88
	CFbsBitmap* iMask;
williamr@2
    89
	TFrameInfo iFrameInfo;
williamr@2
    90
	};
williamr@2
    91
williamr@2
    92
#endif //__ANIMATIONFRAME_H__