Constants
| [Menu] |
|
Description The following constants indicate handle status.
Remarks For compatibility, Old definitions are remained. MWE_PLY_STAT_STOP MWE_PLY_STAT_PREP MWE_PLY_STAT_PLAYING MWE_PLY_STAT_PLAYEND MWE_PLY_STAT_ERROR |
| [Menu] |
|
Description The following constants indicate vertical sync (Vsync) frequency for decoder.
|
| [Menu] |
|
Description The following constants indicate the type of decode server.
|
| [Menu] |
|
Description The following constants indicate frame composition mode.
|
| [Menu] |
|
Description The following constants indicate the type of file to play for Sofdec.
Remarks For compatibility, Old definitions are remained. MWE_PLY_FTYPE_SFD MWE_PLY_FTYPE_MPV |
| [Menu] |
|
Description The following constants indicate the data format of decoder's outpu buffer.
Remarks For compatibility, Old definitions are remained. MWE_PLY_BUFFMT type MWE_PLY_BUFFMT_MB_YCC420 MWE_PLY_BUFFMT_MB_ARGB8888 MWE_PLY_BUFFMT_PLN_YCC420 |
| [Menu] |
|
Description The following constants indicate output audio volume.
|
| [Menu] |
|
Description The following constants indicate output audio channel.
Remarks For compatibility, Old definitions are remained. MWD_CH_L MWD_CH_R |
| [Menu] |
|
Description The following constants indicate output audio pan. In the MWSFD_PAN_AUTO, pan would be set automatically according to data.
Remarks For compatibility, Old definitions are remained. MWD_PAN_LEFT MWD_PAN_CENTER MWD_PAN_RIGHT MWD_PAN_AUTO |
| [Menu] |
|
Description The following constants indicate horizontal pitch of output frame buffer. Unspecified horizontal pitch of output frame buffer. Frame conversion may be done with width of input frame. |
| [Menu] |
|
Description The following constants indicate luminance alpha's transparence key.
|
| [Menu] |
|
Description The following constants indicate frame type of progressive or interlace.
|
| [Menu] |
|
Description The following constants indicate picture type.
Remarks For compatibility, Old definitions are remained. MWE_PLY_PTYPE type MWE_PLY_PTYPE_I MWE_PLY_PTYPE_P MWE_PLY_PTYPE_B MWE_PLY_PTYPE_D |
| [Menu] |
|
Description The following constants indicate picture type.
|
| [Menu] |
|
Description The following constants indicate video synchronization mode.
Remarks For compatibility, Old definitions are remained. MWD_PLY_SYNC_NONE MWD_PLY_SYNC_VSYNC MWD_PLY_SYNC_AUDIO |
| [Menu] |
|
Description The following constants indicate frame obtain synchronization mode.
|
| [Menu] |
|
Description The following constants indicate minimum/maximum Z value and Z range for Z movie.
|
| [Menu] |
|
Description The following constants indicate video codec type.
|
Macro
| [Menu] |
|
Format MWSFD_TIME2SEC(ncount, tscale) Input ncount: playback time in sample units (number of samples) tscale: sampling frequency (Hz) Output None Return value playback time in real time (sec) Description converts the return value of mwPlyGetTime to sec. Remarks For compatibility, Old definitions are remained. MWD_PLY_TIME2SEC(ncount, tscale) |
| [Menu] |
|
Format MWSFD_TIME2MSEC(ncount, tscale) Input ncount: playback time in sample units (number of samples) tscale: sampling frequency (Hz) Output None Return value playback time in real time (msec) Description converts the return value of mwPlyGetTime to msec. Remarks For compatibility, Old definitions are remained. MWD_PLY_TIME2MSEC(ncount, tscale) |
| [Menu] |
|
Format MWSFD_SIZE_PICUSRBUF(npool, size1pic) Input npool: the number of frame pool which is set in handle creation parameter size1pic: maximum user data size per 1 picture Output None Return value Buffer size of user data in picture layer (byte) Description calculates buffer size of setting paramteter for mwPlyAttachPicUsrBuf(). |
| [Menu] |
|
Format MWSFD_CALC_WORK_VPTS(picnum) Input picnum : the number of picture whitch holding information of time Output None Return value The size of buffer for video PTS (byte) Description calc size for setting by mwPlySetVideoPts function. Remarks Normally, please set the number of picture is 90. 90 pictures is about 3 seconds. |
Data types
| [Menu] |
|
Description Handle to control playback sofdec data. |
| [Menu] |
|
Description Parameter structure for setting the initialization function of Sofdec library.
Remarks For compatibility, Old definitions are remained. MWS_PLY_INIT_SFD type |
| [Menu] |
|
Description Parameter structure to set when creating a Middleware playback handle for Sofdec library.
Remarks Maximum number of frame pools is 14. For compatibility, Old definitions are remained. MWS_PLY_CPRM_SFD type |
| [Menu] |
|
Description This is the movie surface information that is to be obtained when playing a texture movie.
Remarks For compatibility, Old definitions are remained. MWS_PLY_FRM type |
| [Menu] |
|
Description This is subtitle parameter structure that is obtained by mwPlyGetSubtile function.
|
| [Menu] |
|
Description This is the playback information structure for getting playback information function.
|
| [Menu] |
|
Description This is File header information structure that is obtained by mwPlyGetHdrInf function.
|
| [Menu] |
|
Description This is malloc function type that is set to MWSFD library. Format void *(*MwsfdMallocFn)(void *obj, Uint32 size) Input obj : user's object size : size of allocation Output None Return value None |
| [Menu] |
|
Description This is free function type that is set to MWSFD library. Format void (*MwsfdFreeFn)(void *obj, void *ptr) Input obj : user's object ptr : allocated pointer Output None Return value None |
| [Menu] |
|
Description This is the YcbCr plane information.
Remarks For compatibility, Old definitions are remained. MWS_PLY_YCC_PLANE type |
| [Menu] |
|
Description This is make z conversion table function type that is set to MWSFD library. Format void (*MwsfdMakeZTblCbFn)(Uint32 *orgtbl, Float32 znear, Float32 zfar, void *ztbl) Input
orgtbl : the pointer of table whitch convert from output decoding to Z-value (0x00000000~0x7FFFFFFF). the table buffer exist in MWPLY handle's work buffer. znear : near value of Z. zfar : far value of Z. Output ztbl : the pointer of table whitch convert from Z-value (0x00000000~0x7FFFFFFF) to content in Z-Buffer. the table buffer exist in MWPLY handle's work buffer. Return value None |
| [Menu] |
|
Description This is the counter of supply data and consume data.
|
| [Menu] |
|
Description This is the data flow informatin of each decode unit.
|
| [Menu] |
|
Description This is external clock function type that is set to MWSFD library. This function is used on MWSFD_SYNCMODE_EXTCLOCK mode. Format void (*MwsfdExtClockFn)(void *usrobj, Sint32 *time, Sint32 *tunit) Input
mwply :Middleware playback handle Output time :time counter tunit :time unit Return value None |
| [Menu] |
|
Description This is frame information for video codec-specific.
|
| [Menu] |
|
Description This structure is recorded directly information in MPEG-2 bit stream. This information is available in the case of MPEG-1 and Sofdec Video.
|
Function
| [Menu] |
|
Format void mwPlyInitSofdec(MwsfdInitPrm *iprm) Input iprm : Initialization parameter Output None Return value None Description This function initializes the library. Remarks If this function called repeatedly, function runs only first time. If you will change initialize parameter, calls mwPlyFinishSfdFx function, and after call mwPlyInitSfdFx function. Example
|
| [Menu] |
|
Format void mwPlyFinishSfdFx(void) Input None Output None Return value None Description This function performs the library end processing. |
| [Menu] |
|
Format Sint32 mwPlyCalcWorkCprmSfd(MwsfdCrePrm *cprm) Input cprm : Handle creation parameter Output None Return value Work area size (unit: bytes) Description Calculates the work area size. Example
|
| [Menu] |
|
Format MWPLY mwPlyCreateSofdec(MwsfdCrePrm *cprm) Input cprm : Handle creation parameter Output None Return value Middleware playback handle Description This function creates a handle. Example
|
| [Menu] |
|
Format void mwPlyDestroy(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value None Description Destroys the handle. |
| [Menu] |
|
Format void mwPlyStartFname(MWPLY mwply, Char8 *fname) Input mwply : Middleware playback handle fname : file name of sofdec data to play Output None Return value None Description Starts playback sofdec data with specified file name. |
| [Menu] |
| [Menu] |
|
Format void mwPlyRequestStop(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value None Description This is a non-blocking function that just requests command and returns immediately. The handle status can not be changed after this function but after completion of internal stop process. It required for status transition to keep calling ADXM_ExecMain function and wait Vsync function in main loop. This function can avoid having to wait for late function return. The period of time from calling mwPlyRequestStop function till changed to STOP status is indefinite because of dependency on movie decoding and file reading process. |
| [Menu] |
|
Format MwsfdStat mwPlyGetStat(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value Internal handle status Description Gets the internal status of the Middleware playback handle.
|
| [Menu] |
|
Format void mwPlyGetCurFrm(MWPLY mwply, MwsfdFrmObj *frm) Input mwply : Middleware playback handle Output frm : frame information Return value None Description This function gets the frame to be displayed. Remarks (a) If failed to get frame, then frm.bufadr is set to NULL. (b) Release any unused frames by mwPlyRelCurFrm promptly. (c) This function can not use with mwPlyGetFrm/mwPlyRelFrm. Example
|
| [Menu] |
|
Format void mwPlyRelCurFrm(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value None Description Release the frame reserved by mwPlyGetCurFrm. Remarks (a) This function can not use with mwPlyGetFrm/mwPlyRelFrm. Example
|
| [Menu] |
|
Format void mwPlyGetTime(MWPLY mwply, Sint32 *ncount, Sint32 *tscale) Input mwply : Middleware playback handle Output ncount : time tscale : unit of time (Hz) Return value None Description This function gets the playback time. Remarks Actual time (second or millisecond) can be calculated by: sec = MWSFD_TIME2SEC(ncount , tscale); msec = MWSFD_TIME2MSEC(ncount , tscale); |
| [Menu] |
|
Format void mwPlyPause(MWPLY mwply, Sint32 sw) Input mwply : Middleware playback handle sw : Pause / Resume switch (ON=Pause, OFF=Resume) Output None Return value None Description Pause and resume playback. Remarks In the case of playback Video only, Pause in a pause means single step playback. |
| [Menu] |
|
Format Bool mwPlyIsPause(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value TRUE : in pause (= pause ON) FALSE : not in pause (= pause OFF) Description Get pause status whether pause ON/OFF. Return value is independent from middleware playback handle status, but result of calling mwPlyPause function. |
| [Menu] |
|
Format Bool mwPlyGetFrm(MWPLY mwply, Sint32 *frmid, MwsfdFrmObj *frm) Input mwply : Middleware playback handle Output frmid :frame identifier ID frm :frame information Return value TRUE : successed getting frame. FALSE : failed getting frame. Description This function gets the frame to be displayed. To get next frame, application don't need to release previous frame. Application can get each frame only one. The data of frame is hold until releasing the frame or calling mwPlyStop function. This function is need to execute on same thread of mwPlyGetFrm and mwPlyRelFrm need to be called on same thread. This function can not use with mwPlyGetCurFrm/mwPlyRelCurFrm. |
| [Menu] |
|
Format void mwPlyRelFrm(MWPLY mwply, Sint32 frmid) Input
mwply : Middleware playback handle frmid : frame identifier ID Output None Return value None Description This function release the frame indicated by frame ID. Application can release each frame only one. If you repeatedly released, error callback occured. mwPlyGetFrm and mwPlyRelFrm need to be called on same thread. This function can not use with mwPlyGetCurFrm/mwPlyRelCurFrm. |
| [Menu] |
|
Format void mwPlyStartAfs(MWPLY mwply, Sint32 patid, Sint32 fid) Input mwply : Middleware playback handle patid : partition ID fid : faile ID Output None Return value None Description Starts playback by file ID in AFS file. Example
|
| [Menu] |
|
Format void mwPlyStartFnameRange(MWPLY mwply, Char8 *fname, Sint32 offset_sct, Sint32 range_sct) Input mwply : Middleware playback handle fname : File name that includes Sofdec data. offset_sct : Offset of Sofdec data in file [sector] range_sct : Size of Sofdec data [sector] Output None Return value None Description
Start playing Sofdec data by range in file. Please use your original packing file including Sofdec data. |
| [Menu] |
|
Format void mwPlyStartSj (MWPLY mwply, SJ sji) Input mwply : Middleware playback handle sji : Input SJ handle Output None Return value None Description Starts playback by SJ handle. |
| [Menu] |
|
Format void mwPlyTermSupply(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value None Description
Notify the end of data supply to MWPLY handle whitch start by mwPlyStartSj function. Please call this function after you supply all of data to to SJ. After mwPlyTermSupply function was called and all of data was decoded, MWPLY handle's status transit to PLAYEND. |
| [Menu] |
|
Format void mwPlyStartMem (MWPLY mwply, void *addr, Sint32 len) Input mwply : Middleware playback handle addr : memory address len : data size Output None Return value None Description Starts playback on memory movie file. This function can not play seamless loop/continuous playback. This function can play only SFD format, can not play MWSFD_FTYPE_MPV data. Remarks ADX library has "memory file system(MFS)" for reading data on memory. By MFS, mwPlyStartFname/mwPlyStartFnameLp/mwPlyEntryFname functions can play data on memory. About MFS, please refer sample program "adxmfs" of ADX. |
| [Menu] |
|
Format void mwPlyStartFnameLp(MWPLY mwply, Char8 *fname) Input mwply : Middleware playback handle fname : file name of sofdec data to play Output None Return value None Description Starts seamless loop playback sofdec data with specified file name. Remarks (a) mwPlyGetTime() function's return-value means total playback time. (b) The playback is terminated in limit time, even if the playback is in mid-flow. About limit time, please refer to mwPlySetLimitTime, mwPlyGetLimitTime functions. (c) By mwPlyReleaseLp() function, the playback is terminated at end of stream. (d) If movie's total time is vely short (ex. below 2 second), the playback could be not smoothly because reading file is not ready in time. (e) You can play infinite loop by mwPlySetInfiniteSingleLoop function. |
| [Menu] |
|
Format void mwPlyReleaseLp(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value None Description Release seamless loop playback. Remarks The playback is terminated at end of stream. If call function timing is near at end of stream, The playback is terminated at end of next stream. |
| [Menu] |
|
Format void mwPlyStartAfsLp(MWPLY mwply, Sint32 patid, Sint32 fid) Input mwply : Middleware playback handle patid : partition ID fid : faile ID Output None Return value None Description Starts seamless loop playback by file ID in AFS file. Remarks Refer to mwPlyStartFnameLp() function's Remarks. |
| [Menu] |
|
Format void mwPlyStartFnameRangeLp(MWPLY mwply, Char8 *fname, Sint32 offset_sct, Sint32 range_sct) Input mwply : Middleware playback handle fname : File name that includes Sofdec data. offset_sct : Offset of Sofdec data in file [sector] range_sct : Size of Sofdec data [sector] Output None Return value None Description
Start seamless loop playback of Sofdec data by range in file. Please use your original packing file including Sofdec data. |
| [Menu] |
|
Format void mwPlySetInfiniteSingleLoop(MWPLY mwply, Bool sw) Input
mwply : Middleware playback handle sw : mode switch (ON = use infinite loop playback, OFF = not use infinite loop playback) Output None Return value None Description Set infinite single loop playback. The default setting is OFF. The playback is terminated in limit time, even if the playback is in mid-flow. Infinite single movie loop playback function is a kind of automatic restart, finished by reaching playback limit time. Restart process runs inside ADXM_ExecMain function. Restarting movie, playback looks breaking up but handle status is kept as PLAYING. Also playback time, frame ID and other information related to plyaback will be reset by restart process. Strictly, restart process will wake up at not just playback limit time but a certain time before it, that is based on length of the movie. Therefore movie would not stop halfway. Restart process will wake up starting by follow functions exclusively. - mwPlyStartLsnLp For example, this sample code can't use infinite loop playback. mwPlyEntryFname(ply, loopmovie.sfd); mwPlyStartSeamless(ply); mwPlySetSeamlessLp(ply, ON); Remarks
The number of restart can be got by mwPlyGetInfiniteLoopCount function. |
| [Menu] |
|
Format Uint32 mwPlyGetInfiniteLoopCount(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value The count of internal restart for infinite loop playback Description Get the count of internal restart for infinite loop playback. |
| [Menu] |
|
Format void mwPlyEntryFname(MWPLY mwply, Char8 *fname) Input mwply : Middleware playback handle fname : file name of sofdec data to enter play list Output None Return value None Description Add filename to continuous play list. Remarks (a) Assigned file name is deleted from file list after the file was played. (b) Before start playback, can add some files. If the playback is in mid-flow, can add filename. (c) If file is added to file list, the playback could be not smoothly because reading file is not ready in time. Example
|
| [Menu] |
|
Format void mwPlyStartSeamless(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value None Description Starts seamless continuous playback by file list. Remarks (a) mwPlyGetTime() function's return-value means total playback time. (b) The playback is terminated in limit time, even if the playback is in mid-flow. About limit time, please refer to mwPlySetLimitTime, mwPlyGetLimitTime functions. (c) By mwPlyReleaseLp() function, the playback is terminated at end of stream. (d) If movie's total time is vely short (ex. below 2 second), the playback could be not smoothly because reading file is not ready in time. (e) This function can't use infinite single loop playback. Example
|
| [Menu] |
|
Format void mwPlyReleaseSeamless(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value None Description Terminate filelist for continuous playback. Remarks After all file listed was played, the playback is termination. Example
|
| [Menu] |
|
Format void mwPlySetSeamlessLp(MWPLY mwply, Sint32 flg) Input mwply : Middleware playback handle flg : flag (1: loop ON, 0: loop OFF) Output None Return value None Description Set a loop playback of files witch is registered on continuous playback. Example
|
| [Menu] |
|
Format Sint32 mwPlyGetNumSlFiles(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value The number of file listed Description Get The number of file listed for continuous playback at now. Example
|
| [Menu] |
|
Format Char8 *mwPlyGetSlFname(MWPLY mwply, Sint32 stm_no) Input mwply : Middleware playback handle stm_no : Ordinal number which is relative from reading file now Output None Return value File name Description Get the file name in file list. "stm_no" of now reading file is zero. Example
|
| [Menu] |
|
Format void mwPlyEntryAfs(MWPLY mwply, Sint32 patid, Sint32 fid) Input mwply : Middleware playback handle patid : partition ID fid : faile ID Output None Return value None Description Add file to continuous play list by file ID in AFS file. Remarks Refer to mwPlyEntryFname() function's Remarks. |
| [Menu] |
|
Format void mwPlyEntryFnameRange(MWPLY mwply, Char8 *fname, Sint32 offset_sct, Sint32 range_sct) Input mwply : Middleware playback handle fname : File name that includes Sofdec data. offset_sct : Offset of Sofdec data in file [sector] range_sct : Size of Sofdec data [sector] Output None Return value None Description Add filename to continuous play list by range in file. Remarks (a) Assigned file name is deleted from file list after the file was played. (b) Before start playback, can add some files. If the playback is in mid-flow, can add filename. (c) If file is added to file list, the playback could be not smoothly because reading file is not ready in time. |
| [Menu] |
|
Format void mwPlySetOutVol(MWPLY mwply, Sint32 vol) Input mwply : Middleware playback handle vol : Output volume (Minimun value is ?796, Maximum value is 0) Output None Return value None Description Set audio channel number in the multiple audio stream. |
| [Menu] |
|
Format Sint32 mwPlyGetOutVol(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value Output volume (Minimun value is ?796, Maximum value is 0) Description Get current audio volume. |
| [Menu] |
|
Format void mwPlySetOutPan(MWPLY mwply, Sint32 chno, Sint32 pan) Input mwply : Middleware playback handle chno : Channel number (MWSFD_CH_L / MWSFD_CH_R) pan : Output pan value (-15 to 15) Output None Return value None Description Set output pan in each channel. |
| [Menu] |
|
Format Sint32 mwPlyGetOutPan(MWPLY mwply, Sint32 chno) Input mwply : Middleware playback handle chno : Channel number (MWSFD_CH_L / MWSFD_CH_R) Output None Return value Output pan value (-15 to 15) Description Get current audio pan in each channel. |
| [Menu] |
|
Format Sint32 mwPlyGetNumAudioCh(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value The number of audio channel streams. Description Get the number of audio channel streams in SFD file. Remarks This function is enabled after that handle's status is MWSFD_STAT_PLAYING. |
| [Menu] |
|
Format void mwPlySetAudioCh(MWPLY mwply, Sint32 ch) Input mwply : Middleware playback handle ch : Channel number (Minimun value is 0) Output None Return value None Description Set audio channel number in the multiple audio stream. |
| [Menu] |
|
Format Sint32 mwPlyGetAudioCh(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value
Channel number Description Get audio channel number playing now. |
| [Menu] |
|
Format Sint32 mwPlyGetAhxWorkSize(void) Input None Output None Return value size of work buffer for AHX Description Get size of work buffer for AHX |
| [Menu] |
|
Format void mwPlyAttachAhx(MWPLY mwply, void *wkptr, Sint32 wksize, Sint32 ch) Input mwply : Middleware playback handle wkptr : pointer of work buffer wksize : size of work buffer ch : channel number of AHX stream Output None Return value None Description Attach AHX. |
| [Menu] |
|
Format void mwPlyDetachAhx(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value None Description Detach AHX. |
| [Menu] |
|
Format void mwPlySetAhxCh(MWPLY mwply, Sint32 ch) Input mwply : Middleware playback handle ch : channel number of AHX Output None Return value None Description Set channel number of AHX. |
| [Menu] |
|
Format Sint32 mwPlyGetSubtitle(MWPLY mwply, Uint8 *bufptr, Sint32 bufsize, MwsfdSbtPrm *sbtprm) Input
mwply : Middleware playback handle bufptr : pointer of user's buffer bufsize : size of user's buffer [byte] Output sbtprm : Subtitle parameter Return value 1 : Got subtitle data on time other : Didn't get subtitle data Description This function copies subtitle to user's buffer and get subtitle parameter. While subtitle's duration time of display, this function get same data repeatedly. For use, please set MWSFD_COMPO_AUTO to composition mode of MWPLY handle. |
| [Menu] |
|
Format void mwPlySetSubtitleCh(MWPLY mwply, Sint32 chno) Input
mwply : Middleware playback handle chno : channel number of subtitle data Output None Return value None Description Set channel of subtitle data |
| [Menu] |
|
Format Sint32 mwPlyGetNumSubtitleCh(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value The number of subtitle channel. Description Get the number of subtitle channel in SFD file. Remarks This function is enabled after that handle's status is MWSFD_STAT_PLAYING. |
| [Menu] |
|
Format void mwPlySetSubtitleScount(MWPLY mwply, Sint32 scount) Input
mwply : Middleware playback handle scount : shift time count (sec = scount / tunit) Output None Return value None Description Set shift time of subtitle data |
| [Menu] |
|
Format void mwPlyFxSetOutBufSize(MWPLY mwply, Sint32 width, Sint32 height) Input mwply : Middleware playback handle pitch : width of output buffer (Byte) height : height of output buffer (Byte) Output None Return value None Description Set size of output buffer. |
| [Menu] |
|
Format void mwPlyFxGetOutBufPitchHeight(MWPLY mwply, Sint32 *pitch, Sint32 *height) Input mwply : Middleware playback handle Output pitch : width of output buffer (Byte) height : height of output buffer (Byte) Return value None Description Get size of output buffer. Remarks If unset condition, this function's return-value is "MWSFD_DFL_OUTBUFSIZE". |
| [Menu] |
|
Format void mwPlyFxSetCompoMode(MWPLY mwply, Sint32 mode) Input mwply : Middleware playback handle mode : composition mode Output None Return value None Description Set composition mode. |
| [Menu] |
|
Format Sint32 mwPlyFxGetCompoMode(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value Composition mode Description Get composition mode. |
| [Menu] |
|
Format void mwPlyFxSetLumiPrm(MWPLY mwply, Sint32 in_th, Sint32 out_th, MwsfdLumiKey key) Input mwply : Middleware playback handle in_th : transparence in-threshold (min: 0 max: 255) out_th : transparence out-threshold (min: 0 max: 255) key : transparence key Output None Return value None Description Set luminance key alpha parameter. |
| [Menu] |
|
Format void mwPlyFxGetLumiPrm(MWPLY mwply, Sint32 *in_th, Sint32 *out_th, MwsfdLumiKey *key) Input mwply : Middleware playback handle Output in_th : transparence in-threshold (min: 0 max: 255) out_th : transparence out-threshold (min: 0 max: 255) key : transparence key Return value None Description Get luminance key alpha parameter. |
| [Menu] |
|
Format void mwPlyFxSetAlp3Prm(MWPLY mwply, Uint8 zero, Uint8 half, Uint8 full) Input
mwply : Middleware playback handle zero : alpha value (0~255) for transparence pixels half : alpha value (0~255) for translucence pixels full : alpha value (0~255) for opaque pixels Output None Return value None Description Set alpha 3-value parameter. Remarks
Please use to adjust translucence pixels. Alpha 3-value movie was encoded based on transparence/translucence/opaque pixcels. If you change alpha vlue of transparence/opaque pixels extremely, NOISE may be occured. |
| [Menu] |
|
Format void mwPlyFxGetAlp3Prm(MWPLY mwply, Uint8 *zero, Uint8 *half, Uint8 *full) Input mwply : Middleware playback handle Output zero : alpha value (0~255) for transparence pixels half : alpha value (0~255) for translucence pixels full : alpha value (0~255) for opaque pixels Return value None Description Get alpha 3-value parameter. |
| [Menu] |
|
Format void mwPlyFxCnvFrmZ16(MWPLY mwply, MwsfdFrmObj *frm, Uint8 *zout) Input mwply : Middleware playback handle frm : Frame Information Output zout : Z-buffer pointer Return value None Description Convert to 16bit-Z format from decoded frame. |
| [Menu] |
|
Format void mwPlyFxCnvFrmZ32(MWPLY mwply, MwsfdFrmObj *frm, Uint8 *zout) Input mwply : Middleware playback handle frm : Frame Information Output zout : Z-buffer pointer Return value None Description Convert to 32bit-Z format from decoded frame. |
| [Menu] |
|
Format void mwPlyFxSetZclip(MWPLY mwply, Float32 znear, Float32 zfar) Input mwply : Middleware playback handle znear : Z-near value zfar : Z-far value Output None Return value None Description Set Z-clip to MWPLY handle. |
| [Menu] |
|
Format void mwPlyFxGetZclip(MWPLY mwply, Float32 *znear, Float32 *zfar) Input mwply : Middleware playback handle Output znear : Z-near value zfar : Z-far value Return value None Description Get Z-clip assigned in MWPLY handle. |
| [Menu] |
|
Format void mwPlyFxSetCbFnMakeZTbl(MWPLY mwply, MwsfdMakeZTblCbFn func) Input
mwply : Middleware playback handle func : function to make Z conversion table Output None Return value None Description
Normally do not call this function. Set callback function for making z table. |
| [Menu] |
|
Format Sint32 mwPlyGetFxType(mwply) Input
mwply : Middleware playback handle Return value F/X type Description Get F/X type in Sofdec data. This function can get following F/X type. - MWSFD_COMPO_OPAQ : Opaque - MWSFD_COMPO_ALPHFULL : Full-Alpha - MWSFD_COMPO_ALPH3 : 3value-Alpha Remarks This function is enabled after that handle's status is MWSFD_STAT_PLAYING. |
| [Menu] |
|
Format void mwPlyGetHdrInf(Sint8 *buf, Sint32 bsize, MwsfdHdrInf *hdrinf) Input
buf : Address of data bsize : Size of data Output hdrinf : file header information structure Return value None Description Analyze the SFD file. Please input the top 20 Kbyte of SFD file on memory. |
| [Menu] |
|
Format Sint32 mwPlyGetTotalFrmNum(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value The number of movie frame Description Get the number of movie frame Remarks This function is enabled after that handle's status is MWSFD_STAT_PLAYING. Example
|
| [Menu] |
|
Format void mwPlyGetPlayingHdrInf(MWPLY mwply, MwsfdHdrInf *hdrinf) Input mwply : Middleware playback handle Output hdrinf : file header information structure Return value None Description Get movie header info from playing movie file. Remarks This function is enabled after that handle's status is MWSFD_STAT_PLAYING. This function can get only information from SFD file. |
| [Menu] |
|
Format void mwPlySetMallocFn(MwsfdMallocFn mallocfn, MwsfdFreeFn freefn, void *obj) Input mwply : Middleware playback handle mallocfn : malloc function freefun : free function obj : argument of malloc / free function Output None Return value None Description The work buffer of a MWPLY handle is securable using registered Malloc / free function. A work buffer is secured by two or more times of Malloc. The memory secured at the time of handle creation is released at the time of handle destruction. When you use the registered function, it is a parameter at the time of handle creation, and please make a buffer address of creation parameter into NULL. Remarks The registered function is used only within mwPlyCreateSofdec() and mwPlyDestroy(). |
| [Menu] |
|
Format void mwPlySetSpeed(MWPLY mwply, Sint32 speed) Input mwply : Middleware playback handle speed : Playback speed (1000 = x1 speed) Output None Return value None Description Set speed of playback. Playback speed depends on load average of decoding movie. Therefore actual playback speed is not necessarily correspond to setting speed. |
| [Menu] |
|
Format void mwPlySetSyncMode(MWPLY mwply, Sint32 mode) Input mwply : Middleware playback handle mode : synchronization mode Output None Return value None Description Set synchronization mode. If you change the syncmode, please call this function before start playback.
Remarks Default mode is the following.
In the case of MWSFD_FTYPE_VONLYSFD, default mode is MWSFD_SYNCMODE_VSYNC, even if SFD file contained audio. |
| [Menu] |
|
Format Sint32 mwPlyGetSyncMode(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value MWSFD_SYNCMODE_~ : synchronization mode macro Description Get synchronization mode. |
| [Menu] |
|
Format void mwPlySetTimerCh(Sint32 chno) Input chno : timer channel Output None Return value None Description Set timer channel. If you don't use timer, please set -1 as channel number. |
| [Menu] |
|
Format Sint32 mwPlyGetTimerCh(void) Input None Output None Return value
The number of timer channel. -1 : No use timer Description Get the number of timer channel |
| [Menu] |
|
Format void mwPlyAttachPicUsrBuf(MWPLY mwply, void *bufptr, Sint32 bufsize, Sint32 size1pic) Input mwply : Middleware playback handle bufptr : Pointer to user data in picture layer bufsize : Data size of user data in picture layer size1pic : Maximum user data size per 1 picture Output None Return value None Description buffer setting function to get user data in each frame. After setting, some value would be set to member usrdatptr, usrdatsize of structure MwsfdFrmObj which is acquired by mwPlyGetCurFrm(). If size of user data exceeds size1pic, you can not refer to user data exceeded size1pic. Remarks Sofdec CRAFT does not have function to fill in user data. |
| [Menu] |
|
Format void mwPlySetFrmSync(MWPLY mwply, MwsfdFrmSync frmsync) Input mwply : Middleware playback handle frmsync : frame obtain synchronization mode Output None Return value None Description Set frame obtain synchronization mode.
Remarks Default mode is no synchronization. |
| [Menu] |
|
Format MwsfdFrmSync mwPlyGetFrmSync(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value MWSFD_FRMSYNC_~ : frame obtain synchronization mode macro Description Get frame obtain synchronization mode. |
| [Menu] |
|
Format void mwPlySetCbExtClock(MWPLY mwply, MwsfdExtClockFn extclock_fn, Sint32 extclock_max, void *extclock_usrobj) Input
mwply :Middleware playback handle extclock_fn :External clock function extclock_max :The maximum namber of clock value (In the case fo 8bit: 0x000000FF, 32bit:0xFFFFFFFF) extclock_usrobj :User object (first argument of external clock function) Output None Return value None Description Set external clock callback function for MWSFD_SYNCMODE_EXTCLOCK mode. The external clock callback need satisfy the following conditions. - Return the value that always increases monotonously by the same pace. - The overflow of the clock value must be larger more enough than the update time cycle. (The update time cycle is generaly Vsync.) The external clock callback function is called at the following timing. - If using ADX thread and auto update Sofdec time mode, then the callback function is called from Vsync thread. - If not using ADX thread and auto update Sofdec time mode, then the callback function is called from ADXM_ExecMain function. - If not auto update Sofdec time mode, then the callback function is called from mwPlyUpdateTime function. Remarks
If latest clock value is less than previous one, Sofdec library assume overflow of clock value. When the overflow occurred, Sofdec library compensates the clock value : clock value = latest value - previous value + clock_max + 1. |
| [Menu] |
|
Format void mwPlySetUpdateTimeAuto(MWPLY mwply, Bool sw) Input
mwply :Middleware playback handle sw : mode switch (ON = use auto update time, OFF = not use auto update time) Output None Return value None Description Set auto update time mode. The default mode is ON (use auto update time). If you change the mode, please call this function before start playback. When not use auto update time mode, the application need to call mwPlyUpdateTime function for update time. For example, this function is used when Vsync thread of ADX can't synchronize with main loop. Remarks
When use auto update time mode , updating time is executed at the following timing. - If using ADX thread, updating is executed in Vsync thread of ADX. - If not using ADX thread, updating is executed in ADXM_ExecMain function. You can use ADX thread when you call ADXM_SetupThread or ADXM_SetupFramework function before initialization of ADX/Sofdec. |
| [Menu] |
|
Format void mwPlyUpdateTime(MWPLY mwply) Input
mwply:Middleware playback handle. If you use NULL, it is for all handles. Output None Return value None Description Update Sofdec time. If you use not auto update time mode by mwPlySetUpdateTimeAuto function, please call this function once per main loop. Please call this function at the same timing in vsync (ex. after wait vsync). If you use auto update time mode, this function don't update time. |
| [Menu] |
|
Format const Char8 *mwPlyGetVersionStr(void) Input None Output None Return value Pointer of version string Description Get Sofdec library version number string. |
| [Menu] |
|
Format void mwPlySetLimitTime(MWPLY mwply, Sint32 sec) Input mwply : Middleware playback handle sec : playback's time limit[second] Output None Return value None Description Set limit time of playback. The playback(simple, seamless loop, seamless concatenation) is terminated in limit time, even if the playback is in mid-flow. playback limit time depends on following condition. - Vsync frequency (one of handle creation parameter) - with or without audio - frame rate of the movie You can't set limit time over the default limit. Typical playback limit time is follows. - 29.97fps frame rate movie without audio 59.94Hz : 99hrs 31min 11sec 50.00Hz : 119hrs 18min 15sec 60.00Hz : 99hrs 25min 12sec - movie with audio 59.94Hz : 9hrs 57min 06sec 50.00Hz : 11hrs 55min 48sec 60.00Hz : 9hrs 56min 30sec Generally playback limit time without audio is about 10 times longer than with audio except 23.976fps that is about 4 times longer. Remarks Playback limit time can be got by mwPlyGetLimitTime function after changing to PLAYING state. |
| [Menu] |
|
Format Sint32 mwPlyGetLimitTime(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value The limit time [msec]. Description
Get limit time of playback. Please call this function after the handle status transit to PLAYING. Remarks About limit time, please refer to mwPlySetLimitTime function. |
| [Menu] |
|
Format void mwPlyGetPlyInf(MWPLY mwply, MwsfdPlyInf *plyinf) Input mwply : Middleware playback handle Output plyinf : playback information structure Return value None Description Get statistic playback information. Each information as below is obtainable. (a) Count of drop frame ; mwPlyGetNumDropFrm (b) Count of decode frame skip ; mwPlyGetNumSkipDec (c) Count of display frame skip ; mwPlyGetNumSkipDisp (d) Count of empty-B picture skip ; mwPlyGetNumSkipEmptyB Difference of return value of above function are as follows. (yes = obtainable, no = is not obtainable)
|
| [Menu] |
|
Format Sint32 mwPlyGetNumTotalDec(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value The total number of frames decoded. Description Get the total number of frames docoded in the playback. |
| [Menu] |
|
Format Sint32 mwPlyGetNumTotalDec(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value The number of frames pooled. Description Get the number of frames pooled which is docoded. After last frame was released, this function return -1. |
| [Menu] |
|
Format Sint32 mwPlyGetNumDropFrm(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value The number of dropped frames. Description Get the number of decoding skip. In setting skip empty-B picture, this function's return-value doesn't contain the count of empty-B picture. |
| [Menu] |
|
Format Sint32 mwPlyGetNumSkipDec(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value The number of skipped frame to decode. Description Get the total number of decoding skip. Remarks This counter is increased by a frame that does not finish decoding till it's time to display. |
| [Menu] |
|
Format Sint32 mwPlyGetNumSkipDisp(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value The number of skipped frame to decode. Description Get the total number of skipped frame to display. Remarks This counter is increased by a frame that is not obtained till it's time to display. |
| [Menu] |
|
Format Sint32 mwPlyGetNumSkipEmptyB(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value The number of skipped empty-B picture. Description Get the number of skipped empty-B picture. In setting skip empty-B picture, this function return 0. |
| [Menu] |
|
Format void mwPlyGetFlowInf(MWPLY mwply, MwsfdFlowInf *flowinf) Input mwply : Middleware playback handle Output flowinf : data flow information Return value None Description Get data flow information of system stream. |
| [Menu] |
|
Format void mwPlySetBpicSkip(MWPLY mwply, Bool sw) Input mwply : Middleware playback handle sw : setting switch (ON: skip B-picture, OFF: don't skip B-picture) Output None Return value None Description Set switch skip B-picture decode. |
| [Menu] |
|
Format void mwPlySetEmptyBpicSkip(MWPLY mwply, Bool sw) Input mwply : Middleware playback handle sw : setting switch (ON: skip empty-B, OFF: don't skip empty-B) Output None Return value None Description Set switch skip empty-B-picture decode. |
| [Menu] |
|
Format void mwPlySetPpicSkip(MWPLY mwply, Bool sw) Input mwply : Middleware playback handle sw : setting switch (ON: skip P-picture, OFF: don't skip P-picture) Output None Return value None Description Set switch skip P-picture decode. |
| [Menu] |
| [Menu] |
| [Menu] |
|
Format void *mwPlyGetSfdHn(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value Video decoder handle Description Get video decoder handle in MWPLY handle. |
| [Menu] |
|
Format Sint32 mwPlyGetNumRemainFrm(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value the number of gettable new frames Description This function get the number of gettable new frames. This number don't include frames which already application got. If this function return 0, applicatin can not get next frame. |
| [Menu] |
|
Format void mwPlySwitchToIdle(void) Input None Output None Return value None Description Change into idle thread, that is, Main thread is falling a sleep until next VSync. If you use MWSFD Ver.3.30 or later, mwPlySwitchToIdle function is same ADXM_WaitVsync function. Please substitute ADXM_WaitVsync function for user function that waits for Vsync. |
| [Menu] |
|
Format Bool mwPlyIsSvrBdr(void) Input None Output None Return value TRUE : in server border FALSE : not in server border Description Determine whether process is in server border. |
| [Menu] |
|
Format void mwPlyCalcYccPlane(Uint8 *bufptr, Sint32 width, Sint32 height,MWS_PLY_YCC_PLANE *ycc) Input bufptr : decoder's output buffer address width : width by number of pixels height : height by number of pixels Output ycc : YCbCr plane information Return value None Description Calculate each of Y, Cb, Cr buffer pointer and width from decoder's output buffer address. |
| [Menu] |
|
Format void mwPlySetAudioSw(MWPLY mwply, Sint32 sw) Input mwply : Middleware playback handle sw : Audio output switch (ON=decode audio, OFF=skip to decode audio) Output None Return value None Description Set audio output switch in decoder level. If you change the sudio switch, please call this function before start playback. Remarks Mute OFF is realised by volume 0, mwPlySetOutVol(mwply, 0). |
| [Menu] |
|
Format Sint32 mwPlyGetNumVideoCh(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value The number of video channel streams. Description Get the number of video channel streams in SFD file. Remarks This function is enabled after that handle's status is MWSFD_STAT_PLAYING. |
| [Menu] |
|
Format void mwPlySetVideoCh(MWPLY mwply, Sint32 ch) Input mwply : Middleware playback handle ch : Channel number (Minimun value is 0) Output None Return value None Description Set audio channel number in the multiple video stream. |
| [Menu] |
|
Format Sint32 mwPlyGetVideoCh(MWPLY mwply) Input mwply : Middleware playback handle Output None Return value
Channel number Description Get video channel number playing now. |
| [Menu] |
|
Format void mwPlySetVideoSw(MWPLY mwply, Sint32 sw) Input mwply : Middleware playback handle sw : Video output switch (ON=decode video, OFF=skip to decode video) Output None Return value None Description Set video output switch in decoder level. |
| [Menu] |
|
Format void mwPlyVsyncHndl (MWPLY mwply) Input mwply : Middleware playback handle Output None Return value None Description Execute MWSFD library's vsync process about only one MWPLY handle. Remarks This function is not available. |
| [Menu] |
|
Format Bool mwPlyExecSvrHndl (MWPLY mwply) Input mwply : Middleware playback handle Output None Return value TRUE : server process request more execution. FALSE : server process don't request more execution now. Description Execute MWSFD library's server process about only one MWPLY handle. Remarks Normally, Calling this funcition by application is prohibited. |
| [Menu] |
|
Format Bool mwPlyExecVsyncServer(void) Input None Output None Return value TRUE : process for time update that should be done remains. FALSE : process for time update has finished. Description Appilication that does not use ADX thread function must call this function instead. Normally do not call this function. |
| [Menu] |
|
Format Bool mwPlyExecDecServer(void) Input None Output None Return value TRUE : process for decode that should be done remains. FALSE : process for decode has finished. Description Appilication that does not use ADX thread function must call this function instead. Normally do not call this function. |