1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00

ffplay: use stream sample_aspect_ratio if available in source frames

When we are using filter chains we have to set the aspect ratio of the source
to the best known value, we use the av_guess_sample_aspect_ratio function to
determine that.

Fixes ticket 1228.

Signed-off-by: Marton Balint <cus@passwd.hu>
This commit is contained in:
Marton Balint 2012-04-21 13:06:55 +02:00
parent 89080a0a5e
commit 84087b243e

View File

@ -1688,6 +1688,7 @@ static int input_request_frame(AVFilterLink *link)
av_free_packet(&pkt); av_free_packet(&pkt);
avfilter_copy_frame_props(picref, priv->frame); avfilter_copy_frame_props(picref, priv->frame);
picref->video->sample_aspect_ratio = av_guess_sample_aspect_ratio(priv->is->ic, priv->is->video_st, priv->frame);
picref->pts = pts; picref->pts = pts;
avfilter_start_frame(link, picref); avfilter_start_frame(link, picref);