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

📄 armvc.h

📁 The OpenMAX DL (Development Layer) APIs contain a comprehensive set of audio, video, signal processi
💻 H
📖 第 1 页 / 共 3 页
字号:
 * * Description: * Checks the type of Escape Mode and put encoded bits for  * quantized DCT coefficients. * * Remarks: * * Parameters: * [in]	 ppBitStream      pointer to the pointer to the current byte in *						  the bit stream * [in]	 pBitOffset       pointer to the bit position in the byte pointed *                        by *ppBitStream. Valid within 0 to 7 * [in] shortVideoHeader binary flag indicating presence of short_video_header; escape modes 0-3 are used if shortVideoHeader==0, *                           and escape mode 4 is used when shortVideoHeader==1. * [in]  start            start indicates whether the encoding begins with  *                        0th element or 1st. * [in]  maxStoreRunL0    Max store possible (considering last and inter/intra) *                        for last = 0 * [in]  maxStoreRunL1    Max store possible (considering last and inter/intra) *                        for last = 1 * [in]  maxRunForMultipleEntriesL0  *                        The run value after which level  *                        will be equal to 1:  *                        (considering last and inter/intra status) for last = 0 * [in]  maxRunForMultipleEntriesL1  *                        The run value after which level  *                        will be equal to 1:  *                        (considering last and inter/intra status) for last = 1 * [in]  pRunIndexTableL0 Run Index table defined in  *                        armVCM4P2_Huff_Tables_VLC.c for last == 0 * [in]  pVlcTableL0      VLC table for last == 0 * [in]  pRunIndexTableL1 Run Index table defined in  *                        armVCM4P2_Huff_Tables_VLC.c for last == 1 * [in]  pVlcTableL1      VLC table for last == 1 * [in]  pLMAXTableL0     Level MAX table defined in  *                        armVCM4P2_Huff_Tables_VLC.c for last == 0 * [in]  pLMAXTableL1     Level MAX table defined in  *                        armVCM4P2_Huff_Tables_VLC.c for last == 1 * [in]  pRMAXTableL0     Run MAX table defined in  *                        armVCM4P2_Huff_Tables_VLC.c for last == 0 * [in]  pRMAXTableL1     Run MAX table defined in  *                        armVCM4P2_Huff_Tables_VLC.c for last == 1 * [out] pQDctBlkCoef     pointer to the quantized DCT coefficient * [out] ppBitStream      *ppBitStream is updated after the block is encoded *                        so that it points to the current byte in the bit *                        stream buffer. * [out] pBitOffset       *pBitOffset is updated so that it points to the *                        current bit position in the byte pointed by *                        *ppBitStream. * * Return Value: * Standard OMXResult result. See enumeration for possible result codes. * */OMXResult armVCM4P2_PutVLCBits (              OMX_U8 **ppBitStream,              OMX_INT * pBitOffset,              const OMX_S16 *pQDctBlkCoef,              OMX_INT shortVideoHeader,              OMX_U8 start,              OMX_U8 maxStoreRunL0,              OMX_U8 maxStoreRunL1,              OMX_U8  maxRunForMultipleEntriesL0,              OMX_U8  maxRunForMultipleEntriesL1,              const OMX_U8  * pRunIndexTableL0,              const ARM_VLC32 *pVlcTableL0,			  const OMX_U8  * pRunIndexTableL1,              const ARM_VLC32 *pVlcTableL1,              const OMX_U8  * pLMAXTableL0,              const OMX_U8  * pLMAXTableL1,              const OMX_U8  * pRMAXTableL0,              const OMX_U8  * pRMAXTableL1,              const OMX_U8  * pZigzagTable);/** * Function: armVCM4P2_FillVLCBuffer * * Description: * Performs calculating the VLC bits depending on the escape type and insert  * the same in the bitstream * * Remarks: * * Parameters: * [in]	 ppBitStream		pointer to the pointer to the current byte in *	                        the bit stream * [in]	 pBitOffset         pointer to the bit position in the byte pointed *                          by *ppBitStream. Valid within 0 to 7 * [in]  run                Run value (count of zeros) to be encoded   * [in]  level              Level value (non-zero value) to be encoded * [in]  runPlus            Calculated as runPlus = run - (RMAX + 1)   * [in]  levelPlus          Calculated as  *                          levelPlus = sign(level)*[abs(level) - LMAX] * [in]  fMode              Flag indicating the escape modes * [in]  last               status of the last flag * [in]  maxRunForMultipleEntries  *                          The run value after which level will be equal to 1:  *                          (considering last and inter/intra status) * [in]  pRunIndexTable     Run Index table defined in *                          armVCM4P2_Huff_tables_VLC.h * [in]  pVlcTable          VLC table defined in armVCM4P2_Huff_tables_VLC.h * [out] ppBitStream		*ppBitStream is updated after the block is encoded *                          so that it points to the current byte in the bit *                          stream buffer. * [out] pBitOffset         *pBitOffset is updated so that it points to the *                          current bit position in the byte pointed by *                          *ppBitStream. * * Return Value: * Standard OMXResult result. See enumeration for possible result codes. * */OMXResult armVCM4P2_FillVLCBuffer (              OMX_U8 **ppBitStream,              OMX_INT * pBitOffset,              OMX_U32 run,              OMX_S16 level, 			  OMX_U32 runPlus,              OMX_S16 levelPlus,               OMX_U8  fMode,			  OMX_U8  last,              OMX_U8  maxRunForMultipleEntries,               const OMX_U8  *pRunIndexTable,              const ARM_VLC32 *pVlcTable);/** * Function: armVCM4P2_CheckVLCEscapeMode * * Description: * Performs escape mode decision based on the run, run+, level, level+ and  * last combinations. * * Remarks: * * Parameters: * [in] run             Run value (count of zeros) to be encoded   * [in] level           Level value (non-zero value) to be encoded * [in] runPlus         Calculated as runPlus = run - (RMAX + 1)   * [in] levelPlus       Calculated as  *                      levelPlus = sign(level)*[abs(level) - LMAX] * [in] maxStoreRun     Max store possible (considering last and inter/intra) * [in] maxRunForMultipleEntries  *                      The run value after which level  *                      will be equal to 1:  *                      (considering last and inter/intra status) * [in] shortVideoHeader binary flag indicating presence of short_video_header; escape modes 0-3 are used if shortVideoHeader==0, *                           and escape mode 4 is used when shortVideoHeader==1. * [in] pRunIndexTable  Run Index table defined in  *                      armVCM4P2_Huff_Tables_VLC.c *                      (considering last and inter/intra status) * *                       * Return Value: * Returns an Escape mode which can take values from 0 to 3 * 0 --> no escape mode, 1 --> escape type 1, * 1 --> escape type 2, 3 --> escape type 3, check section 7.4.1.3 * in the MPEG ISO standard. * */OMX_U8 armVCM4P2_CheckVLCEscapeMode(     OMX_U32 run,     OMX_U32 runPlus,     OMX_S16 level,     OMX_S16 levelPlus,     OMX_U8  maxStoreRun,     OMX_U8  maxRunForMultipleEntries,     OMX_INT shortVideoHeader,     const OMX_U8  *pRunIndexTable);/** * Function: armVCM4P2_BlockMatch_Integer * * Description: * Performs a 16x16 block search; estimates motion vector and associated minimum SAD.   * Both the input and output motion vectors are represented using half-pixel units, and  * therefore a shift left or right by 1 bit may be required, respectively, to match the  * input or output MVs with other functions that either generate output MVs or expect  * input MVs represented using integer pixel units.  * * Remarks: * * Parameters: * [in]	pSrcRefBuf		pointer to the reference Y plane; points to the reference MB that  *                    corresponds to the location of the current macroblock in the current  *                    plane. * [in]	refWidth		  width of the reference plane * [in]	pRefRect		  pointer to the valid rectangular in reference plane. Relative to image origin.  *                    It's not limited to the image boundary, but depended on the padding. For example,  *                    if you pad 4 pixels outside the image border, then the value for left border  *                    can be -4 * [in]	pSrcCurrBuf		pointer to the current macroblock extracted from original plane (linear array,  *                    256 entries); must be aligned on an 8-byte boundary. * [in] pCurrPointPos	position of the current macroblock in the current plane * [in] pSrcPreMV		  pointer to predicted motion vector; NULL indicates no predicted MV * [in] pSrcPreSAD		pointer to SAD associated with the predicted MV (referenced by pSrcPreMV) * [in] searchRange		search range for 16X16 integer block,the units of it is full pixel,the search range  *                    is the same in all directions.It is in inclusive of the boundary and specified in  *                    terms of integer pixel units. * [in] pMESpec			  vendor-specific motion estimation specification structure; must have been allocated  *                    and then initialized using omxVCM4P2_MEInit prior to calling the block matching  *                    function. * [in] BlockSize     MacroBlock Size i.e either 16x16 or 8x8. * [out]	pDstMV			pointer to estimated MV * [out]	pDstSAD			pointer to minimum SAD * * Return Value: * OMX_Sts_NoErr – no error. * OMX_Sts_BadArgErr – bad arguments * */OMXResult armVCM4P2_BlockMatch_Integer(     const OMX_U8 *pSrcRefBuf,     OMX_INT refWidth,     const OMXRect *pRefRect,     const OMX_U8 *pSrcCurrBuf,     const OMXVCM4P2Coordinate *pCurrPointPos,     const OMXVCMotionVector *pSrcPreMV,     const OMX_INT *pSrcPreSAD,     void *pMESpec,     OMXVCMotionVector *pDstMV,     OMX_INT *pDstSAD,     OMX_U8 BlockSize);/** * Function: armVCM4P2_BlockMatch_Half * * Description: * Performs a 16x16 block match with half-pixel resolution.  Returns the estimated  * motion vector and associated minimum SAD.  This function estimates the half-pixel  * motion vector by interpolating the integer resolution motion vector referenced  * by the input parameter pSrcDstMV, i.e., the initial integer MV is generated  * externally.  The input parameters pSrcRefBuf and pSearchPointRefPos should be  * shifted by the winning MV of 16x16 integer search prior to calling BlockMatch_Half_16x16.   * The function BlockMatch_Integer_16x16 may be used for integer motion estimation. * * Remarks: * * Parameters: * [in]	pSrcRefBuf		pointer to the reference Y plane; points to the reference MB  *                    that corresponds to the location of the current macroblock in  *                    the	current plane. * [in]	refWidth		  width of the reference plane * [in]	pRefRect		  reference plane valid region rectangle * [in]	pSrcCurrBuf		pointer to the current macroblock extracted from original plane  *                    (linear array, 256 entries); must be aligned on an 8-byte boundary.  * [in]	pSearchPointRefPos	position of the starting point for half pixel search (specified  *                          in terms of integer pixel units) in the reference plane. * [in]	rndVal			  rounding control bit for half pixel motion estimation;  *                    0=rounding control disabled; 1=rounding control enabled * [in]	pSrcDstMV		pointer to the initial MV estimate; typically generated during a prior  *                  16X16 integer search and its unit is half pixel. * [in] BlockSize     MacroBlock Size i.e either 16x16 or 8x8. * [out]pSrcDstMV		pointer to estimated MV * [out]pDstSAD			pointer to minimum SAD * * Return Value: * OMX_Sts_NoErr – no error * OMX_Sts_BadArgErr – bad arguments * */OMXResult armVCM4P2_BlockMatch_Half(     const OMX_U8 *pSrcRefBuf,     OMX_INT refWidth,     const OMXRect *pRefRect,     const OMX_U8 *pSrcCurrBuf,     const OMXVCM4P2Coordinate *pSearchPointRefPos,     OMX_INT rndVal,     OMXVCMotionVector *pSrcDstMV,     OMX_INT *pDstSAD,     OMX_U8 BlockSize);/** * Function: armVCM4P2_PadMV * * Description: * Performs motion vector padding for a macroblock. * * Remarks: * * Parameters: * [in] pSrcDstMV       pointer to motion vector buffer of the current *                              macroblock * [in] pTransp         pointer to transparent status buffer of the *                              current macroblock * [out]    pSrcDstMV       pointer to motion vector buffer in which the *                              motion vectors have been padded * Return Value: * Standard OMXResult result. See enumeration for possible result codes. * */OMXResult armVCM4P2_PadMV(     OMXVCMotionVector * pSrcDstMV,     OMX_U8 * pTransp);/*  * H.264 Specific Declarations  *//* Defines */#define ARM_M4P10_Q_OFFSET        (15)/* Dequant tables */extern const OMX_U8 armVCM4P10_PosToVCol4x4[16];extern const OMX_U8 armVCM4P10_PosToVCol2x2[4];extern const OMX_U8 armVCM4P10_VMatrix[6][3];extern const OMX_U32 armVCM4P10_MFMatrix[6][3];/* * Description: * This function perform the work required by the OpenMAX * DecodeCoeffsToPair function and DecodeChromaDCCoeffsToPair. * Since most of the code is common we share it here. * * Parameters: * [in]	ppBitStream		Double pointer to current byte in bit stream buffer * [in]	pOffset			Pointer to current bit position in the byte pointed *								to by *ppBitStream * [in]	sMaxNumCoeff	Maximum number of non-zero coefficients in current *								block (4,15 or 16) * [in]	nTable          Table number (0 to 4) according to the five columns *                      of Table 9-5 in the H.264 spec * [out]	ppBitStream		*ppBitStream is updated after each block is decoded * [out]	pOffset			*pOffset is updated after each block is decoded * [out]	pNumCoeff		Pointer to the number of nonzero coefficients in *								this block * [out]	ppPosCoefbuf	Double pointer to destination residual *								coefficient-position pair buffer * Return Value: * Standard omxError result. See enumeration for possible result codes. */OMXResult armVCM4P10_DecodeCoeffsToPair(     const OMX_U8** ppBitStream,     OMX_S32* pOffset,     OMX_U8* pNumCoeff,     OMX_U8**ppPosCoefbuf,     OMX_INT nTable,     OMX_INT sMaxNumCoeff         );/* * Description: * Perform DC style intra prediction, averaging upper and left block * * Parameters: * [in]	pSrcLeft		Pointer to the buffer of 16 left coefficients: *								p[x, y] (x = -1, y = 0..3) * [in]	pSrcAbove		Pointer to the buffer of 16 above coefficients: *								p[x,y] (x = 0..3, y = -1) * [in]	leftStep		Step of left coefficient buffer * [in]	dstStep			Step of the destination buffer * [in]	availability	Neighboring 16x16 MB availability flag * [out]	pDst			Pointer to the destination buffer * * Return Value: * None */void armVCM4P10_PredictIntraDC4x4(     const OMX_U8* pSrcLeft,     const OMX_U8 *pSrcAbove,     OMX_U8* pDst,     OMX_INT leftStep,     OMX_INT dstStep,     OMX_S32 availability        );/* * Description * Unpack a 4x4 block of coefficient-residual pair values

⌨️ 快捷键说明

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