av.h
上传用户:fy98168
上传日期:2015-06-26
资源大小:13771k
文件大小:2k
- #ifndef __AV_H__
- #define __AV_H__
- #if defined(__cplusplus)
- extern "C" {
- #endif
- #include "gendef.h"
- #include "stvid.h"
- #include "db.h"
- #define KB_AV_MAX_VOLUME 32
- #define KB_AV_DEFAULT_VOLUME 20
- #define KB_AV_DEFAULT_DISP_MODE KB_AV_VIDEO_DISPLAY_PAL
- #define KB_AV_DEFAULT_ASPECT_RATIO KB_AV_ASPECT_RATIO_4TO3
- #define KB_AV_DEFAULT_TRACK LEFT_TRACK
- #define KB_AV_DEFAULT_ADULT_RANK RANK_10
- typedef enum
- {
- KB_AV_ASPECT_RATIO_4TO3,
- KB_AV_ASPECT_RATIO_16TO9
- }KB_AVAspectRatio;
- typedef enum
- {
- KB_AV_VIDEO_DISPLAY_PAL,
- KB_AV_VIDEO_DISPLAY_NTSC,
- KB_AV_VIDEO_DISPLAY_SECAM,
- KB_AV_VIDEO_DISPLAY_MAX_TYPE
- }KB_AVVideoDisplayMode;
- typedef struct
- {
- UINT32 nVideoPid;
- UINT32 nAudioPid;
- UINT32 nPcrPid;
- } KB_AVPID;
- typedef void (*KB_AVEndCallback)(void);
- typedef void (*KB_AVPlayStartCallback)(INT32 nSuccess,INT32 nHours,INT32 nMinutes,INT32 nSeconds);
- /*****************************************************************************
- ** Function prototypes
- *****************************************************************************/
- INT32 KB_AVInit(void);
- INT32 KB_AVPlay(UINT32 nVideoPid, UINT32 nAudioPid, UINT32 nPcrPid);
- INT32 KB_AVStop(void);
- INT32 KB_AVPause(void);
- INT32 KB_AVSetWindow(INT32 nLeft, INT32 nTop, INT32 nRight, INT32 nBottom);
- INT32 KB_AVGetWindow(INT32 *pLeft, INT32 *pTop, INT32 *pRight, INT32 *pBottom);
- INT32 KB_AVChangeWindow(BOOL bFull);
- BOOL KB_AVGetWindowFlag(void);
- INT32 KB_AVSetMute(BOOL bisMute);
- INT32 KB_AVSetPrgTrack(KB_DBTRACK nTrack);
- KB_DBTRACK KB_AVGetTrack(void);
- KB_AVPlayStartCallback KB_AVHandlePlayState(KB_AVPlayStartCallback ptCallback);
- INT32 KB_AVSetVolume(INT32 nVolume);
- INT32 KB_AVGetVolume(void);
- INT32 KB_AVGetMuteFlag(void);
- INT32 KB_AVPlayIFrame(UINT8 *pInData, INT32 nDataSize);
- INT32 KB_AVStopIFrame(void);
- BOOL KB_AVGetIFrameFlag(void);
- #if 0
- int KB_AVSetTVAspectRatioAndMatchMode(KB_AVAspectRatio nAspectRatio,STVID_DisplayAspectRatioConversion_t nMatchMode);
- #else
- int KB_AVSetAspectRatio(KB_AVAspectRatio nAspectRatio);
- #endif
- int KB_AVSetMode(KB_AVVideoDisplayMode nMode);
- #if defined(__cplusplus)
- }
- #endif
- #endif