Clip_Impl.h
上传用户:super_houu
上传日期:2008-09-21
资源大小:4099k
文件大小:5k
- /****************************************************************************************
- * Copyright (c) 2002 ZORAN Corporation, All Rights Reserved
- * THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF ZORAN CORPORATION
- *
- * File: $Workfile: Clip_Impl.h $
- *
- * Description:
- * ============
- *
- *
- * Log:
- * ====
- * $Revision: 5 $
- * Last Modified by $Author: Jerryc $ at $Modtime: 03-03-03 15:17 $
- ****************************************************************************************
- * Updates:
- ****************************************************************************************
- * $Log: /SourceCode/I64_Common/I64_Reference/Playcore/Nav_Clips/Clip_Impl.h $
- *
- * 5 03-03-04 11:34 Jerryc
- * jerry cai, merge new nav clips lib
- *
- * 4 03-02-08 0:34 Leslie
- * Add MANUAL_DIRECTORY_EXPLORER
- *
- * 3 03-01-10 12:21 Leslie
- * Add wide-character strings support
- *
- * 2 03-01-09 12:30 Leslie
- *
- * 1 10/30/02 18:05 Rond
- *
- * 1 11/09/02 15:48 Atai
- *
- * 3 13/08/02 13:47 Nirm
- * - Clip_isFinished() replaced by Clip_getStatus().
- *
- * 2 2/08/02 19:47 Nirm
- * - Added Caching capability.
- *
- * 1 30/07/02 18:39 Nirm
- ****************************************************************************************/
- #include "Config.h" // Global Configuration - do not remove!
- #ifndef __CLIP_IMPL_H_
- #define __CLIP_IMPL_H_
- #include "IncludeSysDefs.h"
- #include "PlaycoreFileSysFileSystem.h"
- #include "PlaycoreNav_ClipsClip.h"
- /////////////////////////////////////////////////////////////////////////////
- // Macros
- // Valid Extenions List
- #define CLIP_VALID_EXTENSIONS(clipTypeName) g_a##clipTypeName##Extensions
- #define BEGIN_CLIP_VALID_EXTENSIONS_MAP(clipTypeName)
- static CONST LPCWSTR CLIP_VALID_EXTENSIONS(clipTypeName)[]= {
- #define CLIP_VALID_EXTENSIONS_ENTRY(sExtension) sExtension,
- #define END_CLIP_VALID_EXTENSIONS_MAP() NULL };
- // Constant Attributes
- #define CLIP_CONST_ATTR(clipTypeName) g_##clipTypeName##Const
- #define DECLARE_CLIP_VTABLE(pfGetExtendedInfo, pfPlay, pfPause, pfGetStatus,
- pfAbort, pfRecordMarker, pfRefresh, pfGetTime,
- pfDigest, pfClipScan)
- {
- pfGetExtendedInfo, pfPlay, pfPause, pfGetStatus, pfAbort,
- pfRecordMarker, pfRefresh, pfGetTime, pfDigest, pfClipScan
- }
- #define DECLARE_CLIP_CONST_ATTR(clipTypeName, vtable, eType, audioSID, videoSID,
- eBitstreamType, uAttributes, pPresentationTime)
- static CONST ClipConstAttr CLIP_CONST_ATTR(clipTypeName)= {
- vtable,
- (enClipType)eType,
- (UINT8)audioSID, (UINT8)videoSID, (UINT8)eBitstreamType,
- (UINT8)uAttributes,
- pPresentationTime
- };
- /////////////////////////////////////////////////////////////////////////////
- // Common Structures
- typedef struct ClipConstAttr_TAG {
- // Virtual Table
- struct {
- BOOL (*m_pfGetExtendedInfo)(const struct Clip_TAG *i_pThis, WORD o_pExtInfoContainer);
- BOOL (*m_pfPlay)(struct Clip_TAG *i_pThis, const ClipMarker *i_pResumeMarker, BOOL bCacheOnly);
- void (*m_pfPause)(struct Clip_TAG *i_pThis, BOOL bEnable);
- enClipStatus (*m_pfGetStatus)(const struct Clip_TAG *i_pThis);
- void (*m_pfAbort)(struct Clip_TAG *i_pThis, BOOL bMaintainStandby);
- void (*m_pfRecordMarker)(const struct Clip_TAG *i_pThis, ClipMarker *o_pMarker);
- void (*m_pfRefresh)(struct Clip_TAG *i_pThis);
- UINT16 (*m_pfGetTime)(const struct Clip_TAG *i_pThis);
- void (*m_pfDigest)(struct Clip_TAG *i_pThis);
- void (*m_pfClipScan)(struct Clip_TAG *i_pThis, INT16 iSpeed);
- } m_vtable;
- // Constant Data members
- enClipType m_eType;
- UINT8 m_eAudioSID;
- UINT8 m_eVideoSID;
- UINT8 m_eBitstreamType;
- UINT8 m_eAttributes;
- UINT8 *m_pPresentationTime;
- } ClipConstAttr;
- typedef struct ClipFileInfo_TAG {
- // Path information
- WCHAR szDirectoryName[1+CLIPS_MAX_DIRNAME_LEN];
- // File-Name, Location, and Size (Bytes)
- WCHAR szFilename[1+CLIPS_MAX_FILENAME_LEN];
- DWORD dwFileLocation;
- ULONG cbFileSize;
- // Robin_0715_2004, merge changelist #24166
- #ifdef USE_AUX_SUBTITLES
- // <<< Robin_0903_2004
- #ifdef DIVX_SUPPORT_MULTI_SUBTITLE
- WORD wSubFileIndex;
- WORD wSubFileCnt;
- #else
- DWORD dwSubtitlesFileAddress;
- // Robin_1003_2004_E
- DWORD dwSubtitlesFileSize;
- #endif
- // >>> Robin_0903_2004
- #endif
- } ClipFileInfo;
- typedef struct Clip_TAG {
- // Implementation
- const ClipConstAttr *m_pConstAttr;
- // Non-Constant Data Members
- ClipFileInfo m_cfiInfo;
- struct {
- unsigned int eImageOrientation :2;
- unsigned int eTransitionEffect :3;
- unsigned int ucUserData :8;
- unsigned int reserved :2;
- unsigned int bModified :1;
- } m_presentationInfo;
- } Clip;
- #endif //__CLIP_IMPL_H_