Skip to content

armgit / krita

Public Imported from GitHub
0

Krita is a free and open source cross-platform application that offers an end-to-end solution for creating digital art files from scratch built on the KDE and Qt frameworks.

C++

Add comment about how this is supposed to work

Halla Remptb22ece9db232
diff --git a/libs/psdutils/asl/kis_asl_reader.cpp b/libs/psdutils/asl/kis_asl_reader.cpp
index b1f70319d6..5e9a9d5310 100644
--- a/libs/psdutils/asl/kis_asl_reader.cpp
+++ b/libs/psdutils/asl/kis_asl_reader.cpp
@@ -395,6 +395,7 @@ QImage readVirtualArrayList(QIODevice &device, int numPlanes, const QVector<QRgb
if (format == QImage::Format_ARGB32) {
quint8 *dstPtr = image.bits();
+ // This copies the single channel data into all three rgb channels, creating a grayscale picture
for (int i = 0; i < dataLength; i++) {
for (int j = 2; j >= 0; j--) {
int plane;
@@ -404,7 +405,6 @@ QImage readVirtualArrayList(QIODevice &device, int numPlanes, const QVector<QRgb
else {
plane = j;
}
-
*dstPtr++ = dataPlanes[plane][i];
}
*dstPtr++ = 0xFF;