MM Developer's Guide
MM Interfaces | MM Methods | MM Types and Misc API
This document contains the following sections:
Defined in: mmtypes.h
typedef struct { union { MoaMmRGBTriple rgb; MoaByte index; } color; MoaByte type; } MoaMmColorSpec, FAR *PMoaMmColorSpec;
color | Union representing the possible types of color values |
rgb | RGB color value |
index | Indexed color value |
type | Type of color value specified |
This structure represents color specifications in a device-independent way. On devices that use true color representations, the RGB field of the color union represents the specified color. On devices that use color palettes or color lookup tables, the index field represents the specified color.
A MoaMmColorSpec can be of two types: kMoaMmColorSpec_Index or kMoaMmColorSpec_RGB. Any code that receives a MoaMmColorSpec must be able to handle both types. The type field specifies the type, and which of the color union fields contains the color value. Valid values for this field are defined as MOA constants:
kMoaMmColorSpec_Index | Color value in index field of color union |
kMoaMmColorSpec_RGB | Color value in rgb field of color union |
In general, the host application supplies you with a MoaMmColorSpec of type kMoaMmColorSpec_Index if the associated graphics context uses indexed colors (8 bit or less color pixels). A MoaMmColorSpec of type kMoaMmColorSpec_RGB is supplied for a direct color graphics context (greater than 8 bit color pixels).
If the MoaMmColorSpec is kMoaMmColorSpec_Index, the color index is supplied in the index field of the color union in the structure. If it's kMoaMmColorSpec_RGB, the RGB value, stored as a MoaMmRGBTriple, is supplied in the rgb field of the color union.
The MacToMoaRGB(),
MoaToMacRGB(),
WinToMoaRGB(),
MoaToWinRGB()
macros are provided for converting between native
and MoaRGB types.
MoaEqualRGB()
compares two MoaRGBTriples.
The macros ColorSpec_MakeFromIndex(),
ColorSpec_MakeFromMacRGB(),
and ColorSpec_MakeFromWinRGB()
are supplied for creating new MoaMmColorSpecs
from an index, Macintosh RGBColor, or Windows 32-bit
RGB value.
typedef struct{ MoaByte red; MoaByte green; MoaByte blue; } MoaMmRGBTriple, FAR *PMoaMmRGBTriple;
Defined in: mmtypes.h
typedef struct { MoaUlong nMilliseconds; MoaChar sName[kMoaMmCuePointMaxNameLen]; } MoaMmCuePoint, FAR * PMoaMmCuePoint;
typedef struct { MoaMmValue vChannel; MoaLong nIndex; MoaMmCuePoint cuePoint; } MoaMmCuePointPassedInfo, FAR * PMoaMmCuePointPassedInfo;Use the cue point macros to access the data in these structures.
Defined in: mmtypes.h
typedef struct { MoaMmEventType type; MoaLong target; MoaPoint where; MoaLong when; union { MoaMmKeyInfo keyInfo; struct { MoaLong data1; MoaLong data2; MoaLong data3; MoaLong data4; } aux; } data; } MoaMmEventInfo;Structure passed to the IMoaMmXSpriteActor::Event() method to describe the event being sent.
type | Type of the event |
target | Reserved |
where | Mouse location. where is filled out for mouse, keyboard, idle, and step events. |
when | Timestamp (milliseconds). when is filled out for mouse and keyboard events |
data | Substructure event-specific data |
keyInfo | MoaMmKeyInfo structure containing information relevant to key events |
aux | Substructure for additional event-specific data |
data1 | Event-specific data |
data2 | Event-specific data |
data3 | Event-specific data |
data4 | Event-specific data |
Structure representing information relevant to mouse and key events, passed as a parameter to the IMoaMmXSpriteActor::Event() method. Your implementation of this method should evaluate data in this structure and determine the corresponding behavior.
MoaMmEventInfo | Structure representing event information |
PMoaMmEventInfo | Pointer to MoaMmEventInfo information structure |
ConstPMoaMmEventInfo | Constant pointer to MoaMmEventInfo structure |
The where and when fields are not valid for all events. Here's a list of events for which the fields are valid in Director:
See the following sections for descriptions of these events.
MoaLong used in the structure MoaMmEventInfo to represent the type of an event. The valid values for this type are defined as MOA constants: mouse event, key event, playback event, and environment event.
Name | Description |
kMoaMmEvent_Idle | Idle (null) event |
kMoaMmEvent_MouseDown | Mouse button down |
kMoaMmEvent_MouseDblClick | Mouse double click |
kMoaMmEvent_MouseUp | Mouse up within clicked-on actor |
kMoaMmEvent_MouseUpOutside | Mouse up outside clicked-on actor |
kMoaMmEvent_RightMouseDown | Right mouse button down |
kMoaMmEvent_RightMouseDblClick | Right mouse button double click |
kMoaMmEvent_RightMouseUp | Right up within clicked-on actor |
kMoaMmEvent_RightMouseUpOutside | Right up outside clicked-on actor |
kMoaMmEvent_MouseEnter | Rollover support |
kMoaMmEvent_MouseExit | Rollover support |
kMoaMmEvent_MouseWithin | Rollover support |
A full double-click sequence for Sprite Xtras should be
Instead of getting a kMoaMmEvent_MouseDown for the second click, you'll get a kMoaMmEvent_MouseDblClick. kMoaMmEvent_RightMouseDblClick is used for the right mouse button. Odd numbered clicks in a sequence come in as regular kMoaMmEvent_MouseDown (in accordance with Microsoft Windows conventions). For example, a third click is a kMoaMmEvent_MouseDown, not a kMoaMmEvent_MouseDblClick. If you just want to make sure you get every mouse down event (and don't care about distinguishing double-clicks), you must test for both kMoaMmEvent_MouseDown and kMoaMmEvent_MouseDblClick.
Lingo users: Lingo does not yet recognize the double-click events, therefore these events get propogated as normal "mouseDown" or "mouseUp" messages to Lingo handlers.
In Director on the Macintosh, a Control-click simulates a right mouse click sequence if the Lingo global property, the emulateMultiButtonMouse is set TRUE. The default is FALSE. Other applications may have their own conventions for mapping right mouse events on the Macintosh.
Name | Description |
kMoaMmEvent_KeyDown | Key down |
kMoaMmEvent_KeyUp | Key up |
kMoaMmEvent_KeyFocusEnter | Actor has just received keyboard focus |
kMoaMmEvent_KeyFocusExit | Actor has just lost keyboard focus |
Name | Description |
kMoaMmEvent_Step | Playback head has moved to next frame |
kMoaMmEvent_SpanBegin | A sprite span for actor has started |
kMoaMmEvent_SpanEnd | A sprite span for actor has ended |
kMoaMmEvent_PlayBegin | Movie started playing (authoring only) |
kMoaMmEvent_PlayEnd | Movie stopped playing (authoring only) |
Note: In Director, PlayBegin and playEnd are tied to playing and stopping movies when authoring. Because they are actor event, you get these only when you are on-stage while the movie starts or stops playing; they are not generated in projectors. Use the playerStateInfo field to check if the movie is playing when the actor is not on-stage.
Name | Description |
kMoaMmEvent_StageWindowOpen | Stage window opened |
kMoaMmEvent_StageWindowClose | Stage window hidden or destroyed |
kMoaMmEvent_StageWindowDepth | Stage window/buffer changed bit depth |
kMoaMmEvent_SoundState | Global sound on/off state changed |
kMoaMmEvent_AssetModified | Asset associated with actor was modified |
typedef struct { MoaLong character; MoaLong modifiers; MoaLong nativeKeyCode; MoaLong nativeModifiers; } MoaMmKeyInfo, FAR * PMoaMmKeyInfo;
character | |
modifiers | Modifier keys pressed (Cmd, Ctrl, etc.) |
nativeKeyCode | Platform-specific native key code |
nativeModifiers | Platform-specific modifier key information |
Note that while the mouse button is down, the modifier keys aren't updated as subsequent events are passed to the IMoaMmXSpriteActor::Event() method.
MoaMmKeyInfo | Structure containing information relevant to keydown events |
PMoaMmKeyInfo | Pointer to MoaMmKeyInfo information structure |
Name | Description |
kMoaMmModifier_None | No modifier keys pressed |
kMoaMmModifier_Shift | Shift key pressed |
kMoaMmModifier_Command | Command (Macintosh) or Control (Windows) pressed |
kMoaMmModifier_Option | Option (Macintosh) or Alt (Windows) pressed |
kMoaMmModifier_Alt | Option (Macintosh) or Alt (Windows) pressed |
kMoaMmModifier_Control | Control key pressed |
Defined in: mmtypes.h
Type representing the platform-dependent graphics context provided for drawing by the host platform. Valid values for this type are defined as MOA constants:
Name | Description |
kMoaMmGCType_Null | No graphics context or graphics context unknown |
kMoaMmGCType_WinWindow | Microsoft Windows window graphics context |
kMoaMmGCType_WinDIBDC | Microsoft Windows device-independent bitmap context |
kMoaMmGCType_WinDDBDC | Microsoft Windows device-dependent bitmap context |
kMoaMmGCType_MacWindow | Macintosh window graphics context. The value is a WindowRef rather than a WindowPtr |
kMoaMmGCType_MacGWorld | Macintosh graphics world graphics context |
kMoaMmGCType_Aux | (reserved) |
MoaLong representing Microsoft Windows device context flags in the win_dibdc variant of MoaMmNativeGCInfo structure. These flags are set as the bitwise OR (|) of MOA constants that specify certain states. Currently, there is one flag used to indicate when WinG is available. Valid values are defined as MOA constants:
Name | Description |
kMoaMmWinDIBDCFlags_None | No device context flags set |
kMoaMmWinDIBDCFlags_WinG | (No longer supported) |
typedef struct { MoaMmGCType type; union { struct { MoaMmWinHdl32 Hdc MoaMmWinHdl32 hWND; } win_window; struct { MoaMmWinHdl32 hDC; PMoaVoid lpBitMapInfo; PMoaVoid lpBits; MoaMmWinDIBDCFlags flags; } win_dibdc; struct { MoaMmWinHdl32 hDC; PMoaVoid hBITMAP; } win_ddbdc; struct { PMoaMmMacWindow windowPtr; // this is a WindowRef rather than a WindowPtr PMoaVoid qdGlobalsPtr; // NULL for OS X and later } mac_window; struct { PMoaMmMacGWorld gworldPtr; PMoaVoid qdGlobalsPtr; // NULL for OS X and later } mac_gworld; struct { PMoaVoid data1; PMoaVoid data2; PMoaVoid data3; PMoaVoid data4; } aux; } data; } MoaMmNativeGCInfo;
MoaMmNativeGCInfo | Structure containing graphic context information |
PMoaMmNativeGCInfo | Pointer to MoaMmNativeGCInfo information structure |
ConstPMoaMmNativeGCInfo | Constant pointer to MoaMmNativeGCInfo structure |
Platform-specific graphics context information structure. This structure consists of two parts: a field specifying a particular graphics context of the host platform and a union of structures, each relevant to a specific graphics context. The members of this union are:
hDC | Win16: only low 16-bits used |
hWND | Win16: only low 16-bits used |
This member structure defines the graphics context for a Microsoft Windows window.
hDC | Win16: only low 16-bits used |
lpBitMapInfo | |
lpBits | |
flags |
This member structure defines the graphics context for a Microsoft Windows device-independent bitmap.
hDC | Win16: only low 16-bits used |
hBitmap |
This member structure defines the graphics context for a Microsoft Windows device-dependent bitmap.
windowPtr | a WindowRef |
qdGlobalsPtr | NULL for OS X and later |
This member structure defines the graphics context for a Macintosh window.
gworldPtr | a GWorldPtr |
qdGlobalsPtr | NULL for OS X and later |
This member structure defines the graphics context for a Macintosh graphics world.
data1 | |
data2 | |
data3 | |
data4 |
This member defines a general structure that can be redefined for various graphics contexts.
Name | Description |
MoaMmWinHdl32 | 32-bit value used to hold both 16- and 32-bit Windows handles |
MoaMmWinHandle | Matches Windows HANDLE. Win16: 16-bit unsigned integer; Win32: 32-bit void * |
MoaMmHInst | A MoaMmWinHandle (16- or 32-bits depending on the Windows version) |
MoaMmHWnd | A MoaMmWinHandle (16- or 32-bits depending on the Windows version) |
PMoaMmMacWindow | A Macintosh WindowRef |
PMoaMmMacGWorld | A Macintosh GWorldPtr |
MoaLong value used in registering a Macintosh window with the IMoaMmWndMac::MacRegisterWindow() method. To form a value for this type, create the bitwise OR (|) or the various values representing the Window's capabilities. These values are defined as MOA constants:
kMoaMmRegWindowFlags_None
kMoaMmRegWindowFlags_AuthorIdle
When the AuthorIdle flag is set, the window receives null events in all cases. When not set, the window receives null events only when it is active.
kMoaMmMacEvent_CloseWindow
Special event passed to your IMoaMmMacEventHandler when the host application wants you to close your window.
MoaLong representing the modification state of a media asset. To form a value for this type, create the bitwise OR (|) or the various values representing the modification state. Valid values for this type are defined as MOA constants:
Name | Description |
kMoaMmModifyFlags_None | Nothing was modified |
kMoaMmModifyFlags_Media | Media data was modified |
kMoaMmModifyFlags_Props | Property data was modified |
MoaMmModifyFlags | Long value containing modification flags |
PMoaMmModifyFlags | Pointer to MoaMmModifyFlags modification flags |
ConstPMoaMmModifyFlags | Constant pointer to MoaMmModifyFlags modification flags |
These flags are passed from an asset to the host in the IMoaMmXAsset methods InvokeMediaEditor() and FinishPropsEditor().
Defined in: mmtypes.h
MoaLong type representing unique run-time IDs used for properties, asset types, etc. The MoaMmSymbol for an item is guaranteed unique only for the current session, so these values should never be stored on disk or otherwise transferred outside the running application. To acquire a unique symbol for a particular string value, use the StringToSymbol() method of the IMoaMmValue callback interface. To acquire the string for a particular symbol, use theSymbolToString() method of the IMoaMmValue interface. Symbol strings are case-insensitive.
MoaMmSymbol | Type |
PMoaMmSymbol | Pointer type |
ConstPMoaMmSymbol | Constant pointer type |
Do not access fields of MoaMmValue directly. Use the value conversion methods in IMoaMmValue.
The one exception to this rule is when you want to specify initialization values for a new MoaMmValue structure. There are
two macros in xmmvalue.h that can used for this purpose: kVoidMoaMmValueInitializer
and kNullMoaMmValueInitializer
.
MoaMmValue | Structure type |
PMoaMmValue | Pointer type |
ConstPMoaMmValue | Constant pointer type |
MoaLong representing the type of a MoaMmValue.
struct MoaMmCallInfo { PMoaVoid xinst; MoaLong methodFlags; MoaMmSymbol methodSelector; MoaMmValue resultValue; MoaLong nargs; PMoaMmValue pArgs };
xinst | MoaHandle to XtraInstRec |
methodFlags | Reserved |
methodSelector | Method index or symbol |
resultValue | Slot for result |
nargs | Number of arguments passed |
pArgs | Pointer to array of arguments |
typedef struct { MoaMmEventMask eventMask; MoaMmXSpriteCapsFlags flags; MoaMmXSpriteImageMode requiredImageMode; MoaMmXSpriteImageMode preferredImageMode; } MoaMmXSpriteCaps, FAR * PMoaMmXSpriteCaps;
eventMask | Mask representing event types handled by the sprite |
flags | Flag representing other capabilities of the sprite |
requiredImageMode | Required image mode (if any) |
preferredImageMode | Preferred image mode (if any) |
Structure representing the capabilities of a particular Sprite Xtra.
MoaMmXSpriteCaps | Structure of information about Sprite Xtra capabilities |
PMoaMmXSpriteCaps | Pointer to MoaMmXSpriteCaps structure |
Use these in the eventMask MoaMmXSpriteCaps field for sprite actors. To receive events from multiple event classes, combine your masks with the OR operator, for example, kMoaMmEventMask_Mouse | kMoaMmEventMask_Key
Name | Description |
kMoaMmEventMask_Every | Receive all events |
kMoaMmEventMask_None | Receive no events |
kMoaMmEventMask_Idle | Receive idles (play-time only) |
kMoaMmEventMask_Mouse | Receive all mouse events |
kMoaMmEventMask_Key | Receive all key and focus events |
kMoaMmEventMask_Play | Receive all play events |
kMoaMmEventMask_Span | Receive span events |
kMoaMmEventMask_Step | Receive step events |
kMoaMmEventMask_Environment | Receive all environment change events |
MoaLong type used in the MoaMmXSpriteCaps structure to represent the capabilities of a particular Sprite Xtra. The valid values for this type are defined as MOA constants:
Name | Description |
kMoaMmXSpriteCapsFlags_None | No capabilities defined |
kMoaMmXSpriteCapsFlags_IsStatic | Sprite seldom changes |
kMoaMmXSpriteCapsFlags_AutoTabEnabled | Application handles Tab key |
MoaLong type representing the imaging mode of a particular Sprite Xtra. The valid values for this type are defined as MOA constants:
Name | Description |
kMoaMmXSpriteImageMode_Any | Sprite draws in any mode |
kMoaMmXSpriteImageMode_Offscreen | Sprite draws offscreen |
kMoaMmXSpriteImageMode_DirectToScreen | Sprite draws to screen |
typedef struct { MoaRect spriteRect; MoaMmXSpriteImageMode imageMode; MoaMmXSpriteFlags flags; MoaMmInk ink; MoaMmInkParams inkParams; MoaLong aux; } MoaMmXSpriteInfo;
spriteRect | Rectangle on stage where sprite appears |
imageMode | Imaged direct or to an offscreen buffer |
flags | Sprite FX flags |
ink | Sprite ink mode |
inkParams | Extra parameters for some inks |
aux | Reserved |
MoaMmXSpriteInfo | Structure representing various information about a sprite Xtra |
PMoaMmXSpriteInfo | Pointer to MoaMmXSpriteInfo information structure |
ConstPMoaMmXSpriteInfo | Constant pointer to MoaMmXSpriteInfo structure |
MoaLong included as a field in the MoaMmXSpriteInfo structure to represent the capabilities of a specific Sprite Xtra. To form a value for this type, create the bitwise OR (|) or the various values representing capabilities of the Xtra. These values are defined as MOA constants:
Name | Description |
kMoaMmXSpriteFlags_None | No unique capabilities |
kMoaMmXSpriteFlags_Moveable | Sprite is movable |
kMoaMmXSpriteFlags_Editable | Sprite is editable |
kMoaMmXSpriteFlags_Blend |
Supplied as parameters to Xtra Actor methods
MoaLong representing the image transfer types or ink modes available for raster imaging operations. Valid values for this type are defined as MOA constants.
kMoaMmInk_Copy kMoaMmInk_Transparent kMoaMmInk_Reverse kMoaMmInk_Ghost kMoaMmInk_NotCopy kMoaMmInk_NotTransparent kMoaMmInk_NotReverse kMoaMmInk_NotGhost kMoaMmInk_Matte kMoaMmInk_Mask kMoaMmInk_AddPin kMoaMmInk_Add kMoaMmInk_SubtractPin kMoaMmInk_BackgroundTransparent kMoaMmInk_Lightest kMoaMmInk_Subtract kMoaMmInk_Darkest
These ink types correspond to standard transfer modes defined by both Macintosh and Windows graphics systems
typedef struct { MoaMmColorSpec fgColor; MoaMmColorSpec bgColor; MoaLong blendValue; MoaBool obeyBlend; } MoaMmInkParams;
fgColor | Ink foreground color |
bgColor | Ink background color |
blendValue | Sprite blend value (v5.0: 0-255) |
obeyBlend | If TRUE, use blendValue |
Structure representing the ink parameters of a sprite. If obeyBlend is TRUE, the blendValue field should be obeyed.
MoaMmInkParams | Structure representing the ink parameters of a sprite |
PMoaMmInkParams | Pointer to MoaMmInkParams information structure |
ConstPMoaMmInkParams | Constant pointer to MoaMmInkParams structure |
MoaLong included as a field in the MoaMmPlayerStateInfo structure to represent the playback state of a specific player. Valid values for this type are defined as MOA constants:
Name | Description |
kMoaMmPlayState_Stopped | Movie has stopped (authoring only) |
kMoaMmPlayState_Playing | Movie is playing |
Note that in a player application, a presentation is always playing.
MoaLong type included as a field in the MoaMmPlayerStateInfo structure to represent the playback state of a specific player. Valid values for this type are defined as MOA constants:
Name | Description |
kMoaMmSoundState_Disabled | Sound is disabled |
kMoaMmSoundState_Enabled | Sound is enabled |
typedef struct { MoaMmPlayState playState; MoaMmSoundState soundState; } MoaMmPlayerStateInfo;
playState | Playing or stopped |
soundState | Sound should be on/off |
MoaMmPlayerStateInfo | Structure containing player state information |
PMoaMmPlayerStateInfo | Pointer to MoaMmPlayerStateInfo information structure |
ConstPMoaMmPlayerStateInfo | Constant pointer to MoaMmPlayerStateInfo structure |
Type representing the capabilities of a transition provided by an Xtra. If _DoesScreenAccess is set, the application copies any windows in front of the transition area back into the offscreen buffer before doing the transition. Provides special handling for Macintosh Powerbooks with mirrored displays. Valid values include the following:
Name | Description |
kMoaMmTransCaps_None | Has no special capabilities |
kMoaMmTransCaps_ChangeArea | Supports change area option |
kMoaMmTransCaps_ChunkSize | Supports chunk size control |
kMoaMmTransCaps_Duration | Supports duration control |
kMoaMmTransCaps_CantPaletteInterleave | Can't interleave with palette change |
kMoaMmTransCaps_DoesScreenAccess | Draws directly to screen |
typedef struct { MoaLong chunkSize; MoaLong duration; MoaLong realTime; MoaLong elapsedTime; MoaLong aux; } MoaMmTransInfo
chunkSize | Chunkiness |
duration | Duration (milliseconds) |
realTime | Non-zero if running in real time, 0 if frame-by-frame export |
elapsedTime | Elapsed time (milliseconds) |
aux | Reserved |
Structure providing transition cueing information, passed as a parameter to a transition actor's Cue method.
MoaMmTransInfo | Structure representing transition cueing information |
PMoaMmTransInfo | Pointer to MoaMmTransInfo structure |
ConstPMoaMmTransInfo | Constant pointer to MoaMmTransInfo structure |
Defined in: m3dtypes.h
/* Note: this 3dPoint structure is compatible with the Moa3dVector type */ typedef struct { Moa3dCoord x; Moa3dCoord y; Moa3dCoord z; Moa3dCoord h; /* also known as w */ } Moa3dPoint;
Defined in: mmtypes.h
MoaToMacRGB(PMoaMmRGBTriple pMoaColor, RGBColor FAR * pMacColor)
pMoaColor | Pointer to a MoaMmRGBTriple containing a color |
pMacColor | Pointer to an RGBColor to receive the Macintosh-specific RGB result |
Converts the value located in pMoaColor into a Macintosh-specific RGBColor and places the result in the location specified by pMacColor.
MacToMoaRGB(RGBColor FAR * pMacColor, PMoaMmRGBTriple pMoaColor)
pMacColor | Pointer to an RGBColor |
pMoaColor | Pointer to a to receive MoaMmRGBTriple the MOA-specific result |
Converts the value located in pMacColor into a MOA-specific PMoaMmRGBTriple and places the result in the location specified by pMoaColor.
MoaToWinRGB(PMoaMmRGBTriple pMoaColor, COLORREF winColor)
Converts the value located in pMoaColor into a Windows-specific COLORREF and places the result in the location specified by pWinColor.
WinToMoaRGB(COLORREF winColor, PMoaMmRGBTriple pMoaColor)
Converts the value located in pWinColor into a MOA-specific PMoaMmRGBTriple and places the result in the location specified by pMoaColor.
MoaBool MoaEqualRGB(PMoaMmRGBTriple pMoaColorOne, PMoaMmRGBTriple pMoaColorOne)
Compares two colors.
ColorSpec_MakeFromIndex(PMoaMmColorSpec pSpec, MoaByte theIndex)
pSpec | Pointer to a PMoaMmColorSpec containing the new color specification |
theIndex | Indexed color value |
Creates a new color specification from the index.
ColorSpec_MakeFromMacRGB(PMoaMmColorSpec pSpec, MoaMmRGBTriple FAR * pMacRGBColor)
pSpec | Pointer to a PMoaMmColorSpec containing the new color specification |
pMacRGBColor | The Macintosh RGB color |
Makes a new RGB color specification from a Macintosh RGB value.
ColorSpec_MakeFromWinRGB(pSpec, winColorRef)
pSpec | Pointer to a PMoaMmColorSpec containing the new color specification |
winColorRef | The Windows, 32-bit RGB value |
Makes a new RGB color specification from a Windows COLORREF
Defined in: mmixscrp.h
AccessArgByIndex(n,
pValue)
Access an argument to a scripting language function by numerical
index and return in pValue
.
Defined in: mmtypes.
CuePoint_GetChannel(pCuePoint)
Returns the channel of a cue point structure.
CuePoint_GetIndex(pCuePoint)
Returns index of a cue point structure.
CuePoint_GetName(pCuePoint)
Returns name of cue point structure.
Defined in: mmtypes.h
Constant | Val | Description |
kMoaMmMaxXtraName | 32 | Max byte lgth of Xtra name symbol string |
kMoaMmMaxPropName | 32 | Max byte lgth of property name symbol string |
kMoaMmMaxXtraDisplayName | 64 | Max byte length of Xtra display name |
kMoaMmMaxXtraDisplayCategory | 64 | Max byte length of Xtra display category |
Constant | Description |
kMoaMmGCType_Null | No graphics context or graphics context unknown |
kMoaMmGCType_WinWindow | Microsoft Windows window graphics context |
kMoaMmGCType_WinDIBDC | Microsoft Windows device-independent bitmap context |
kMoaMmGCType_WinDDBDC | Microsoft Windows device-dependent bitmap context |
kMoaMmGCType_MacWindow | Macintosh window graphics context. The value is a WindowRef, not a WindowPtr |
kMoaMmGCType_MacGWorld | Macintosh graphics world graphics context |
kMoaMmGCType_Aux | (reserved) |
Constant | Description |
kMoaMmWinDIBDCFlags_None | |
kMoaMmWinDIBDCFlags_WinG |
Defined in: mmtypes.h
Constant | Description |
kMoaMmTransArea_FullStage | Transition applies to whole stage |
kMoaMmTransArea_ChangeArea | Transition applies to change area only |
These constants represent valid values for a transition Xtras' defaultTransArea registry entry. If the transition Xtras kMoaMmTransCaps_ChangeArea is set, this entry determines the default state of the transition area control. If kMoaMmTransCaps_ChangeArea is not set, the default is automatically forced to kMoaMmTransArea_FullStage.
Constant | Description |
kMoaMmTrans_IsNotComplete | FALSE. Returned if the transition isn't complete |
kMoaMmTrans_IsComplete | TRUE. Returned when the transition is complete |
Use these constants as return values to the pFinished parameter of the IMoaMmXTransitionActor::Continue() method.
Defined in: mmtypes.h
Although an asset Xtra can register any string as its displayCategoryString (kMoaMmDictKey_DisplayCategoryString), using one of these predefined categories is recommended. Using the predefined categories helps the user locate asset Xtras, by grouping similar types together. The predefined categories are also recognized by the application, and the correct translation is automatically substituted in internationalized versions.
An Xtra should register the most-specific category applicable. Some applications, however, may combine some of the categories into one group. For example, Director 5 combines Media Element, Sound, Video and ThreeD in the same submenu.
Category | Value | Description |
kMoaMmSpriteCategory_Unknown | "" | Default category |
kMoaMmSpriteCategory_Media | "Media" | Static media: e.g., bitmaps, static text |
kMoaMmSpriteCategory_Control | "Control" | UI controls, e.g., buttons, check boxes. |
kMoaMmSpriteCategory_Behavior | "Behavior" | behaviors, interactions, scripts: e.g., "gravity" |
kMoaMmSpriteCategory_Database | "Database" | Database management or connectivity |
kMoaMmSpriteCategory_Sound | "Sound" | Any audio |
kMoaMmSpriteCategory_Video | "Video" | Any video or animation |
kMoaMmSpriteCategory_ThreeD | "ThreeD" | Modeling, virtual worlds, etc. |
kMoaMmSpriteCategory_Network | "Network" | Communications and connectivity |
Asset caps constants
Name | Description |
kMoaMmAssetCaps_CanLinkMedia | When this flag is set and you allow an author to create an asset through the import dialog (i.e., importing a Flash movie creates a Flash asset in your cast), they have the option of importing the file as linked, just like with sounds and bitmaps. |
kMoaMmAssetCaps_MustLinkMedia | This means it is always imported as linked, regardless of what the user asks for. QT3 uses this flag, since you can not have an internal QT3 member embedded in the Director file. |
kMoaMmAssetCaps_CanStream | If this flag is not set when a linked Xtra is playing an URL, it first downloads the entire file, then tells your asset to load from the local file, as well as creates any actors for the stage, etc. However, if this flag is set, Director loads your member right away, assuming that you can handle loading yourself from the URL. The Flash asset uses this setting. |
Defined in: mmtypes.h
Use these in the eventMask MoaMmXSpriteCaps field for sprite actors. To receive events from multiple event classes, combine your masks together using the OR operator (|), for example, kMoaMmEventMask_Mouse | kMoaMmEventMask_Key
Name | Description |
kMoaMmEventMask_Every | Receive all events |
kMoaMmEventMask_None | Receive no events |
kMoaMmEventMask_Idle | Receive idles (play-time only) |
kMoaMmEventMask_Mouse | Receive all mouse events |
kMoaMmEventMask_Key | Receive all key and focus events |
kMoaMmEventMask_Step | Receive frame update events |
kMoaMmEventMask_Span | Receive sprite span events |
kMoaMmEventMask_Play | Receive play events (authoring only) |
kMoaMmEventMask_Environment | Receive all environment change events |
Defined in: mmtypes.h
Mac event handler constant
kMoaMmMacEvent_CloseWindow IMoaMacEventHandler constant to close window
Sprite actor event handling
Use these constants as return values to the pHandled parameter of the IMoaMmXSpriteActor::Event() method.
Name | Description |
kMoaMmSprEvent_Handled | TRUE |
kMoaMmSprEvent_Pass | FALSE |
Defined in: mmtypes.h
Used to indicate the state and category of IMoaMmXTool implementations.
Name | Description |
kMoaMmEnabledState_Disabled | MoaMmEnabledState value for a disabled tool |
kMoaMmEnabledState_Enabled | MoaMmEnabledState value for a disabled tool |
kMoaMmToolCategory_Unknown | Empty string-the default category for tools that don't specify a category |
Defined in: mmiservc.h
NID_MmNPaletteChanged NID_MmNStep NID_MmNIdle
Defined in: mmtypes.h
Registry keys are used in an Xtra's IMoaRegister interface to indicate the capabilities it provides.
key: kMoaMmDictKey_SafeForShockwave
string: "safeForShockwave"
type: kMoaMmDictType_SafeForShockwave
base type: kMoaDictType_Bool
Keys used to register Xtras implementing the IMoaMmXAsset interface.
key: kMoaMmDictKey_SymbolString
string: "symbolString"
type: kMoaMmDictType_SymbolString
base type: kMoaDictType_CString
key: kMoaMmDictKey_DisplayNameString
string: "displayNameString"
type: kMoaMmDictType_DisplayNameString
base type: kMoaDictType_CString
Specifies the name to appear for your Xtra in the host application's user interface. If your Xtra doesn't specify a value for this key, the host application uses your symbol string.
key: kMoaMmDictKey_DisplayCategoryString
string: "displayCategoryString"
type: kMoaMmDictType_DisplayCategoryString
base type: kMoaDictType_CString
key: kMoaMmDictKey_ColorIcon
string: "colorIcon"
type: kMoaMmDictType_ColorIcon
base type: kMoaDictType_Bytes
Customizes the asset type icon for your asset by registering a color icon using this dictionary entry. On both Macintosh and Windows, you register a "bag of bytes" for each icon. On the Macintosh, this is the contents of a PicHandle (PICT resource) representing the icon. On Windows, this is the contents of a packed DIB handle (a BITMAP resource). See the OvalSprite sample for the code you need to handle this. In the future, we may provide this is common support code or build resource registration into MOA.
key: kMoaMmDictKey_BWIcon
string: "BWIcon"
type: kMoaMmDictType_BWIcon
base type: kMoaDictType_Bytes
Customizes the asset type icon for your asset by registering a black and white icon using this dictionary entry. On both Macintosh and Windows, you register a "bag of bytes" for each icon. On the Macintosh, this is the contents of a PicHandle (PICT resource) representing the icon. On Windows, this is the contents of a packed DIB handle (a BITMAP resource). See the InkTest sample for the code you need to handle this. In the future, we may provide this is common support code or build resource registration into MOA.
key: kMoaMmDictKey_ActorType
string: "actorType"
type: kMoaMmDictType_ActorType
base type: kMoaDictType_Long
key: kMoaMmDictKey_AssetCaps
string: "assetCaps"
type: kMoaMmDictType_AssetCaps
base type: kMoaDictType_Bytes
key: kMoaMmDictKey_MessageTable
string: "msgTable"
type: kMoaMmDictType_MessageTable
base type: kMoaDictType_CString
Keys used to register Xtras implementing the IMoaMmXTransitionActor interface.
key: kMoaMmDictKey_TransitionCaps
string: "transitionCaps"
type: kMoaMmDictType_TransitionCaps
base type: kMoaDictType_Bytes
key: kMoaMmDictKey_TransDefaultChunkSize
string: "transitionDefaultChunkSize"
type: kMoaMmDictType_TransDefaultChunkSize
base type: kMoaDictType_Long
key: kMoaMmDictKey_TransDefaultArea
string: "transitionDefaultArea"
type: kMoaMmDictType_TransDefaultArea
base type: kMoaDictType_Long
key: kMoaMmDictKey_TransDefaultDuration
string: "transitionDefaultDuration"
type: kMoaMmDictType_TransDefaultDuration
base type: kMoaDictType_Long
Key used to register Xtras implementing the IMoaMmXScript interface.
key: kMoaMmDictKey_MessageTable
symbol: "msgTable"
type: kMoaMmDictType_MessageTable
base type: kMoaDictType_CString
Key used to register Xtras implementing the IMoaMmXTool interface.
key: kMoaMmDictKey_AlwaysEnabled
symbol: "alwaysEnabled"
type:kMoaMmDictType_AlwaysEnabled
base type: kMoaDictType_Long
Defined in: mmtypes.h
Error | Description |
kMoaMmErr_Base | Base for MOA Multimedia API error codes |
kMoaMmErr_NotImplemented | Method not implemented |
kMoaMmErr_InterfaceNotFound | Interface not provided by Xtra or application |
kMoaMmErr_InternalError | Internal error |
kMoaMmErr_XAssetTypeUnknown | Unknown Xtra type |
kMoaMmErr_GCTypeNotSupported | Unsupported graphics context specified |
kMoaMmErr_GCNotModifiable | An attempt is made to modify an application-owned graphics context |
kMoaMmErr_GCNotAvailable | Attempted to get a stage window graphics context or a stage buffer graphics context and one isn't available |
kMoaMmErr_NotRegistered | You attempted to unregister an object (such as a PIMoaMmMacEventHandler) that is not currently registered. |
kMoaMmErr_FunctionNotFound
kMoaMmErr_NoArgExpected
kMoaMmErr_OneArgExpected
kMoaMmErr_TwoArgsExpected
kMoaMmErr_ThreeArgsExpected
kMoaMmErr_FourArgsExpected
kMoaMmErr_WrongNumberOfArgs
kMoaMmErr_NotRegistered
Errors returned by methods of the IMoaMmPropOwner interface.
kMoaMmErr_PropertyNotFound
kMoaMmErr_CannotSetProperty
kMoaMmErr_NoMemForString
kMoaMmErr_ArgOutOfRange
kMoaMmErr_IntegerExpected
kMoaMmErr_SymbolExpected
kMoaMmErr_FloatExpected
kMoaMmErr_StringExpected
kMoaMmErr_PointExpected
kMoaMmErr_RectExpected
Error returned by Xtras implementing the IMoaMmXTool interface.
kMoaMmErr_ToolDisabled Tool disabled