MHEG  17.9.0
 All Data Structures Files Functions Variables Typedefs Enumerations Macros Pages
mh5bitmap.h
Go to the documentation of this file.
1 /*******************************************************************************
2  * Copyright © 2014 The DTVKit Open Software Foundation Ltd (www.dtvkit.org)
3  * Copyright © 2004 Ocean Blue Software Ltd
4  * Copyright © 2000 Koninklijke Philips Electronics N.V
5  *
6  * This file is part of a DTVKit Software Component
7  * You are permitted to copy, modify or distribute this file subject to the terms
8  * of the DTVKit 1.0 Licence which can be found in licence.txt or at www.dtvkit.org
9  *
10  * THIS CODE AND INFORMATION ARE PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND,
11  * EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES
12  * OF MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR PURPOSE.
13  *
14  * If you or your organisation is not a member of DTVKit then you have access
15  * to this source code outside of the terms of the licence agreement
16  * and you are expected to delete this and any associated files immediately.
17  * Further information on DTVKit, membership and terms can be found at www.dtvkit.org
18  *******************************************************************************/
31 #ifndef _MH5BITMAP_H
32 #define _MH5BITMAP_H
33 
34 /*---includes for this file--------------------------------------------------*/
35 #include "mh5visible.h"
36 
37 /*---Constant and macro definitions for public use---------------------------*/
38 
39 /*---Enumerations for public use---------------------------------------------*/
40 
41 /*---Global type defs for public use-----------------------------------------*/
42 typedef struct
43 {
44  /* Base class */
45  MHEG5Visible visible;
46 
47  /* Engine data */
48  MHEG5Bool scaleSet;
49  MHEG5Int xscale;
50  MHEG5Int yscale;
51 
52  /* Internal attributes */
53  MHEG5Int xOffset;
54  MHEG5Int yOffset;
55  /* above attributes are common with video class - and need the same positions */
56 
57  MHEG5Int transparency;
58 
59  MHEG5Bool tiling;
60  MHEG5Int originalTransparency;
61 } MHEG5Bitmap;
62 
63 /*---Global variable declarations for public use-----------------------------*/
64 
65 /*---Global Function prototypes for public use-------------------------------*/
66 
77 void MHEG5bitmapInit(MHEG5Bitmap *bitmap);
78 
79 
87 void MHEG5bitmapFree(MHEG5Bitmap *bitmap);
88 
89 /*
90  Clone
91  */
98 
99 /*
100  Internal behaviours
101  */
102 void MHEG5bitmapPrepare(MHEG5Bitmap *bitmap);
103 void MHEG5bitmapActivate(MHEG5Bitmap *bitmap);
104 void MHEG5bitmapDeactivate(MHEG5Bitmap *bitmap);
105 void MHEG5bitmapDestruct(MHEG5Bitmap *bitmap);
106 
107 /*
108  Actions
109  */
110 MHEG5ErrorCode MHEG5scaleBitmap(MHEG5Root *target, MHEG5GList *params);
111 MHEG5ErrorCode MHEG5setTransparency(MHEG5Root *target, MHEG5GList *params);
112 MHEG5ErrorCode MHEG5setBitmapDecodeOffset(MHEG5Root *target, MHEG5GList *params);
113 MHEG5ErrorCode MHEG5getBitmapDecodeOffset(MHEG5Root *target, MHEG5GList *params);
114 
115 /*
116  Debug
117  */
118 #ifdef MH5PRINTOUT
119 void MHEG5bitmapPrint(MHEG5Bitmap *bitmap, char *out);
120 #endif
121 
122 #endif /*_MH5BITMAP_H*/
void MHEG5bitmapDestruct(MHEG5Bitmap *bitmap)
Destruct a bitmap object.
Definition: mh5bitmap.c:250
Definition: mh5bitmap.h:42
Definition: mh5visible.h:46
void MHEG5bitmapInit(MHEG5Bitmap *bitmap)
<Function description>="">
Definition: mh5bitmap.c:95
MHEG5ErrorCode MHEG5setBitmapDecodeOffset(MHEG5Root *target, MHEG5GList *params)
Implementation of the SetBitmapDecodeOffset (NewXOffset, NewYOffset) action of the bitmap class...
Definition: mh5bitmap.c:376
Definition: mh5base.h:169
Implement the MHEG5 Visible Class Defines the behaviour of Presentables that have a visual representa...
void MHEG5bitmapFree(MHEG5Bitmap *bitmap)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
Definition: mh5bitmap.c:109
void MHEG5bitmapActivate(MHEG5Bitmap *bitmap)
Apply the activation behaviour of the bitmap class. As this class has no own activation behaviour thi...
Definition: mh5bitmap.c:164
MHEG5ErrorCode MHEG5scaleBitmap(MHEG5Root *target, MHEG5GList *params)
The effect of this action is to scale the contents of the Bitmap to the size (XScale, YScale). Implementation of the ScaleBitmap (XScale, YScale) action of the bitmap class.
Definition: mh5bitmap.c:276
Definition: mh5root.h:43
MHEG5ErrorCode MHEG5getBitmapDecodeOffset(MHEG5Root *target, MHEG5GList *params)
Implementation of the GetBitmapDecodeOffset (XOffset, YOffset) action of the bitmap class GetBitmapDe...
Definition: mh5bitmap.c:432
void MHEG5bitmapPrepare(MHEG5Bitmap *bitmap)
Apply the preparation behaviour of the bitmap class. As this class has no own preparation behaviour t...
Definition: mh5bitmap.c:146
MHEG5ErrorCode MHEG5setTransparency(MHEG5Root *target, MHEG5GList *params)
Change the value of the Transparency attribute. Implementation of the SetTransparency (NewTransparenc...
Definition: mh5bitmap.c:327
MHEG5Bitmap * MHEG5bitmapClone(MHEG5Bitmap *source)
Copy a bitmap object with original values.
Definition: mh5bitmap.c:121
void MHEG5bitmapDeactivate(MHEG5Bitmap *bitmap)
Apply the deactivation behaviour of the bitmap class. As this class has no own deactivation behaviour...
Definition: mh5bitmap.c:210