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

📄 mv_dec03.c

📁 tuner扫描
💻 C
字号:
/*==========================================================================*/
/*     (Copyright (C) 2003 Koninklijke Philips Electronics N.V.             */
/*     All rights reserved.                                                 */
/*     This source code and any compilation or derivative thereof is the    */
/*     proprietary information of Koninklijke Philips Electronics N.V.      */
/*     and is confidential in nature.                                       */
/*     Under no circumstances is this software to be exposed to or placed   */
/*     under an Open Source License of any type without the expressed       */
/*     written permission of Koninklijke Philips Electronics N.V.           */
/*==========================================================================*/
/*==========================================================================*/
/*                                                                          
       SOURCE_FILE:    MV_DEC03.C

       PACKAGE:        DEC
       
       COMPONENT:      IPVD      
                                                                            
       (C) 1998: Philips Semiconductors                                
                                                                            */ 
/*==========================================================================*/
/*MPP:::DEC======================================================*/

/* PACKAGE NAME:       DEC

   SCOPE:              PLATEFORM
      
   ORIGINAL AUTHOR:    B.LEMESLE

   DESCRIPTION :  
   Basic functionalities of the video decoding package to retrieve decoding
   state, sequence and picture informations

   DATA TYPES:

   FUNCTIONS:
   MV_DEC_get_decoding_state
   MV_DEC_get_picture_info
   MV_DEC_get_seq_info
                                                                            */
/*EMP=======================================================================*/

/*==========================================================================*/
/*       I N C L U D E S                                                    */ 
/*==========================================================================*/
#include "standard.h"
#include "mv_decl.h"
#include "mv_decp.h"
#include "mv_drv.h"

/*==========================================================================*/
/*       G L O B A L   D A T A   D E C L A R A T I O N S                    */
/*==========================================================================*/
extern MV_DEC_STATUS GV_MV_DEC_status;

/*==========================================================================*/
/*       L O C A L   S Y M B O L   D E F I N I T I O N S                    */
/*==========================================================================*/

/*==========================================================================*/
/*       L O C A L   D A T A   D E C L A R A T I O N S                      */
/*==========================================================================*/

/*==========================================================================*/
/*       L O C A L   F U N C T I O N S   P R O T O T Y P E S                */
/*==========================================================================*/

/*==========================================================================*/
/*       G L O B A L  F U N C T I O N S                                     */ 
/*==========================================================================*/

/*MPF=======================================================================*/
/*  
    FUNCTION NAME:     MV_DEC_get_seq_info

    PACKAGE:           DEC

    SCOPE:             PLATFORM

    DESCRIPTION:  
    Get informations about the sequence currently found in the video fifo,
    and which will be decoded.
    
    The sequence informations retrieved are :
    - Sequence width in pixels
    - Sequence height in pixels
    - Sequence aspect ratio
    - Sequence frame rate

    Drivers notify MV_DEC_NEW_SEQ_FOUND_EVENT to application when
    sequence informations are available.
    
    NOTES:
    MV_DEC_get_seq_info() can be call in an ISR.

    PRECONDITIONS:
    Before calling this routine, application must enable notification of
    MV_DEC_NEW_SEQ_FOUND_EVENT via
    MV_DEC_enable_notification(MV_DEC_NEW_SEQ_FOUND_EVENT) routine.

    POSTCONDITIONS:
    None
    
    CALLING SEQUENCE:
*/
void
MV_DEC_get_seq_info(    
   MV_DEC_SEQ_INFO   *ou_seq_info_ptr       /* Out: structure with seq info */
   )
/*EMP=======================================================================*/
{
   ou_seq_info_ptr->seq_width = GV_MV_DEC_status.dec_seq_info.seq_width;
   ou_seq_info_ptr->seq_height= GV_MV_DEC_status.dec_seq_info.seq_height;   
   ou_seq_info_ptr->aspect_ratio = GV_MV_DEC_status.dec_seq_info.aspect_ratio;   
   ou_seq_info_ptr->frame_rate = GV_MV_DEC_status.dec_seq_info.frame_rate;   

} /* End of MV_DEC_get_seq_info */


/*MPF=======================================================================*/
/*  
    FUNCTION NAME:     MV_DEC_get_picture_info

    PACKAGE:           DEC

    SCOPE:             PLATFORM

    DESCRIPTION:
    Get informations about the picture currently found in the video fifo, and
    which will be decoded or not (depends of the picture).
    
    The picture informations retrieved are :
    - Sequence width in pixels
    - Sequence height in pixels
    - Window width in pixels
    - Window height in pixels
    - Centre hor offset in 1/16 of pixels
    - Centre ver offset in 1/16 of pixels
    - Temporal reference
    - Coding_type on 8 bits
    - Luma odd start addr (offset % beginning of SDRAM)
    - Luma even start addr (offset % beginning of SDRAM)
    - Chroma odd start addr (offset % beginning of SDRAM)
    - Chroma even start addr (offset % beginning of SDRAM)
    - Line memory storing alignement
    - DTS of the picture (the real one, otherwise the HW emulated one) on 24 bits
    - PTS of the picture (the real one, if it's present in the stream)

    Drivers notify MV_DEC_EOPH_EVENT to application when picture informations
    are available.

    NOTES:
    MV_DEC_get_picture_info() can be call in an ISR.
    
    PRECONDITIONS:
    Before calling this routine, application must enable notification of
    MV_DEC_EOPH_EVENT via MV_DEC_enable_notification(MV_DEC_EOPH_EVENT) routine.
    

    POSTCONDITIONS:
    None
    
    CALLING SEQUENCE:
*/
void  
MV_DEC_get_picture_info(
   MV_DEC_PICT_INFO   *ou_pict_info_ptr    /* Out: structure with pict info */
   )
/*EMP=======================================================================*/
{
   ou_pict_info_ptr->coded_win_width = GV_MV_DEC_status.dec_pict_info.coded_win_width;
   ou_pict_info_ptr->coded_win_height = GV_MV_DEC_status.dec_pict_info.coded_win_height;
   ou_pict_info_ptr->disp_win_width = GV_MV_DEC_status.dec_pict_info.disp_win_width;
   ou_pict_info_ptr->disp_win_height = GV_MV_DEC_status.dec_pict_info.disp_win_height;
   ou_pict_info_ptr->centre_off_hor = GV_MV_DEC_status.dec_pict_info.centre_off_hor;
   ou_pict_info_ptr->centre_off_ver = GV_MV_DEC_status.dec_pict_info.centre_off_ver;
   ou_pict_info_ptr->temp_ref = GV_MV_DEC_status.dec_pict_info.temp_ref;
   ou_pict_info_ptr->pict_coding_type = GV_MV_DEC_status.dec_pict_info.pict_coding_type;
   ou_pict_info_ptr->pict_y_odd_buf_addr = GV_MV_DEC_status.dec_pict_info.pict_y_odd_buf_addr;
   ou_pict_info_ptr->pict_y_even_buf_addr = GV_MV_DEC_status.dec_pict_info.pict_y_even_buf_addr;
   ou_pict_info_ptr->pict_c_odd_buf_addr = GV_MV_DEC_status.dec_pict_info.pict_c_odd_buf_addr;
   ou_pict_info_ptr->pict_c_even_buf_addr = GV_MV_DEC_status.dec_pict_info.pict_c_even_buf_addr;
   ou_pict_info_ptr->pitch = GV_MV_DEC_status.dec_pict_info.pitch;
   ou_pict_info_ptr->pict_dts = GV_MV_DEC_status.dec_pict_info.pict_dts;
   ou_pict_info_ptr->pict_pts = GV_MV_DEC_status.dec_pict_info.pict_pts;
   
} /* End of MV_DEC_get_picture_info */

/*MPF=======================================================================*/
/*  
    FUNCTION NAME:     MV_DEC_get_decoding_state

    PACKAGE:           DEC

    SCOPE:             PLATFORM

    DESCRIPTION:
    Retrieve the state of the video decoder

    NOTES:
    MV_DEC_get_picture_info() can be call in an ISR.

    PRECONDITIONS:
    None    

    POSTCONDITIONS:
    None

    CALLING SEQUENCE:
*/
void
MV_DEC_get_decoding_state(    
   MV_DEC_DECODING_STATE *ou_state_ptr        /* Out: decoder state */
   )
/*EMP=======================================================================*/
{
   *ou_state_ptr = GV_MV_DEC_status.dec_state;
   
} /* End of MV_DEC_get_decoding_state */
/*==========================================================================*/
/*       L O C A L  F U N C T I O N S                                       */ 
/*==========================================================================*/














⌨️ 快捷键说明

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