home *** CD-ROM | disk | FTP | other *** search
-
- /*
- * Copyright (c) 1991, Microsoft Corporation. All rights reserved.
- */
-
- /***************************************************************************
-
- WINDOWS MUTLIMEDIA MOVIE Player 2.0
- Beta Release
- Loadable DLL Driver
- (c) Copyright 1990 MacroMind
- All Rights Reserved.
-
- *****************************************************************************/
- /*
- This file to be included in any applicaton wishing to play back Windows
- MultiMedia Movies.
- */
-
- /*
- ------------------------------------------------------------------------------
- Constants:
- ------------------------------------------------------------------------------
- */
-
- /***************************\
- ERROR CODES
- \***************************/
-
- #define MMPERR_NO_ERROR 0 /* Function succesful, no error dude */
- #define MMPERR_FATAL_ERROR -101 /* fatal error -- program abort */
- #define MMPERR_STAGE_ERROR -102 /* error creating stage window */
- #define MMPERR_FILE_VER -110 /* wrong file version */
- #define MMPERR_FILE_TYPE -111 /* wrong file type -- not an MMP movie file */
- #define MMPERR_OPEN_ERROR -112 /* DOS error opening file */
- #define MMPERR_READ_ERROR -113 /* DOS read error on file */
- #define MMPERR_EOF_ERROR -115 /* unexpected end of file */
- #define MMPERR_REC_HEADER -116 /* invalid record header */
- #define MMPERR_CAST_ERROR -117 /* error reading cast */
- #define MMPERR_CAST_MAP_ERROR -118 /* cast/bitmap mismatch */
- #define MMPERR_MEM_ALLOC -121 /* memory allocation error */
-
- #define MMPERR_BAD_ID -412 /* re-entered (from FrameHook) with different ID */
- #define MMPERR_BAD_PARM -426 /* bad parameters */
-
- #define MMP_MOVEOK 1 /* boolean field definition */
- #define SCRIPTCHANNEL -1 /* definition for a script channel action code */
-
- #define MMP_MAXERRORLENGTH 128 /* Guaranteed maximum length of error strings */
-
- /*
- Constants used with the Animation
- */
-
- #define MMP_FRAME_FIRST 1
- #define MMP_FRAME_LAST 0x7FFF
-
- //#define MMP_VERSION 0x00000032L
-
- /*
- mmpSetTempo
- */
-
- #define MMPTEMPO_MOUSEWAIT -128
-
- /*
- Animation status: returned from mmpAnimate and mmpAnimStatus
- */
-
- #define MMP_TEMPO_WAIT 2 // waiting for enuf time to pass to advance frame
- #define MMP_ANIM_DRAW 1 // next frame drawn on this call
- #define MMP_MOUSE_WAIT -1 // animation is waiting for mouse click
- #define MMP_DEVICE_WAIT -2 // animation is waiting for device to finish
- #define MMP_ANIM_STOPPED -3 // animation is stopped
-
- /*
- Use at own Risk (with mmpGetInfo) -- peek into internal structures:
- */
-
- #define MMPINFO_LABELLIST -6
- #define MMPINFO_LABELTEXT -7
- #define MMPINFO_LABELCOUNT -8
- #define MMPINFO_ACTIONLIST -9
- #define MMPINFO_ACTIONTEXT -10
- #define MMPINFO_ACTIONCOUNT -11
-
- /*
- MMP_STAGE_ options for MMPSetStage and MMPGetStage.
- */
-
- #define MMP_STAGE_CENTER 0x1 /* stage rect is centered in stage wind */
- #define MMP_STAGE_OFFSET 0x2 /* stage rect is offset to a fixed location */
- #define MMP_STAGE_BORDER 0x4 /* border is drawn around stage rect */
- #define MMP_STAGE_FIXED 0x8 /* stage size doesn't change between movies */
-
- /*
- MMP_LOAD_ options.
- */
-
- #define MMP_LOAD_REFERENCED 0x1 /* load if referenced from score */
- #define MMP_LOAD_NOSTATIC 0x2
- #define MMP_LOAD_NOBUFFER 0x4
- // note: MMP_DRAW_FRAME (0xC000) is also an Load option
-
- /*
- MMP_FRAME_ options for MMPStepFrame, MMPGoToFrame, MMPDrawFrame, etc. !!!
- High order bits are used since they may be combined with other options.
- */
-
- #define MMP_ERASE_FRAME 0x2000 /* erase entire stage */
- #define MMP_DRAW_FRAME 0xC000 // (MMP_FRAME_IMAGE | MMP_FRAME_UPDATE)
-
- /*
- ------------------------------------------------------------------------------
- Types:
- ------------------------------------------------------------------------------
- */
-
- typedef DWORD MMPID; /* ID of an MMP animation port */
-
- typedef struct {
- DWORD dwFileVersion;
- DWORD dwTotalFrames;
- DWORD dwInitialFramesPerSecond;
- WORD wPixelDepth;
- DWORD dwMovieExtentX;
- DWORD dwMovieExtentY;
- char achFullMacName[128];
- } MMPINFO, FAR *LPMMPINFO;
-
- /* per-frame-hook callback */
- typedef BOOL (FAR PASCAL *LPMMPFRAMEHOOK)(MMPID id, WORD msg, WORD wParam, LONG lParam);
-
- /* messages passed to callback */
-
- #define MMP_HOOK_FRAME 0x0003
- #define MMP_HOOK_SCRIPT 0x0004
-
- /*
- ------------------------------------------------------------------------------
- Functions:
- ------------------------------------------------------------------------------
- */
-
- extern MMPID FAR PASCAL
- mmpOpen( HWND hWndStage, WORD fsOptions );
-
- extern BOOL FAR PASCAL
- mmpClose( MMPID id, WORD fsOptions );
-
- extern BOOL FAR PASCAL
- mmpStartAnimating( MMPID id, WORD fsOptions );
-
- extern int FAR PASCAL /* function modified CRK 8-30-90 */
- mmpAnimate( MMPID id );
-
- extern int FAR PASCAL
- mmpAnimStatus( MMPID id );
-
- extern BOOL FAR PASCAL
- mmpStopAnimating( MMPID id, WORD fsOptions );
-
- extern BOOL FAR PASCAL
- mmpGoToFrame( MMPID id, short sFrameCtr, WORD fsOptions );
-
- extern BOOL FAR PASCAL
- mmpUpdate( MMPID id, HDC hDC, RECT FAR * prectArea );
-
- extern BOOL FAR PASCAL
- mmpSetFrameHook( MMPID id, LPMMPFRAMEHOOK lpFrameHook );
-
- extern LPMMPFRAMEHOOK FAR PASCAL
- mmpGetFrameHook( MMPID id );
-
- extern BOOL FAR PASCAL
- mmpGetFileInfo( char FAR * pstrFileName, LPMMPINFO lpMMPInfo );
-
- extern BOOL FAR PASCAL
- mmpGetMovieInfo( MMPID id, LPMMPINFO lpMMPInfo );
-
- extern BOOL FAR PASCAL
- mmpLoadFile( MMPID id, char FAR *pstrFileName, WORD fsOptions );
-
- extern BOOL FAR PASCAL
- mmpFreeFile( MMPID id, WORD fsOptions );
-
- extern BOOL FAR PASCAL
- mmpFileLoaded( MMPID id );
-
- extern short FAR PASCAL
- mmpError( MMPID id, LPSTR szError, WORD wBufLen);
-
- extern BOOL FAR PASCAL
- mmpAnimStopped( MMPID id );
-
- extern short FAR PASCAL
- mmpGetCurFrame( MMPID id );
-
- extern BOOL FAR PASCAL
- mmpGetMute( MMPID id, BYTE FAR *bpSquelchOn);
-
- extern BOOL FAR PASCAL
- mmpSetMute( MMPID id, BOOL bbSquelchOn );
-
- extern BOOL FAR PASCAL
- mmpSetStage( MMPID id, HWND hWndStage, RECT FAR * prectStage, WORD fsOptions );
-
- extern BOOL FAR PASCAL
- mmpGetStage( MMPID id, HWND FAR *phWndStage, RECT FAR * prectStage, LPWORD pfsOptions );
-
- extern BOOL FAR PASCAL
- mmpSetRepeat( MMPID id, BOOL bbRepeat );
-
- extern BOOL FAR PASCAL
- mmpGetRepeat( MMPID id );
-
- extern BOOL FAR PASCAL
- mmpSetDC( MMPID id, HDC hDC );
-
- extern HPALETTE FAR PASCAL
- mmpGetPaletteHandle( MMPID id );
-
-
- extern BOOL FAR PASCAL
- mmpSetTempo( MMPID id, short sTempo );
-
- extern short FAR PASCAL
- mmpGetTempo( MMPID id );
-
- extern BOOL FAR PASCAL
- mmpGetInfo(MMPID id, int nIndex, LPVOID pvData, WORD wLen);
-
- extern BOOL FAR PASCAL
- mmpSetInfo(MMPID id, int nIndex, LPVOID pvData, WORD wLen);
-