49 #ifdef SURFACE_THRESHOLD 60 #define GROUP_CP_DEFAULT 127 61 #define ZERO_TIMER_HDL ((void*)0x2EA02EA0) 64 extern int asn_bitmap_count;
65 extern int asn_group_item_count;
82 static void *group_mutex = NULL;
83 static MHEG5Int processing_timers = 0;
97 processing_timers = 0;
98 TRACE(TSTATE, (
"grp_mutex=%d", group_mutex))
109 void MHEG5groupPrint(
MHEG5Group *group,
char *out)
116 MHEG_PRINT(out,
" (");
118 MHEG_PRINT(out,
" 0 )");
142 MHEG_PRINT(out,
":ObjectInfo ");
149 MHEG_PRINT(out,
":OnStartUp ");
156 MHEG_PRINT(out,
":OnCloseDown ");
163 MHEG_PRINT(out,
":OrigGCPriority ");
172 MHEG_PRINT(out,
":Items ( ");
177 MHEG5finalPrint((
MHEG5Root *)currItem, out);
178 currItem = currItem->
next;
180 while (currItem != NULL);
183 MHEG_PRINT(out,
")");
190 MHEG_PRINT(out,
"// cachePriority ");
224 key = item->
root.
id & 0xff;
270 key = item->
root.
id & 0xff;
292 group->
group_id = ++nextFreeGroupId;
302 for (i = 0; i != 256; i++)
370 if (!item->initiallyStopped)
373 switch (item->root.clazz)
377 ERROR_PRINT((
"MHEG5groupPrepare: item is invalid class %d\n", item->root.clazz));
426 #ifndef MHEG5PROFILE_UK1_06 465 ERROR_PRINT((
"INTERNAL ERROR: MHEG5groupPrepare Unrecognised class %d\n", item->root.clazz));
485 TRACE(TFILE, (
" item count=%d grp_itm_cnt=%d asn_bmp_cnt=%d", count, asn_group_item_count, asn_bitmap_count))
579 #ifndef MHEG5PROFILE_UK1_06 643 if (group_timers[t_ndx].
group_ptr == group)
645 if (group_timers[t_ndx].
t_handle != 0)
740 #ifndef MHEG5PROFILE_UK1_06 860 #ifndef MHEG5PROFILE_UK1_06 899 ERROR_PRINT((
"INTERNAL ERROR: MHEG5groupDeactivate Unrecognised class %d\n", item->
root.
clazz));
949 ((
MHEG5Group *) target)->cachePriority = value;
959 static void MH5_GroupTimer(
void *
data )
977 TRACE(TTIME, (
"Timer %ld Fired, but it was cancelled while fire event was waiting in Queue (0x%x 0x%x)",
995 static void TimerCallback(
BOOLEAN triggered,
void *callerRef,
H_Timer timerHandle )
1003 event.proc_msg_func = MH5_GroupTimer;
1005 event.data.timer.triggered = triggered;
1006 event.data.timer.callerRef = callerRef;
1007 event.data.timer.timerHandle = (
void *)timerHandle;
1009 processing_timers++;
1013 TRACE(TERROR, (
"VQ_PutMsg returned Error\n"))
1018 processing_timers--;
1072 MHEG5GList *thirdParam = 0, *fourthParam = 0;
1074 MHEG5Int timerId = 0, timerValue = -1;
1091 for (t_ndx = 0; t_ndx !=
MAX_TIMERS; t_ndx++)
1093 if ((group_timers[t_ndx].
group_ptr == group) &&
1094 (group_timers[t_ndx].
timer_id == timerId))
1096 TRACE(TTIME, (
"Cancel timer id=%ld ndx=%d hdl=%x", timerId, t_ndx, group_timers[t_ndx].
t_handle))
1098 if (group_timers[t_ndx].t_handle != 0)
1123 timerValue -= currentTime - group->
startTime;
1126 for (t_ndx = 0; t_ndx !=
MAX_TIMERS; t_ndx++)
1128 if (group_timers[t_ndx].
t_handle == 0)
1131 group_timers[t_ndx].
timer_id = timerId;
1135 (
void *) &group_timers[t_ndx], &group_timers[t_ndx].
t_handle ) !=
MHERR_OK)
1140 TRACE(TTIME, (
"Create timer id=%ld val=%ld,ndx=%d hdl=%x", timerId, timerValue, t_ndx, group_timers[t_ndx].t_handle))
1142 else if (!absoluteTime && (timerValue == 0))
1145 timerValue = processing_timers;
1150 TRACE(TTIME, (
"Zero Timer fired, id=%ld, handle via queue", timerId))
1152 TimerCallback(
TRUE, (
void *) &group_timers[t_ndx], group_timers[t_ndx].
t_handle);
1157 TRACE(TTIME, (
"Zero Timer fired, id=%ld, handle immediately", timerId))
1171 #ifdef SURFACE_THRESHOLD 1177 void MHEG5groupDestroySurfaces(
MHEG5Int pixels)
1185 for (i = 0; group != NULL && i < 2; i++)
1187 for (ingredient = group->
itemHead; ingredient != NULL;
1188 ingredient = ingredient->
next)
1205 MG_ApplySurfaceThreshold(&visible->
graphic_data, pixels);
void MHEG5groupFree(MHEG5Group *group)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
MHEG5ErrorCode MHEG5setTimer(MHEG5Root *target, MHEG5GList *params)
This actions sets a new Timer which results in a TimerFired event when the given time is reached...
MHEG5Bool availabilityStatus
U32BIT STB_OSGetClockMilliseconds(void)
Get Current Computer Clock Time.
void MHEG5linkDestruct(MHEG5Link *link)
void MHEG5sliderDestruct(MHEG5Slider *slider)
Destruct a slider object.
void MHEG5videoDestruct(MHEG5Video *video)
Destruct a video object. See also MHEG5videoInit.
void MHEG5hotspotDeactivate(MHEG5Hotspot *hotspot)
E_MhegErr VQ_PutMsg(S_MhegMessage *pMsg, E_PRIORITY priority)
Post event or section message on queue. Copies data into queue.
BOOLEAN MH5GlueActiveState(void)
void MHEG5bitmapDestruct(MHEG5Bitmap *bitmap)
Destruct a bitmap object.
Distributor for Prepare, Destruct, Activate, Deactivate and Clone calls. Distribute the +Prepare +Des...
void MHEG5programFree(MHEG5Program *program)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MH5_GroupInit(void)
This function initialises Group Timers.
struct sMHEG5Ingredient * next
void MHEG5contentVariableFree(MHEG5ContentVariable *variable)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5programDeactivate(MHEG5Program *program)
void MHEG5tokenGroupActivate(MHEG5TokenGroup *tokenGroup)
void MHEG5dynamicLineartDeactivate(MHEG5DynamicLineart *dynamicLineart)
Apply the deactivation behaviour of the dynamiclineart class.
void MHEG5fontActivate(MHEG5Font *font)
void MHEG5octetStringVariablePrepare(MHEG5OctetStringVariable *variable)
Sets all internal attributes for the specified object to their default values.
void MHEG5contentVariablePrepare(MHEG5ContentVariable *variable)
Sets all internal attributes for the specified object to their default values.
void MHEG5actionListExecute(MHEG5Group *source, MHEG5ActionList actions)
Execute the supplied list of actions immediately. The actions will have been executed by the time the...
void MHEG5videoDeactivate(MHEG5Video *video)
Apply the deactivation behaviour of the video class. As this class has no own deactivation behaviour ...
void MHEG5contentVariableDestruct(MHEG5ContentVariable *variable)
void MHEG5cursorShapePrepare(MHEG5CursorShape *cursorShape)
Apply the preparation behaviour of the cursorshape class Apply the preparation behaviour of the curso...
void MHEG5booleanVariablePrepare(MHEG5BooleanVariable *variable)
Sets all internal attributes for the specified object to their default values.
void MHEG5cursorShapeFree(MHEG5CursorShape *cursorShape)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5rootDestruct(MHEG5Root *root)
Implementation of the Destruction behaviour Destruction This behaviour has the basic semantics of ask...
void MHEG5rectangleDeactivate(MHEG5Rectangle *rectangle)
void MHEG5octetStringVariableFree(MHEG5OctetStringVariable *variable)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5rtgraphicsFree(MHEG5RTGraphics *rtgraphics)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5hypertextFree(MHEG5Hypertext *hypertext)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
MHEG5GList * MHEG5resolveGenericInteger(MHEG5GList *params, MHEG5Int *value)
MHEG5ErrorCode MHEG5setCachePriority(MHEG5Root *target, MHEG5GList *params)
Implementation of the SetCachePriority action SetCachePriority (NewCachePriority) Set the GroupCacheP...
void MHEG5audioDeactivate(MHEG5Audio *audio)
Apply the deactivation behaviour off the audio class. As this class has no own deactivation behaviour...
void MHEG5textDestruct(MHEG5Text *text)
Destruct a text object.
void MHEG5listGroupActivate(MHEG5ListGroup *listGroup)
Implementation of the ListGroup Activation behaviour.
MHEG5Ingredient * hashIngred[256]
void MHEG5ingredientDestruct(MHEG5Ingredient *ingredient)
Implementation of the Destruction behaviour Execute the following sequence of actions: ...
void MHEG5fontFree(MHEG5Font *font)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5rectangleActivate(MHEG5Rectangle *rectangle)
Implementation of the Group class Description Defines the structure and behaviour of objects used as ...
void MHEG5groupDestruct(MHEG5Group *group)
Implementation of the Destruction behaviour Destruction.
void MHEG5groupDelItem(MHEG5Group *group, MHEG5Ingredient *item)
Delete Item from the List.
void MHEG5tokenGroupPrepare(MHEG5TokenGroup *tokenGroup)
void MHEG5streamDeactivate(MHEG5Stream *stream)
Apply the deactivation behaviour of the stream class. Execute the following sequence of actions: ...
void MHEG5streamFree(MHEG5Stream *stream)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5textPrepare(MHEG5Text *text)
Apply the preparation behaviour of the text class Apply the preparation behaviour of the text class...
void MHEG5listGroupDeactivate(MHEG5ListGroup *listGroup)
Implementation of the ListGroup Deactivation behaviour.
void MHEG5groupPrepare(MHEG5Group *group)
Implementation of the Preparation behaviour Preparation.
void MHEG5listGroupDestruct(MHEG5ListGroup *listGroup)
Implementation of the ListGroup Destruction behaviour.
void MHEG5linkPrepare(MHEG5Link *link)
void MHEG5stringDestruct(MHEG5String *item)
Destruct a MHEG5String.
void MHEG5fontDestruct(MHEG5Font *font)
void MHEG5linkActivate(MHEG5Link *link)
void MHEG5hotspotDestruct(MHEG5Hotspot *hotspot)
void MHEG5listGroupFree(MHEG5ListGroup *listGroup)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5objectRefVariablePrepare(MHEG5ObjectRefVariable *variable)
Sets all internal attributes for the specified object to their default values.
void MHEG5entryfieldDestruct(MHEG5Entryfield *entryfield)
Destruct a entryfield object.
void MHEG5entryfieldFree(MHEG5Entryfield *entryfield)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void(* F_TimerCallback)(BOOLEAN triggered, void *callerRef, H_Timer timerHandle)
void MHEG5streamActivate(MHEG5Stream *stream)
Apply the activation behaviour of the stream class. Execute the following sequence of actions: ...
struct _GroupTimer GroupTimer
void MHEG5integerVariablePrepare(MHEG5IntegerVariable *variable)
Sets all internal attributes for the specified object to their default values.
void MHEG5groupInit(MHEG5Group *group)
Initialise an Group object with default Values.
MHEG5ActionList onStartUp
void STB_OSMutexUnlock(void *mutex)
Unlock a mutex (a.k.a. 'leave', 'signal' or 'release')
void MHEG5linkFree(MHEG5Link *link)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5dynamicLineartPrepare(MHEG5DynamicLineart *dynamicLineart)
Apply the preparation behaviour of the dynamiclineart class Apply the preparation behaviour of the dy...
void MHEG5tokenGroupDestruct(MHEG5TokenGroup *tokenGroup)
This file defines the profile for the MHEG engine.
void MHEG5sliderActivate(MHEG5Slider *slider)
Apply the activation behaviour of the slider class. As this class has no own activation behaviour thi...
void MHEG5cursorShapeDestruct(MHEG5CursorShape *cursorShape)
Destruct a cursorshape object.
struct sMHEG5Ingredient * hnxt
void MHEG5lineartFree(MHEG5Lineart *lineart)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5rootPrepare(MHEG5Root *root)
Implementation of the Preparation behaviour Preparation This behaviour has the basic semantics of all...
void MHEG5variableActivate(MHEG5Ingredient *variable)
Apply the activation behaviour of the Variable class. Apply the activation behaviour of the variable ...
void MHEG5hotspotPrepare(MHEG5Hotspot *hotspot)
void MHEG5tokenGroupDeactivate(MHEG5TokenGroup *tokenGroup)
void MHEG5hypertextDeactivate(MHEG5Hypertext *hypertext)
void MHEG5sliderPrepare(MHEG5Slider *slider)
Apply the preparation behaviour of the slider class Apply the preparation behaviour of the slider cla...
void MHEG5variableDeactivate(MHEG5Ingredient *variable)
Apply the deactivation behaviour of the variable class. As this class has no own deactivation behavio...
void MHEG5streamDestruct(MHEG5Stream *stream)
Destruct a stream object. Execute the following sequence of actions:
void MHEG5rectangleFree(MHEG5Rectangle *rectangle)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5fontDeactivate(MHEG5Font *font)
void MHEG5entryfieldDeactivate(MHEG5Entryfield *entryfield)
Apply the deactivation behaviour of the entryfield class. As this class has no own deactivation behav...
void MHEG5paletteActivate(MHEG5Palette *palette)
void * STB_OSCreateMutex(void)
Create a mutex.
void MHEG5rootDeactivate(MHEG5Root *root)
Implementation of the Deactivation behaviour Deactivation This behaviour has the basic semantics of n...
struct sMHEG5Ingredient * prev
MHEG5ActionList onCloseDown
Event handling. Implementation of a combined queue for events and actions. This is the eventsystem wh...
void MHEG5paletteDestruct(MHEG5Palette *palette)
void MHEG5textDeactivate(MHEG5Text *text)
Apply the deactivation behaviour of the text class. As this class has no own deactivation behaviour t...
void MHEG5streamPrepare(MHEG5Stream *stream)
Apply the preparation behaviour of the stream class.
void MHEG5bitmapFree(MHEG5Bitmap *bitmap)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5groupDeactivate(MHEG5Group *group)
Implementation of the Deactivation behaviour Deactivation If group is not active, ignore behaviour...
MHEG5String objectInformation
void MHEG5entryfieldActivate(MHEG5Entryfield *entryfield)
Apply the activation behaviour of the entryfield class. As this class has no own activation behaviour...
MHEG5Bool initiallyStopped
Implement functions to retrieve MHEG5objects by GroupID and ID.
void MHEG5palettePrepare(MHEG5Palette *palette)
MHEG5Ingredient * itemHead
Mheg5 logging and debug printing.
void MHEG5bitmapActivate(MHEG5Bitmap *bitmap)
Apply the activation behaviour of the bitmap class. As this class has no own activation behaviour thi...
void MHEG5textActivate(MHEG5Text *text)
Apply the activation behaviour of the text class. As this class has no own activation behaviour this ...
void MHEG5integerVariableFree(MHEG5IntegerVariable *variable)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5rectanglePrepare(MHEG5Rectangle *rectangle)
void MHEG5videoFree(MHEG5Video *video)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5lineartDeactivate(MHEG5Lineart *lineart)
void MHEG5actionDestruct(MHEG5ActionList actions)
<Function description>="">
MHEG5Int originalCachePriority
void MHEG5rtgraphicsDeactivate(MHEG5RTGraphics *rtgraphics)
Apply the deactivation behaviour of the RTGraphics class. As this class has no own deactivation behav...
void MHEG5cursorShapeActivate(MHEG5CursorShape *cursorShape)
Apply the activation behaviour of the cursorshape class. As this class has no own activation behaviou...
void MHEG5rtgraphicsDestruct(MHEG5RTGraphics *rtgraphics)
Destruct a RTGraphics object.
void MHEG5groupActivate(MHEG5Group *group)
Implementation of the Activation behaviour Activation.
MHEG5Scene * MHEG5getCurrentScene(void)
<Function description>="">
void MHEG5sendEvent(MHEG5Root *source, MHEG5EventType event, MHEG5Int data)
Store an event in the asynchronous event queue.
void MHEG5rootInit(MHEG5Root *root)
Initialise a Root object with default values.
void MHEG5hotspotFree(MHEG5Hotspot *hotspot)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5listGroupPrepare(MHEG5ListGroup *listGroup)
Implementation of the ListGroup Preparation behaviour.
void STB_OSMutexLock(void *mutex)
Lock a mutex (a.k.a. 'enter', 'wait' or 'get').
The timer module allows the use of timers within the MHEG5 component. These timers can be set by othe...
void MHEG5objectRefVariableFree(MHEG5ObjectRefVariable *variable)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5tokenGroupFree(MHEG5TokenGroup *tokenGroup)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5hotspotActivate(MHEG5Hotspot *hotspot)
MHEG5ErrorCode MHEG5programActivate(MHEG5Program *program)
void MHEG5fontPrepare(MHEG5Font *font)
void MHEG5dynamicLineartFree(MHEG5DynamicLineart *dla)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
MHEG5GList * MHEG5resolveGenericBoolean(MHEG5GList *params, MHEG5Bool *value)
void MHEG5octetStringVariableDestruct(MHEG5OctetStringVariable *variable)
void MHEG5lineartDestruct(MHEG5Lineart *lineart)
void MHEG5booleanVariableFree(MHEG5BooleanVariable *variable)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5queueResolveTargets(MHEG5ActionList actions)
Finds targets for the action list.
void MHEG5hypertextPrepare(MHEG5Hypertext *hypertext)
void MHEG5groupAddItem(MHEG5Group *group, MHEG5Ingredient *item)
Add an Item to the List.
void MHEG5displayShowAll(void)
Redisplay all active visible objects. AKD: Optimised 12/5/99.
void MHEG5paletteFree(MHEG5Palette *palette)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5lineartPrepare(MHEG5Lineart *lineart)
void MHEG5cursorShapeDeactivate(MHEG5CursorShape *cursorShape)
Apply the deactivation behaviour of the cursorshape class. As this class has no own deactivation beha...
void MHEG5textFree(MHEG5Text *text)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
Implement generic MHEG5-display functions - independent from the OSD These are generic functions used...
void MHEG5bitmapPrepare(MHEG5Bitmap *bitmap)
Apply the preparation behaviour of the bitmap class. As this class has no own preparation behaviour t...
void MHEG5dynamicLineartDestruct(MHEG5DynamicLineart *dynamicLineart)
Destruct a dynamiclineart object.
void MHEG5hypertextDestruct(MHEG5Hypertext *hypertext)
void MHEG5rootFree(MHEG5Root *root)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5hypertextActivate(MHEG5Hypertext *hypertext)
void MHEG5dynamicLineartActivate(MHEG5DynamicLineart *dynamicLineart)
Apply the activation behaviour of the dynamiclineart class.
void MHEG5sliderDeactivate(MHEG5Slider *slider)
Apply the deactivation behaviour of the slider class. As this class has no own deactivation behaviour...
void MHEG5paletteDeactivate(MHEG5Palette *palette)
void MHEG5audioDestruct(MHEG5Audio *audio)
Destruct an audio object.
void MHEG5linkDeactivate(MHEG5Link *link)
void MHEG5sliderFree(MHEG5Slider *slider)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
void MHEG5programPrepare(MHEG5Program *program)
void MHEG5rectangleDestruct(MHEG5Rectangle *rectangle)
void MHEG5sendSync(MHEG5Root *source, MHEG5EventType event, MHEG5Int data)
Store an event in the synchronous event queue.
void MHEG5lineartActivate(MHEG5Lineart *lineart)
void MHEG5audioFree(MHEG5Audio *audio)
Free off all memory associated with the specified object, including any exchanged attributes and inte...
MHEG5Ingredient * itemTail
void MHEG5bitmapDeactivate(MHEG5Bitmap *bitmap)
Apply the deactivation behaviour of the bitmap class. As this class has no own deactivation behaviour...
void MHEG5programDestruct(MHEG5Program *program)
MHEG5Application * MHEG5getCurrentApplication(void)
<Function description>="">
void MHEG5entryfieldPrepare(MHEG5Entryfield *entryfield)
Apply the preparation behaviour of the entryfield class Apply the preparation behaviour of the entryf...
Header file - Function prototypes for operating system.