Lines Matching defs:video

39 PV_STATUS DecodeFrameDataPartMode(VideoDecData *video)
42 Vop *currVop = video->currVop;
43 BitstreamDecVideo *stream = video->bitstream;
45 int nMBPerRow = video->nMBPerRow;
49 int nTotalMB = video->nTotalMB;
61 oscl_memset(video->motX, 0, sizeof(MOT)*4*nTotalMB);
62 oscl_memset(video->motY, 0, sizeof(MOT)*4*nTotalMB);
73 // oscl_memset(video->sliceNo, 0, sizeof(uint8)*nTotalMB);
79 video->mbnum = mbnum;
80 video->mbnum_row = PV_GET_ROW(mbnum, nMBPerRow); /* This is needed if nbnum is read from the packet header */
81 video->mbnum_col = mbnum - video->mbnum_row * nMBPerRow;
86 status = DecodeDataPart_I_VideoPacket(video, slice_counter);
90 status = DecodeDataPart_P_VideoPacket(video, slice_counter);
98 while ((status = PV_ReadVideoPacketHeader(video, &mbnum)) == PV_FAIL)
111 if (mbnum > video->mbnum + 1)
113 ConcealPacket(video, video->mbnum, mbnum, slice_counter);
138 PV_STATUS DecodeDataPart_I_VideoPacket(VideoDecData *video, int slice_counter)
141 uint8 *Mode = video->headerInfo.Mode;
142 BitstreamDecVideo *stream = video->bitstream;
143 int nTotalMB = video->nTotalMB;
145 int16 QP, *QPMB = video->QPMB;
149 int nMBPerRow = video->nMBPerRow;
154 QP = video->currVop->quantizer;
155 mb_start = mbnum = video->mbnum;
156 video->usePrevQP = 0; /* 04/27/01 */
174 video->headerInfo.CBP[mbnum] = (uint8)((MCBPC >> 4) & 3);
175 status = GetMBheaderDataPart_DQUANT_DC(video, &QP);
176 video->usePrevQP = 1; /* set it after the first coded MB 04/27/01 */
181 VideoDecoderErrorDetected(video);
182 video->mbnum = mb_start;
187 video->sliceNo[mbnum] = (uint8) slice_counter;
189 video->mbnum = ++mbnum;
197 /* have we reached the end of the video packet or vop? */
201 while (tmpvar != DC_MARKER && video->mbnum < nTotalMB);
219 VideoDecoderErrorDetected(video);
221 video->mbnum = mb_start;
230 mb_end = video->mbnum;
236 video->mbnum = mbnum;
238 video->mbnum_row = PV_GET_ROW(mbnum, nMBPerRow); /* This is needed if nbnum is read from the packet header */
239 video->mbnum_col = mbnum - video->mbnum_row * nMBPerRow;
241 video->acPredFlag[mbnum] = (uint8) BitstreamRead1Bits(stream);
247 VideoDecoderErrorDetected(video);
250 ConcealTexture_I(video, startFirstPart, mb_start, mb_end, slice_counter);
254 video->headerInfo.CBP[mbnum] |= (uint8)(CBPY << 2);
257 video->usePrevQP = 0;
261 video->mbnum = mbnum;
263 video->mbnum_row = PV_GET_ROW(mbnum , nMBPerRow); /* This is needed if nbnum is read from the packet header */
264 video->mbnum_col = mbnum - video->mbnum_row * nMBPerRow;
267 status = GetMBData_DataPart(video);
271 VideoDecoderErrorDetected(video);
274 ConcealTexture_I(video, startFirstPart, mb_start, mb_end, slice_counter);
277 video->usePrevQP = 1; /* 04/27/01 should be set after decoding first MB */
283 VideoDecoderErrorDetected(video);
285 ConcealTexture_I(video, startFirstPart, mb_start, mb_end, slice_counter);
303 PV_STATUS DecodeDataPart_P_VideoPacket(VideoDecData *video, int slice_counter)
306 uint8 *Mode = video->headerInfo.Mode;
307 BitstreamDecVideo *stream = video->bitstream;
308 int nTotalMB = video->nTotalMB;
310 int16 QP, *QPMB = video->QPMB;
317 int nMBPerRow = video->nMBPerRow;
321 mb_start = video->mbnum;
322 video->usePrevQP = 0; /* 04/27/01 */
336 status = GetMBheaderDataPart_P(video);
341 VideoDecoderErrorDetected(video);
343 video->mbnum = mb_start;
348 video->sliceNo[video->mbnum] = (uint8) slice_counter;
350 if (Mode[video->mbnum] & INTER_MASK) /* INTER || INTER_Q || INTER_4V */
353 status = PV_GetMBvectors(video, Mode[video->mbnum]);
357 VideoDecoderErrorDetected(video);
359 video->mbnum = mb_start;
363 video->mbnum++;
365 video->mbnum_row = PV_GET_ROW(video->mbnum, nMBPerRow); /* This is needed if mbnum is read from the packet header */
366 video->mbnum_col = video->mbnum - video->mbnum_row * nMBPerRow;
374 /* have we reached the end of the video packet or vop? */
378 while (tmpvar != MOTION_MARKER_COMB && video->mbnum < nTotalMB);
396 VideoDecoderErrorDetected(video);
398 video->mbnum = mb_start;
406 QP = video->currVop->quantizer;
408 mb_end = video->mbnum;
420 video->mbnum = mbnum;
421 video->mbnum_row = PV_GET_ROW(mbnum, nMBPerRow); /* This is needed if nbnum is read from the packet header */
422 video->mbnum_col = mbnum - video->mbnum_row * nMBPerRow;
427 video->acPredFlag[mbnum] = (uint8) BitstreamRead1Bits_INLINE(stream);
434 VideoDecoderErrorDetected(video);
437 ConcealTexture_P(video, mb_start, mb_end, slice_counter);
441 video->headerInfo.CBP[mbnum] |= (uint8)(CBPY << 2);
444 status = GetMBheaderDataPart_DQUANT_DC(video, &QP);
447 video->usePrevQP = 1; /* 04/27/01 */
451 video->usePrevQP = 0; /* 04/27/01 */
455 video->mbnum = mbnum;
456 video->mbnum_row = PV_GET_ROW(mbnum, nMBPerRow); /* This is needed if nbnum is read from the packet header */
457 video->mbnum_col = mbnum - video->mbnum_row * nMBPerRow;
463 status = GetMBData_DataPart(video);
467 VideoDecoderErrorDetected(video);
471 ConcealTexture_P(video, mb_start, mb_end, slice_counter);
474 video->usePrevQP = 1; /* 04/27/01 */
479 /* Motion compensation and put it to video->mblock->pred_block */
480 SkippedMBMotionComp(video);
482 //oscl_memset(video->predDCAC_row + video->mbnum_col, 0, sizeof(typeDCACStore)); /* SKIPPED_ACDC */
483 //oscl_memset(video->predDCAC_col, 0, sizeof(typeDCACStore));
485 pbyte = (uint8*)(video->predDCAC_row + video->mbnum_col);
487 pbyte = (uint8*)(video->predDCAC_col);
496 VideoDecoderErrorDetected(video);
498 ConcealTexture_P(video, mb_start, mb_end, slice_counter);
516 PV_STATUS GetMBheaderDataPart_DQUANT_DC(VideoDecData *video, int16 *QP)
519 BitstreamDecVideo *stream = video->bitstream;
520 int mbnum = video->mbnum;
521 int intra_dc_vlc_thr = video->currVop->intraDCVlcThr;
522 uint8 *Mode = video->headerInfo.Mode;
524 typeDCStore *DC = video->predDC + mbnum;
546 if (video->usePrevQP)
547 QP_tmp = video->QPMB[mbnum-1];
574 PV_STATUS GetMBheaderDataPart_P(VideoDecData *video)
576 BitstreamDecVideo *stream = video->bitstream;
577 int mbnum = video->mbnum;
578 uint8 *Mode = video->headerInfo.Mode;
579 typeDCStore *DC = video->predDC + mbnum;
608 video->headerInfo.CBP[mbnum] = (uint8)((MCBPC >> 4) & 3);
618 PV_STATUS GetMBData_DataPart(VideoDecData *video)
620 int mbnum = video->mbnum;
622 MacroBlock *mblock = video->mblock;
623 int QP = video->QPMB[mbnum];
626 int width = video->width;
627 int intra_dc_vlc_thr = video->currVop->intraDCVlcThr;
628 uint CBP = video->headerInfo.CBP[mbnum];
629 uint8 mode = video->headerInfo.Mode[mbnum];
630 int x_pos = video->mbnum_col;
631 typeDCStore *DC = video->predDC + mbnum;
637 int y_pos = video->mbnum_row;
640 int TotalMB = video->nTotalMB;
641 int MB_in_width = video->nMBPerRow;
650 if (video->postFilterType != PV_NO_POST_PROC)
653 pp_mod[0] = video->pstprcTypCur + (y_pos << 1) * (MB_in_width << 1) + (x_pos << 1);
657 pp_mod[4] = video->pstprcTypCur + (TotalMB << 2) + mbnum;
669 if (video->usePrevQP)
670 QP_tmp = video->QPMB[mbnum-1]; /* running QP 04/26/01 */
684 ncoeffs[comp] = VlcDequantH263IntraBlock(video, comp,
702 if (video->postFilterType != PV_NO_POST_PROC)
706 MBlockIDCT(video);
714 MBMotionComp(video, CBP);
716 c_comp = video->currVop->yChan + offset;
725 ncoeffs[comp] = VlcDequantH263InterBlock(video, comp,
742 if (video->postFilterType != PV_NO_POST_PROC)
750 ncoeffs[4] = VlcDequantH263InterBlock(video, 4,
755 BlockIDCT(video->currVop->uChan + (offset >> 2) + (x_pos << 2), mblock->pred_block + 256, mblock->block[4], width >> 1, ncoeffs[4],
764 if (video->postFilterType != PV_NO_POST_PROC)
770 ncoeffs[5] = VlcDequantH263InterBlock(video, 5,
775 BlockIDCT(video->currVop->vChan + (offset >> 2) + (x_pos << 2), mblock->pred_block + 264, mblock->block[5], width >> 1, ncoeffs[5],
784 if (video->postFilterType != PV_NO_POST_PROC)
791 /* Motion compensation and put it to video->mblock->pred_block */