[FFmpeg-devel] [PATCH] avcodec/libx264: support BGRA pixel format

Thomas Volkert silvo at gmx.net
Sat Feb 2 17:39:39 EET 2019


On 02.02.2019 16:14, Carl Eugen Hoyos wrote:
> 2019-02-02 16:05 GMT+01:00, Thomas Volkert <silvo at gmx.net>:
>> From: Thomas Volkert <thomas.volkert at net-zeal.com>
>>
>> ---
>>  libavcodec/libx264.c | 15 ++++++++-------
>>  1 file changed, 8 insertions(+), 7 deletions(-)
>>
>> diff --git a/libavcodec/libx264.c b/libavcodec/libx264.c
>> index a3493f393d..dd51fdc6dc 100644
>> --- a/libavcodec/libx264.c
>> +++ b/libavcodec/libx264.c
>> @@ -158,6 +158,9 @@ static int encode_nals(AVCodecContext *ctx, AVPacket
>> *pkt,
>>  static int avfmt2_num_planes(int avfmt)
>>  {
>>      switch (avfmt) {
>> +    case AV_PIX_FMT_BGRA:
> I was / am completely convinced that libx264 does not
> support AV_PIX_FMT_BGRA.
> Why do you believe it does / when was support added?

I can see the special handling of X264_CSP_BGRA in the code of libx264.
So, I wanted to get feedback from our list here.

But I have seen another mistake, the number of planes is wrong. It
should be 1 instead of 4.

Best regards,
Thomas.



More information about the ffmpeg-devel mailing list