On Wed, Jan 12, 2022 at 10:51 AM Anton Khirnov <[email protected]> wrote:
> Quoting Vittorio Giovara (2022-01-05 16:15:06) > > This resulted in a dimmed tonemapping due to bad resulting luma > > calculation. > > > > Found by: Derek Buitenhuis > > > > Signed-off-by: Vittorio Giovara <[email protected]> > > --- > > libavfilter/vf_tonemap.c | 10 +++++----- > > 1 file changed, 5 insertions(+), 5 deletions(-) > > > > diff --git a/libavfilter/vf_tonemap.c b/libavfilter/vf_tonemap.c > > index 363df8034b..644c9fd9e3 100644 > > --- a/libavfilter/vf_tonemap.c > > +++ b/libavfilter/vf_tonemap.c > > @@ -120,17 +120,17 @@ static void tonemap(TonemapContext *s, AVFrame > *out, const AVFrame *in, > > const AVPixFmtDescriptor *desc, int x, int y, > double peak) > > { > > const float *r_in = (const float *)(in->data[0] + x * > desc->comp[0].step + y * in->linesize[0]); > > - const float *b_in = (const float *)(in->data[1] + x * > desc->comp[1].step + y * in->linesize[1]); > > - const float *g_in = (const float *)(in->data[2] + x * > desc->comp[2].step + y * in->linesize[2]); > > + const float *g_in = (const float *)(in->data[1] + x * > desc->comp[1].step + y * in->linesize[1]); > > + const float *b_in = (const float *)(in->data[2] + x * > desc->comp[2].step + y * in->linesize[2]); > > I'm confused by this, the filter seems to use GBR pixel format. > hmmm right, so the first and last elements are swapped... i'm possibly implying the order in a wrong way, let me send a more generic version of this then -- Vittorio _______________________________________________ ffmpeg-devel mailing list [email protected] https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email [email protected] with subject "unsubscribe".
