[FFmpeg-devel] Channel mapping integration in af pan

Clément Bœsch ubitux at gmail.com
Wed Jan 18 13:31:28 CET 2012


Hi,

After the first attempt to have a channel mapping filter [1], Nicolas proposed
to integrate it in af pan filter instead. So here here is a patch set for that
purpose.

Note: I noticed the union gain (double/int) doesn't work as expected when we
try "if (pan->gain.i[x][y])" with small coefficients. It can be fixed using
int64_t instead of int in the union, but I'm actually wondering if the union
couldn't just be dropped instead.

Also, a more problematic issue is that this example (taken from the doc):

  pan=stereo: FL < FL + 0.5*FC + 0.6*BL + 0.6*SL : FR < FR + 0.5*FC + 0.6*BR + 0.6*SR

doesn't actually work ('Expected out channel name, got " FL < FL"'). I didn't
look closer though. BTW, I think quotes should be added in this example.

And last thing, the patch set introduces a const warning, but I don't know
what's the preferred way of fixing it:

  libavfilter/af_pan.c:316:5: warning: passing argument 4 of ‘swr_convert’ from
  incompatible pointer type [enabled by default]
  ./libswresample/swresample.h:111:5: note: expected ‘const uint8_t **’ but
  argument is of type ‘uint8_t **’

I believe changing the swresample prototypes is the best way to go, but well…

Best regards,

[1]: https://ffmpeg.org/pipermail/ffmpeg-devel/2012-January/118932.html



More information about the ffmpeg-devel mailing list