On Sun, 2022-01-23 at 01:06 +0100, Carl Eugen Hoyos wrote: > Am Fr., 21. Jan. 2022 um 06:56 Uhr schrieb Xiang, Haihao > <haihao.xiang-at-intel....@ffmpeg.org>: > > > > > -----Original Message----- > > > From: ffmpeg-devel <ffmpeg-devel-boun...@ffmpeg.org> On Behalf Of Xiang, > > > Haihao > > > Sent: Tuesday, June 30, 2020 15:34 > > > To: ffmpeg-devel@ffmpeg.org > > > Subject: Re: [FFmpeg-devel] [PATCH v1 1/9] lavu/pix_fmt: add P012 pixel > > > format > > > > > > > Am So., 28. Juni 2020 um 23:01 Uhr schrieb Mark Thompson > > > > <s...@jkqxz.net>: > > > > > > > > > FFmpeg has always used pixfmt as defining both the memory layout > > > > > and which bits are used in that (so, for example, ARGB and 0RGB > > > > > are not the same thing) > > > > > > > > But they have the same bitdepth per component... > > > Agree with Mark. P012 and P016 have different significant bits, we should > > > use > > > different pixfmts, otherwise an extra field in AVFrame is needed for bit > > > depth. > > > > > > BTW there are the YUV420P variants for 10 / 12 / 14 / 16 bit in FFmpeg, it > > > would be better to follow FFmpeg's style to introduce P012 format instead > > > of reusing P016. > > I was under the impression that YUV420P12 is much more different from > YUV420P16 than P012 from P016: Did I misunderstand? > (Reading the thread again, I don't think I did)
I understand YUV420P12 is a LSB format, so YUV420P12 can't be taken as YUV420P16. The style here means FFmpeg uses pixfmt for both memory layout and bit depth. > > > Sorry for picking up this old thread. > > > > We'd like to add the support for 12bit decoding / encoding in VAAPI and QSV. > > Is there any other concern if adding P012 in FFmpeg ? > > Did you already explain why you cannot use P016 or in which situation > it would create a different output? $ ffmpeg -hwaccel vaapi -f rawvideo -pix_fmt p016 -s 1920x1080 -i input.yuv -vf "hwupload,format=vaapi" -c:v hevc_vaapi -f null - If using P016, how will we know the input is 12bit indeed, not 14/16bit if hevc_vaapi may support both 12bit and 14/16bit inputs in the future ? Will we add a new option to ffmpeg to specify the bit depth and a new flag in AVFrame ? Thanks Haihao > > Carl Eugen > _______________________________________________ > ffmpeg-devel mailing list > ffmpeg-devel@ffmpeg.org > https://ffmpeg.org/mailman/listinfo/ffmpeg-devel > > To unsubscribe, visit link above, or email > ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe". _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".