History

avfilter/vf_stereo3d: stop dumping half of data for interleave rows output

Paul B Mahol committed 11 years ago

Commit 0c511eb1 parent 32dd9b21 file · +5 −14Browse files

Unified · Split

libavfilter/vf_stereo3d.c+5−14
@@ -327,13 +327,6 @@ static int config_output(AVFilterLink *outlink) · 326 unmodified lines
327 case ABOVE_BELOW_LR:327 case ABOVE_BELOW_LR:
328 case ABOVE_BELOW_2_RL:328 case ABOVE_BELOW_2_RL:
329 case ABOVE_BELOW_RL:329 case ABOVE_BELOW_RL:
330 if (s->out.format == INTERLEAVE_ROWS_LR ||
331 s->out.format == INTERLEAVE_ROWS_RL) {
332 if (inlink->h & 3) {
333 av_log(ctx, AV_LOG_ERROR, "height must be multiple of 4\n");
334 return AVERROR_INVALIDDATA;
335 }
336 }
337 if (inlink->h & 1) {330 if (inlink->h & 1) {
338 av_log(ctx, AV_LOG_ERROR, "height must be even\n");331 av_log(ctx, AV_LOG_ERROR, "height must be even\n");
339 return AVERROR_INVALIDDATA;332 return AVERROR_INVALIDDATA;
@@ -391,9 +384,7 @@ static int config_output(AVFilterLink *outlink) · 51 unmodified lines
391 s->in.off_lstep = 1;384 s->in.off_lstep = 1;
392 else385 else
393 s->in.off_rstep = 1;386 s->in.off_rstep = 1;
394 if (s->out.format != INTERLEAVE_ROWS_LR &&387 if (s->out.format != CHECKERBOARD_LR &&
395 s->out.format != INTERLEAVE_ROWS_RL &&
396 s->out.format != CHECKERBOARD_LR &&
397 s->out.format != CHECKERBOARD_RL)388 s->out.format != CHECKERBOARD_RL)
398 s->height = inlink->h / 2;389 s->height = inlink->h / 2;
399 break;390 break;
@@ -468,16 +459,16 @@ static int config_output(AVFilterLink *outlink) · 68 unmodified lines
468 s->out.row_left = s->height;459 s->out.row_left = s->height;
469 break;460 break;
470 case INTERLEAVE_ROWS_LR:461 case INTERLEAVE_ROWS_LR:
471 s->in.row_step = 2;462 s->in.row_step = 1 + (s->in.format == INTERLEAVE_ROWS_RL);
472 s->out.row_step = 2;463 s->out.row_step = 2;
473 s->height = s->height / 2;464 s->out.height = s->height * 2;
474 s->out.off_rstep = 1;465 s->out.off_rstep = 1;
475 s->in.off_rstep = s->in.format != INTERLEAVE_ROWS_RL;466 s->in.off_rstep = s->in.format != INTERLEAVE_ROWS_RL;
476 break;467 break;
477 case INTERLEAVE_ROWS_RL:468 case INTERLEAVE_ROWS_RL:
478 s->in.row_step = 2;469 s->in.row_step = 1 + (s->in.format == INTERLEAVE_ROWS_LR);
479 s->out.row_step = 2;470 s->out.row_step = 2;
480 s->height = s->height / 2;471 s->out.height = s->height * 2;
481 s->out.off_lstep = 1;472 s->out.off_lstep = 1;
482 s->in.off_lstep = s->in.format != INTERLEAVE_ROWS_LR;473 s->in.off_lstep = s->in.format != INTERLEAVE_ROWS_LR;
483 break;474 break;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t