dvda_asv.h
上传用户:super_houu
上传日期:2008-09-21
资源大小:4099k
文件大小:7k
- /****************************************************************************************
- * Copyright (c) 2000 ZORAN Corporation, All Rights Reserved
- * THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF ZORAN CORPORATION
- *
- * File: "dvda_asv.h" 20/12/00
- *
- * Description:
- * ============
- * ASV manager functions and data structures
- *
- * Log:
- * ====
- * $Revision: 2 $
- * Last Modified by $Author: Leonh $ at $Modtime: 1/07/04 12:08p $
- ****************************************************************************************
- * Updates:
- ****************************************************************************************
- * $Log: /I76/I76_Common/I76_Reference/Playcore/Nav_DVD/Header/dvda_asv.h $
- *
- * 2 1/07/04 12:17p Leonh
- * Angieh:Merge the code from CES_DB.
- *
- * 16 12/30/03 10:42a Leonh
- * Angieh:Add #include "Config.h".
- *
- * 15 12/29/03 3:27p Leonh
- * Angieh:Use another way check the subpicture size instead of change the
- * HLI pack length.
- *
- * 14 12/23/03 5:53p Leonh
- * Angieh:Add 1 byte to avoid the highlight data lack of one byte.
- *
- * 13 12/21/03 4:46p Leonh
- * Angieh:Support for the Bookmark Play.
- *
- * 12 11/12/03 12:45p Leonh
- * add function for subpicture size
- *
- * 11 11/06/03 8:34a Leslie
- * clean up the code
- *
- * 10 11/03/03 2:53p Leslie
- * add the define for save logo
- *
- * 9 10/20/03 11:46a Leslie
- * check the variable type and change the dvda rtpb schedule way as the
- * same with DVD Video
- *
- * 8 10/16/03 10:50a Leslie
- * change the way to get the nav pointer after cache
- *
- * 7 10/15/03 8:52a Leslie
- * stream subpicture when asv display
- *
- * 6 10/14/03 11:46a Leslie
- * add dvd audio support
- *
- * 5 10/14/03 11:19a Leslie
- * add dvd audio support
- *
- * 4 8/20/03 8:23p Leonh
- * finish some API for ASV
- *
- * 3 03-05-12 10:01 Leonh
- *
- * 2 03-05-12 9:34 Leonh
- *
- * 1 03-05-08 18:16 Leonh
- *
- * 1 10/24/02 14:21 Rinata
- *
- * 14 2/12/02 7:44p Bhupeshv
- * Merged VaddisPlayerV fixes.
- *
- * 12 10/10/01 16:45 Nirp
- * assafm:
- * Fixed Prev / Next DLIST bug.
- * Fixed bug in ASV change during same ASVU range.
- * + Bhupesh integration 1008 + Tia 1009
- *
- * 11 10/03/01 18:11 Rinata
- * Finik+ Bhupesh + Assaf + Tia : Navigation fixes
- *
- * 10 9/30/01 12:08 Rinata
- * Bhupesh,Finik, Assaf and Tia navigator bugs fixes
- *
- * 9 8/21/01 5:22 Nirp
- *
- * 8 8/05/01 17:15 Rinata
- * Integration (cy)
- *
- * 8 7/31/01 11:37 Assafm
- * Bug fixes
- *
- * 7 7/05/01 9:55 Yarone
- * remove cast warning
- *
- * 6 6/14/01 14:16 Rinata
- * Assaf
- *
- * 5 17-04-01 14:38 Assafm
- *
- * 4 17-04-01 11:36 Assafm
- *
- * 3 27-03-01 14:55 Assafm
- *
- * 2 21-03-01 15:25 Assafm
- *
- * 1 22-01-01 11:16 Assafm
- *
- * 2 20/12/00 11:44 Finik
- * 1 10-12-00 15:21 Assafm
- *
- * 1 28-11-00 17:59 Assafm
- Revision 1.1 2000/04/27 17:17:39 tia
- Initial revision
- */
- /**************************************************************************************/
- #include "Config.h" // Global Configuration - do not remove!
- #ifdef DVD_AUDIO_SUPPORT
- #ifndef _DVDA_ASV_H
- #define _DVDA_ASV_H
- #include "playcorecoremaincoremain.h"
- #include "PlaycoreNav_DVDHeadernavdef.h"
- #include "DecoderDec_defs.h"
- #define ASVOBS_SP_PLT_NUM 16
- #define ASVU_ATR_NUM 4
- #define MAX_ASV_SRPS 100 /* maximum search pointers for cached ASVs */
- #ifdef NO_SCPAD
- #define asv_Get_ASV_HLI_SS(ptr) asv_Get_ASV_HLI_word(ptr,0)
- #define asv_Get_ASV_HLI_S_PTM(ptr) asv_Get_ASV_HLI_dword(ptr,2)
- #define asv_Get_ASV_HLI_E_PTM(ptr) asv_Get_ASV_HLI_dword(ptr,6)
- #define asv_Get_ASV_BTN_SL_E_PTM(ptr) asv_Get_ASV_HLI_dword(ptr,10)
- #define asv_Get_ASV_BTN_MD(ptr) asv_Get_ASV_HLI_word(ptr,14)
- #define asv_Get_ASV_BTN_OFN(ptr) asv_Get_ASV_HLI_byte(ptr,16)
- #define asv_Get_ASV_BTN_Ns(ptr) asv_Get_ASV_HLI_byte(ptr,17)
- #define asv_Get_ASV_NSL_BTN_Ns(ptr) asv_Get_ASV_HLI_byte(ptr,18)
- #else
- #define asv_Get_ASV_HLI_SS(asvn) asv_Get_ASV_HLI_word(asvn, 0)
- #define asv_Get_ASV_HLI_S_PTM(asvn) asv_Get_ASV_HLI_dword(asvn, 2)
- #define asv_Get_ASV_HLI_E_PTM(asvn) asv_Get_ASV_HLI_dword(asvn, 6)
- #define asv_Get_ASV_BTN_SL_E_PTM(asvn) asv_Get_ASV_HLI_dword(asvn, 10)
- #define asv_Get_ASV_BTN_MD(asvn) asv_Get_ASV_HLI_word(asvn, 14)
- #define asv_Get_ASV_BTN_OFN(asvn) asv_Get_ASV_HLI_byte(asvn, 16)
- #define asv_Get_ASV_BTN_Ns(asvn) asv_Get_ASV_HLI_byte(asvn, 17)
- #define asv_Get_ASV_NSL_BTN_Ns(asvn) asv_Get_ASV_HLI_byte(asvn, 18)
- #endif
- #define PREV_DLIST -1
- #define NEXT_DLIST -2
- #define HOME_DLIST -3
- #define ASV_HLI_PACK_LENGHT ( 6 + 1 + 694 + 50)
- #define SP_TEMP_BUFFER_NUM 32// bytes
- typedef struct {
- BYTE ASV_Ns; /* number of ASVs */
- BYTE ASVU_ATRN; /* attribute number */
- WORD FirstABS_ASVN;
- DWORD StartAddr; /* start address of ASVU */
- } S_ASVU_GI;
- typedef struct {
- S_ASVU_GI ASVU_GI;
- DWORD ASVOBS_SA; /* Start address of ASVOBS */
- DWORD ASVOBS_EA; /* Start address of ASVOBS */
- #ifdef NO_SCPAD
- DWORD ASVOBS_SP_PLT[ASVOBS_SP_PLT_NUM]; /* sub picture palletes */
- #else
- S_SC_STORAGE asvobs_sp_plt_st;
- #endif
- WORD ASVU_Ns; /* number of ASV units */
- DWORD ASVU_Size;
- #ifdef NO_SCPAD
- WORD ASVU_ATR[ASVU_ATR_NUM]; /* Attributes */
- WORD ASV_SA[MAX_ASV_SRPS];
- #else
- S_SC_STORAGE asvu_atr_sc_st;
- S_SC_STORAGE asv_sa_sc_st;
- #endif
- WORD ASV_PBI_SA; //ZORAN BMV1001
- // short NextASVEventSlot;
- BYTE CurrentASVU;
- BYTE Initialized;
- BYTE NumASVs;
- BYTE MaxDList;
- #ifdef NO_SCPAD
- BYTE *ASV_HLI_Ptr;
- #else
- S_SC_STORAGE asv_hli_info_sc_st;
- #endif
- BYTE CurrentASV_DMD;
- #ifdef NO_SCPAD
- BYTE *DLISTShuffleVector;
- #else
- S_SC_STORAGE dlist_shuffle_vector_sc_st;
- #endif
- BYTE DLISTShuffleVectorSize;
- BYTE DLISTShuffleVectorIdx;
- BYTE DLISTShuffleVectorIdxDirection;
- BYTE SelectedButtonGroup;
- BYTE SelectedButtonNumOfGroups;
- BYTE ResumeDlist;
- BOOL CHANGE_ASV;
- } S_ASV;
- BOOL asv_construct(void);
- void asv_delete(void);
- BOOL asv_CacheASVU(int asvun);
- BOOL asv_DisplayASV(BYTE asvn);
- WORD asv_GetASVUAttr(int num);
- BOOL asv_UNCacheASVU(void);
- #ifdef NO_SCPAD
- BOOL asv_ShuffleDList(S_STORAGE *st,int start_offset,int dlist_size,int num_asv);
- #else
- BOOL asv_ShuffleDList(S_SC_STORAGE*st,int start_offset,int dlist_size,int num_asv);
- #endif
- BOOL asv_ShuffleBrowsableDList(int size);
- DWORD asv_Get_HLI_Sa(BYTE asvn);
- DWORD asv_Get_StillPicture_Sa(BYTE asvn);
- // the next routines fetch data (which might be unaligned so a pointer reference
- // may not work) from the ASV_HLI struct
- BYTE asv_Get_ASV_HLI_byte(BYTE asvn,UINT16 offset);
- WORD asv_Get_ASV_HLI_word(BYTE asvn,UINT16 offset);
- DWORD asv_Get_ASV_HLI_dword(BYTE asvn,UINT16 offset);
- BOOL asv_ScheduleASV(int dlist_num,int nav_cmd);
- void asv_ASVIsDisplayed(void);
- /* HLI packets handling */
- BOOL asv_hli_Button_Select(int button,int valid_auto_activate);
- BOOL asv_hli_Adjacent_Button_Select ( long UOP );
- BOOL asv_Button_Activate( int button, unsigned char *cmdraw);
- DWORD asv_CurrSubPicSize(BYTE asvn);
- void asv_Display_SubPicture(DWORD sp_size);
- void asv_StoreAsvPointer(void);
- #endif //DVD_AUDIO_SUPPORT
- #endif /* _DVDA_ASV_H */