comparison vp56.c @ 5717:c5ec68f922d8 libavcodec

consistent spelling: plan => plane
author aurel
date Tue, 25 Sep 2007 21:01:34 +0000
parents 7577e3036290
children bb4293d858da
comparison
equal deleted inserted replaced
5716:7577e3036290 5717:c5ec68f922d8
398 static void vp56_decode_mb(vp56_context_t *s, int row, int col, int is_alpha) 398 static void vp56_decode_mb(vp56_context_t *s, int row, int col, int is_alpha)
399 { 399 {
400 AVFrame *frame_current, *frame_ref; 400 AVFrame *frame_current, *frame_ref;
401 vp56_mb_t mb_type; 401 vp56_mb_t mb_type;
402 vp56_frame_t ref_frame; 402 vp56_frame_t ref_frame;
403 int b, ab, b_max, plan, off; 403 int b, ab, b_max, plane, off;
404 404
405 if (s->framep[VP56_FRAME_CURRENT]->key_frame) 405 if (s->framep[VP56_FRAME_CURRENT]->key_frame)
406 mb_type = VP56_MB_INTRA; 406 mb_type = VP56_MB_INTRA;
407 else 407 else
408 mb_type = vp56_decode_mv(s, row, col); 408 mb_type = vp56_decode_mv(s, row, col);
421 b_max = 6 - 2*is_alpha; 421 b_max = 6 - 2*is_alpha;
422 422
423 switch (mb_type) { 423 switch (mb_type) {
424 case VP56_MB_INTRA: 424 case VP56_MB_INTRA:
425 for (b=0; b<b_max; b++) { 425 for (b=0; b<b_max; b++) {
426 plan = vp56_b2p[b+ab]; 426 plane = vp56_b2p[b+ab];
427 s->dsp.idct_put(frame_current->data[plan] + s->block_offset[b], 427 s->dsp.idct_put(frame_current->data[plane] + s->block_offset[b],
428 s->stride[plan], s->block_coeff[b]); 428 s->stride[plane], s->block_coeff[b]);
429 } 429 }
430 break; 430 break;
431 431
432 case VP56_MB_INTER_NOVEC_PF: 432 case VP56_MB_INTER_NOVEC_PF:
433 case VP56_MB_INTER_NOVEC_GF: 433 case VP56_MB_INTER_NOVEC_GF:
434 for (b=0; b<b_max; b++) { 434 for (b=0; b<b_max; b++) {
435 plan = vp56_b2p[b+ab]; 435 plane = vp56_b2p[b+ab];
436 off = s->block_offset[b]; 436 off = s->block_offset[b];
437 s->dsp.put_pixels_tab[1][0](frame_current->data[plan] + off, 437 s->dsp.put_pixels_tab[1][0](frame_current->data[plane] + off,
438 frame_ref->data[plan] + off, 438 frame_ref->data[plane] + off,
439 s->stride[plan], 8); 439 s->stride[plane], 8);
440 s->dsp.idct_add(frame_current->data[plan] + off, 440 s->dsp.idct_add(frame_current->data[plane] + off,
441 s->stride[plan], s->block_coeff[b]); 441 s->stride[plane], s->block_coeff[b]);
442 } 442 }
443 break; 443 break;
444 444
445 case VP56_MB_INTER_DELTA_PF: 445 case VP56_MB_INTER_DELTA_PF:
446 case VP56_MB_INTER_V1_PF: 446 case VP56_MB_INTER_V1_PF:
450 case VP56_MB_INTER_V1_GF: 450 case VP56_MB_INTER_V1_GF:
451 case VP56_MB_INTER_V2_GF: 451 case VP56_MB_INTER_V2_GF:
452 for (b=0; b<b_max; b++) { 452 for (b=0; b<b_max; b++) {
453 int x_off = b==1 || b==3 ? 8 : 0; 453 int x_off = b==1 || b==3 ? 8 : 0;
454 int y_off = b==2 || b==3 ? 8 : 0; 454 int y_off = b==2 || b==3 ? 8 : 0;
455 plan = vp56_b2p[b+ab]; 455 plane = vp56_b2p[b+ab];
456 vp56_mc(s, b, plan, frame_ref->data[plan], s->stride[plan], 456 vp56_mc(s, b, plane, frame_ref->data[plane], s->stride[plane],
457 16*col+x_off, 16*row+y_off); 457 16*col+x_off, 16*row+y_off);
458 s->dsp.idct_add(frame_current->data[plan] + s->block_offset[b], 458 s->dsp.idct_add(frame_current->data[plane] + s->block_offset[b],
459 s->stride[plan], s->block_coeff[b]); 459 s->stride[plane], s->block_coeff[b]);
460 } 460 }
461 break; 461 break;
462 } 462 }
463 } 463 }
464 464