Re: [Libav-user] Cheking for an alpha channel / using AVPixFmtDescriptor

2019-04-18 Thread Carl Eugen Hoyos
2019-04-18 11:34 GMT+02:00, Simone Donadini : > Thank you for the explanation Carl. > > Actually i can not deduce from your answer if the first method is correct, See the GPL for an answer;-) > but i will definitely not use the macro one. Good idea. Please avoid top-posting here, Carl Eugen ___

Re: [Libav-user] Cheking for an alpha channel / using AVPixFmtDescriptor

2019-04-18 Thread Simone Donadini
Thank you for the explanation Carl.Actually i can not deduce from your answer if the first method is correct, but i will definitely not use the macro one. Bye,Simone.From: "Carl Eugen Hoyos" Date: 17/04/2019 at 23:30:48To: "This list is about using libavcodec, libavformat, libavutil, libavdevice an

Re: [Libav-user] Cheking for an alpha channel / using AVPixFmtDescriptor

2019-04-17 Thread Carl Eugen Hoyos
2019-04-17 11:37 GMT+02:00, Simone Donadini : > When opening a media i need to check if the pixel format holds an alpha > channel. > I can check for the alpha flag in the pixel format description, like this: > const AVPixFmtDescriptor *pixDesc = av_pix_fmt_desc_get(pix_format); > bool has_alpha =

[Libav-user] Cheking for an alpha channel / using AVPixFmtDescriptor

2019-04-17 Thread Simone Donadini
Hi,When opening a media i need to check if the pixel format holds an alpha channel.I can check for the alpha flag in the pixel format description, like this:const AVPixFmtDescriptor *pixDesc = av_pix_fmt_desc_get(pix_format);bool has_alpha = pixDesc->flags & AV_PIX_FMT_FLAG_ALPHA;But i noticed that