[FFmpeg-devel] [PATCH]Support encoding gray8a in pam
stefasab at gmail.com
Sun Jan 15 12:53:06 CET 2012
On date Sunday 2012-01-15 00:17:16 +0000, Carl Eugen Hoyos encoded:
> Carl Eugen Hoyos <cehoyos <at> ag.or.at> writes:
> > Michael Niedermayer <michaelni <at> gmx.at> writes:
> > > > Attached patch allows encoding gray8a in pam.
> > > > Decoding currently unsupported.
> > >
> > > if it has been tested it should be ok
> > Patch applied.
> This "broke" pam encoding insofar as avcodec_find_best_pix_fmt2() prefers gray8a
> over all (?) other pix_fmts...
> I don't know how to fix this, Carl Eugen
> $ ffmpeg -i out.jpg out.pam
> Input #0, image2, from 'out.jpg':
> Duration: 00:00:00.04, start: 0.000000, bitrate: N/A
> Stream #0:0: Video: mjpeg, yuvj420p, 256x256, 25 tbr, 25 tbn, 25 tbc
> Incompatible pixel format 'yuvj420p' for codec 'pam', auto-selecting format
> [buffer @ 0x8dd6aa0] w:256 h:256 pixfmt:yuvj420p tb:1/1000000 sar:0/1 sws_param:
> [buffersink @ 0x8dc9100] auto-inserting filter 'auto-inserted scale 0' between
> the filter 'src' and the filter 'out'
> Impossible to convert between the formats supported by the filter 'auto-inserted
> scale 0' and the filter 'out'
> Error opening filters!
A possible solution would be to implement gray8 in libswscale (and
thus support it in the scale filter).
Anyway I think you can force the output format with -pix_fmt.
FFmpeg = Fundamentalist and Fantastic Majestic Plastic Elected Gadget
More information about the ffmpeg-devel