[FFmpeg-devel] [RFC] Handling 8 < bit depth < 16
Jason Garrett-Glaser
darkshikari
Sun Sep 5 04:25:12 CEST 2010
Bit depths greater than 8 and less than 16 are inherently problematic.
We only have pixel formats for 8 and 16, but in practice, many
encoders want numbers like 10. Furthermore, a proper converter
between these numbers should dither, making conversion slightly less
than trivial. Thus, imagine the following situation:
Decode 16-bit RGB files from camera
Convert to 16-bit YUV
Pass to 10-bit x264
Encode
Somewhere in here, we have to go from 16 bit to 10 bit, but there's no
pixel format for these, nor is there a way for libx264.c in ffmpeg to
tell ffmpeg that it needs 10-bit. But it would be stupid, ugly, and
hacky to have libx264 itself perform the conversion -- pixel format
conversions should stay out of an encoder. And this doesn't solve the
problem of other encoders; x264 isn't the only encoder that does or we
want to have >8-bit support for.
What's the best approach here?
Dark Shikari
More information about the ffmpeg-devel
mailing list