aboutsummaryrefslogtreecommitdiffstats
path: root/fftools/ffmpeg_filter.c
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2024-02-13 12:18:27 +0100
committerAnton Khirnov <anton@khirnov.net>2024-02-21 10:27:20 +0100
commitfef3052df3166c477f4ab5311f4ee2e18d0296de (patch)
treecdad85996e12a9e8d53bc79042b25ebedfcdd586 /fftools/ffmpeg_filter.c
parent6315f78e0c0d847532f221cc696956888410d094 (diff)
downloadffmpeg-fef3052df3166c477f4ab5311f4ee2e18d0296de.tar.gz
fftools/ffmpeg_filter: pass autorotate/reinit flags through InputFilterOptions
Rather than read them directly from InputStream. This is a step towards avoiding the assumption that filtergraph inputs are always fed by demuxers.
Diffstat (limited to 'fftools/ffmpeg_filter.c')
-rw-r--r--fftools/ffmpeg_filter.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/fftools/ffmpeg_filter.c b/fftools/ffmpeg_filter.c
index d182f3ab2e..56aa3edd78 100644
--- a/fftools/ffmpeg_filter.c
+++ b/fftools/ffmpeg_filter.c
@@ -1534,7 +1534,8 @@ static int configure_input_video_filter(FilterGraph *fg, AVFilterGraph *graph,
av_assert0(desc);
// TODO: insert hwaccel enabled filters like transpose_vaapi into the graph
- if (ist->autorotate && !(desc->flags & AV_PIX_FMT_FLAG_HWACCEL)) {
+ if ((ifp->opts.flags & IFILTER_FLAG_AUTOROTATE) &&
+ !(desc->flags & AV_PIX_FMT_FLAG_HWACCEL)) {
int32_t *displaymatrix = ifp->displaymatrix;
double theta;
@@ -2614,7 +2615,7 @@ static int send_frame(FilterGraph *fg, FilterGraphThread *fgt,
} else if (ifp->displaymatrix_present)
need_reinit |= MATRIX_CHANGED;
- if (!ifp->ist->reinit_filters && fgt->graph)
+ if (!(ifp->opts.flags & IFILTER_FLAG_REINIT) && fgt->graph)
need_reinit = 0;
if (!!ifp->hw_frames_ctx != !!frame->hw_frames_ctx ||