From 14a1adb9e0f6d5e013202a91a167ab20047fe11a Mon Sep 17 00:00:00 2001 From: "T. van der Zwan" Date: Thu, 14 Nov 2013 08:52:10 +0000 Subject: [PATCH] Fixed dispmanx2png (incorrect color byte order) Former-commit-id: fe2529ba068e690e19797b3bd7ae10a2243c7286 --- test/dispmanx2png/dispmanx2png.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/dispmanx2png/dispmanx2png.cpp b/test/dispmanx2png/dispmanx2png.cpp index 1d33dcaa..6464a1f9 100644 --- a/test/dispmanx2png/dispmanx2png.cpp +++ b/test/dispmanx2png/dispmanx2png.cpp @@ -116,7 +116,8 @@ int main(int argc, char** argv) memcpy(scanLinePtr, imageRgba.memptr()+imageRgba.width()*iScanline, imageRgba.width()*sizeof(ColorRgba)); } - qImage.save(QString("HYPERION_%3.png").arg(iFrame)); + const QImage qImageSwp = qImage.rgbSwapped(); + qImageSwp.save(QString("HYPERION_%3.png").arg(iFrame)); ++iFrame; timespec sleepTime;