⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 mrgtmp0

📁 ct952 source code use for Digital Frame Photo
💻
📖 第 1 页 / 共 3 页
字号:
// Micky1.05 begin// Each VOBU presentation time is about 0.5s.// [TIME control value]// LVP08.01( title 11), >= 80000, or will be underflow//                  The reason: if don't do time control, the time gap is about 2s. After multi-audio switching, it needs wait up 2s then go.// Matrix(root menu),   10000~80000 is OK(highlight will display)//                  The reason, every 2 NV will have highlight information, and the highlight start time will change// The Spirit Of The Rain Forest , >= 15000// TDL002(Title 6),   >= 40000, or audio willbe underflow (for MPEG audio)#define EARLIER_TIME    80000L//#define DEBUG_VOBU_TIME// Micky1.05 end//Micky0.65-909, modify HAL_CopyDRAM length into bytes unit.// Micky0.87. for multi-angle title begin// 1. Use smaller SkipGap and do reset before 2nd skip.// 2. Add a _SearchFWDI function, as code overflow// 3. CELL_Recover, for multi-angle, will base on last NV sector and skip 1s.// define it, will use the PCI_NV_PCK_LBN info(updated by parser code)// else will reference the info DSI_GI_NV_PCK_LBN(due to RISC will update PCI_NV_PCK_LBN)// seems has problem when error concealment???//#define REFERENCE_SECTOR_ID// Micky0.87. for multi-angle title end//////////////////////////////////////////////////////////////// ***** Big Modification History Area *****// LLY0.95, remove "REPEATAB_BY_CELL" related code.// LLY2.17, don't include "winav.h" & "ctkav.h" since CELL module is protected module.// LLY2.17, use __dwNVStart to keep NV start address, ie don't reference DS_NV_BUF_ADDR_ST directly//          since the value maybe different base on DRAM configuration.//          So, replace DS_NV_BUF_ADDR_ST w/ __dwNVStart//#include    "winav.h"#include    "setup.h"#include    "cc.h"#include    "cell.h"#include    "nvcmd.h"#include    "Srcfilter.h"#include    "utl.h"#include    "hal.h"#include    "osd.h"#include    "input.h"#include    "comutl.h"#include    "navigate.h"// DVD_173Micky, include dvdinfo.h for __wSPRMs declare.#include    "dvdinfo.h"// DVD_273.2Micky, add special function to execute non-NOP command#include    "infofilter.h"#include    "chips.h"// Micky2.35extern void Service_420(void);// If define it, the cell range will be played by linear.// The range is start from 1st VOBU to last VOBU within the cell./// else, cell will be played VOBU by VOBU./// !!!this is for performance test only.!!! Default shoud be disabled.//#define FORCE_LINEAR// DVD_160Micky, fix "500 & China Blue"(summer night wind), can use number select(from 1.61)// support number selection for invalid encode button info.(BaseOffset=17, SELBTN_Ns=0)// define it, when no Selectable button, will force let all buttons can use number select.// else, will fow the spec.// will have problem when menu display number is not start from 1#define SUPPORT_LOOSE_BUTTON_CONTROL// DVD_170Micky, as navigate.c will update __bANL_Ns// cell don't need serach angles number.// can't be disabled if no problem occur.//#define _DEBUG_ANGLES_NUMBER//#define _DEBUG_BUTTON_STATE//#define _DEBUG_CELL_RANGE//#define _DEBUG_VOBU//#define _DEBUG_STC// LLY1.50, rename DUMP_INFORMATION w/ DUMP_CELL_INFO within cell module for debug cell information only// And, it will be enabled automation if #define DUMP_INFORMATION//#define DUMP_CELL_INFO#ifdef  DUMP_INFORMATION#undef DUMP_CELL_INFO#define DUMP_CELL_INFO#endif  // #ifdef DUMP_INFORMATION// define it, can do debug for DSI reduce// open _DEBUG_DIS only when needed.///#define _DEBUG_DSI//DVD_051Micky// If mark CHECK_VOBU_E_PTM will not do VOBU_E_PTM check, problems://  (1) TDL-002 TT/CC 06/01 will have AC3->MPEG data skip problem//  (2) The "Spirit of Rainforest" slides show will display too fast// also check title LVP08.01 test disc 11. slide show audio smooth// Micky0.68, enable check end time temporarily#define CHECK_VOBU_E_PTM// define it, CELL 1st NV fail, will do linear search.//            2nd NV fail, will do VOBU skip.(By gap 10/30/60/120 seconds)//            Finally will switch to linear play mode.//            Once NV_INT is checked, switch back to CELL_NORMAL mode// if not defined, will just hang at NV sector.#ifdef  ERROR_CONCEAL#define ENHANCE_CELL_ERROR_CONCEAL#endif//#define _CELL_INFO#define MIN_VOBU    1          // 16 is valid//Aron1.08-909, define the size of ring buffer to keep//past NV's start/end presentation time and UOP field#define PAST_NV_RING_BUFF_SIZE 10BYTE    __bVOBUStill;    // flag indicate the VOBU still is on/offBYTE    __bSTCRunning;//Micky2.80, review global variables init.=FALSE;// Aron2.30, used to keep VOBU presentation time start.DWORD   __dwVOBU_S_PTM;// record the end presentation time of current VOBU.(By 90KHz/sec format)DWORD   __dwVOBU_E_PTM;// modify the time display information//DWORD   __dw1stSCR;// LLY2.17, use a variable to keep NV buffer start address// Since, the address maybe different base on different DRAM configuration.// So, replace DS_NV_BUF_ADDR_ST w/ __dwNVStartDWORD   __dwNVStart;#ifndef NO_DVD// DVD_274Micky, add copyright. Don't remove it!!!!BYTE    Copyright_CHEERTEK_INC_2002_CELL;// DVD_160Micky// reference VI3-66, once transferred to Action state, any transfer shall not allowed// DVD_275Micky, share the same variable.#define _bButtonState Copyright_CHEERTEK_INC_2002_CELL///BYTE    _bButtonState;// Micky2.80, review global variables init.//DWORD   *pdwBuffer=NULL;// Micky1.05 begin// LLY1.05, remove this varible for code reduce since it can use constant value now.//DWORD   __dwEARLIER_TIME = EARLIER_TIME;BYTE    _Decide_VOBU_Control(void);// Micky1.05 end// should be assigned by CELL_InitialDWORD   __dwCellFVOBUSA;    // physical start address of 1st VOBU in this cellDWORD   __dwCellFILVUEA;DWORD   __dwCellLVOBUSA;DWORD   __dwCellLVOBUEA;    // physical end address of last VOBU in this cellBYTE     __bSeamlessAngleChange;BYTE     __bInterleaved;// when debug reduce DSI, will read all DSI for comparison#if !defined(REDUCE_DSI) || (defined(REDUCE_DSI) && defined(_DEBUG_DSI))DSI   *pDSI;  // store DSI info.#define cDSI    (*pDSI)#endif// LLY2.32, porting Micky's code for using time map table// Micky07312006 begin, for TMAPBYTE	_bUpdateSCR;// Micky07312006 end ...// for Scan back recursive protection// Keep previous scan position, it will be updated by __dwVOBUSA during scan mode// And, will be clear to 0xffffffff while VOBU_START & CELL_Initial()DWORD   _dwPreScanPosition;//Micky2.80, review global variables init.=0xffffffff;// this will be multi-angle change referenceDWORD    __dwCurrentVOBUSA; // current VOBU Start addressDWORD   __dwVOBUSA;       // it records the offset to the FVOBUDWORD   __dwVOBUEA;       // it records the end offset of this VOBUDWORD   __dwVOBUStart;      // it records the logical sector for VOBU startDWORD   __dwVOBUEnd;        // it records the logical sector for VOBU endDWORD   __dwILVUEnd;      // it records the logical sector for ILVU endDWORD   __dwILVUEA;       // it records the end offset of this ILVUDWORD   __dwNextILVUSA;     // it records the start address of next ILVU//Aron1.15-909, it is not uesd by others, comment it!//WORD    __wNextILVUSZ;    // it records the next ILVU sectorsBYTE    __bAngleChange;         // TRUE, indicate need do seamless angle change// Micky2.31, remove __bAngle initial valueBYTE    __bAngle;//=1;             // Angle number, only referenced when angle is changedBYTE    __bCellAction;   // status of current CELL actionDWORD   __dwVOBUSRI;// [ Button information ]BYTE    __bBTNBaseOffset;       // BTN offsetBYTE    __bBTNEndOffset;        // BTN offsetBYTE    __bSELBTN_Ns;           // number of selectable buttonsBYTE    __bBTN_Ns;              // number of total buttonsBYTE    __bDefaultHL_BTNN;      // default selection button numberBYTE    __bForceActiveBTNN;     // forced active button number// LLY1.15, remove HLI start/end time variable, since it can reference PCI info directly//DWORD   __dwHLStartTime;        // button highlight start time//DWORD   __dwHLEndTime;          // buttom highlight end timeDWORD   __dwBTNSelEndTime;      // end of buttion selection time// the __bNowBTNNumber is valid from 1~36BYTE    __bNowBTNNumber;      // current selection BTNN//Aron1.08-909, For DVD Forum NF250, the UOPs test will not pass since the NV//issue. TT/CC: 07/14 press KEY_PAUSE can be permitted during time 2:18:xx ~ 2:19:xx//==> Pause key should be prohibited during time 2:10 ~ 2:20.//Therefore, I add one ring buffer to keep past NV's//start/end presentation time and UOP field to get right UOP when do CELL_QueryUOPPAST_NV_UOP _past_NV_UOPs[PAST_NV_RING_BUFF_SIZE];WORD _wNV_UOPs_WP = 0; // write pointer of _past_NV_UOPs ring buffer// System parametersextern  DWORD       _dwFirst_VOBS;// DVD_173Micky, remove __wSPRMs declare.///extern  WORD        __wSPRMs [24];// temporary buffer for DSI/PCI data access// max. size used now 120(30*4)// DVD_172r2, use __cBuffer[160].///char    _cTempBuffer[200];// when debug reduce DSI, will read all DSI#if !defined(REDUCE_DSI) || (defined(REDUCE_DSI) && defined(_DEBUG_DSI))char    _cDSIBuffer[110*4];#endifPCI_BTNIT   *_pBTNInfo;// ** TCH0.451; 0-PS, 1-LB, 2-16:9, 3-4:3.extern BYTE    __bSPST_Display_Mode;extern BYTE    __bSPST_LB;extern  DWORD   __dwTimeA, __dwTimeB;// The variable is used to keep NV related information.// bit [7:6], for same NV sector send count.// the count will be cleared when 1) NV_INT got. 2) 2nd NV_INT fail after re-sending.// bit [4], will be linear search NV sector// bit [3:0], the NV sector stateBYTE    _bCheckNVData;// the _bIndex is to be used as a temporarily variable within function// and the function won't call other cell APIs(public or protected)static  BYTE    _bIndex;static BYTE    _bEnableTimeSearch;static DWORD   _dwSearchTime;// record the start time that sending NV sector.DWORD   _dwTimeNV;// LLY1.05, recode the time while issue SCAN CMD (remove from CC module)DWORD   __dwTimeRef;// [CELL Recover]BYTE    _bNVRecover;    // 0, not doing NV skip                        // 1~ MAX_SKIP_GAP1, doing NV skip.                        // MAX_SKIP_GAP1+1, linear play mode.extern BYTE        __bStillTime;   // record the Still Time (0: NONE, 0xFF: Infinite; Other: seconds.)extern DWORD       __dwTimeStill;  // record Still starting SYSTEM Counterextern C_PBI       __pbi_CELL;//Scan forward      //Scan Backward// 1sec=FWDI2=19     1sec=BWDI2=24// 2sec=FWDI4=17     2sec=BWDI4=26// 4sec=FWDI8=13     4sec=BWDI8=30// 8sec=FWDI15=6     8sec=BWDI15=37//10sec=FWDI20=5    10sec=BWDI20=38//30sec=FWDI60=4    30sec=BWDI60=39//60sec=FWDI120=3   60sec=BWDI120=40//120sec=FWDI240=2  120sec=BWDI240=41//!!! can't use FWDI1 as it's possible the current VOBU(0.4~1)BYTE code bFWDI[8]={19, 17, 13, 6, 5, 4, 3, 2};BYTE code bBWDI[8]={24, 26, 30, 37, 39, 39, 40, 41};

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -