From 03593d86b8ba9718c36963d5302d868e574e5148 Mon Sep 17 00:00:00 2001 From: Laszlo Agocs Date: Fri, 19 Dec 2014 12:19:04 +0100 Subject: [PATCH] Support byte ordered QImage formats in pixelFormatFromImageFormat For QVideoFrame purposes they are equivalent. Change-Id: I776c60aa8ca848e58499bbd0c1fc25c457d46ef6 Reviewed-by: Yoann Lopes --- src/multimedia/video/qvideoframe.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/multimedia/video/qvideoframe.cpp b/src/multimedia/video/qvideoframe.cpp index d808862..8dd23d2 100644 --- a/src/multimedia/video/qvideoframe.cpp +++ b/src/multimedia/video/qvideoframe.cpp @@ -902,10 +902,13 @@ QVideoFrame::PixelFormat QVideoFrame::pixelFormatFromImageFormat(QImage::Format { switch (format) { case QImage::Format_RGB32: + case QImage::Format_RGBX8888: return Format_RGB32; case QImage::Format_ARGB32: + case QImage::Format_RGBA8888: return Format_ARGB32; case QImage::Format_ARGB32_Premultiplied: + case QImage::Format_RGBA8888_Premultiplied: return Format_ARGB32_Premultiplied; case QImage::Format_RGB16: return Format_RGB565; -- 2.7.4