[Libav-user] Converting AV_PIX_FMT_CUDA image (AVFrame) to AV_PIX_FMT_BGRA image
Philippe Gorley
philippe.gorley at savoirfairelinux.com
Fri Feb 22 17:31:17 EET 2019
On 2019-02-22 5:24 a.m., Ахмед Анам wrote:
> I have to transform AV_PIX_FMT_CUDA image to AV_PIX_FMT_BGRA image. In
> your code you transform AV_PIX_FMT_RGB24 to AV_PIX_FMT_NV12. I tried to
> run your code. There are no errors but I can not display images because
> I need BGRA pixel format to display them. I don't understand how to get
> BGRA image from AV_PIX_FMT_CUDA image.
AV_PIX_FMT_CUDA is a hardware format, you need to transfer the frame
data into a software frame before using it. You can see an example of
this in doc/examples/hw_decode.c. Look for av_hwframe_transfer_data.
>
>
> --
> С уважением, Ахмед Анам.
> Best regards, Akhmed Anam.
>
> _______________________________________________
> Libav-user mailing list
> Libav-user at ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/libav-user
>
> To unsubscribe, visit link above, or email
> libav-user-request at ffmpeg.org with subject "unsubscribe".
>
--
Philippe Gorley
Free Software Consultant | Montréal, Qc
Savoir-faire Linux
More information about the Libav-user
mailing list