Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Krita
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Fred Fonkle
Krita
Commits
9d648d2f
Commit
9d648d2f
authored
Dec 05, 2012
by
Halla Rempt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix warning
parent
6d360054
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
krita/plugins/formats/psd/psd_layer_record.cpp
krita/plugins/formats/psd/psd_layer_record.cpp
+2
-2
No files found.
krita/plugins/formats/psd/psd_layer_record.cpp
View file @
9d648d2f
...
...
@@ -656,7 +656,7 @@ bool PSDLayerRecord::writePixelData(QIODevice *io)
// if the bitdepth > 8, place the bytes in the right order
// if cmyk, invert the pixel value
if
(
m_header
.
channelDepth
==
8
)
{
if
(
channelInfoRecords
[
channelInfoIndex
]
->
channelId
>=
0
&&
m_header
.
colormode
==
CMYK
||
m_header
.
colormode
==
CMYK64
)
{
if
(
channelInfoRecords
[
channelInfoIndex
]
->
channelId
>=
0
&&
(
m_header
.
colormode
==
CMYK
||
m_header
.
colormode
==
CMYK64
)
)
{
for
(
int
i
=
0
;
i
<
rc
.
width
()
*
rc
.
height
();
++
i
)
{
planes
[
channelInfoIndex
][
i
]
=
255
-
planes
[
channelInfoIndex
][
i
];
}
...
...
@@ -667,7 +667,7 @@ bool PSDLayerRecord::writePixelData(QIODevice *io)
for
(
int
i
=
0
;
i
<
rc
.
width
()
*
rc
.
height
();
++
i
)
{
val
=
reinterpret_cast
<
quint16
*>
(
planes
[
channelInfoIndex
])[
i
];
val
=
ntohs
(
val
);
if
(
m_header
.
colormode
==
CMYK
||
m_header
.
colormode
==
CMYK64
)
{
if
(
channelInfoRecords
[
channelInfoIndex
]
->
channelId
>=
0
&&
(
m_header
.
colormode
==
CMYK
||
m_header
.
colormode
==
CMYK64
)
)
{
val
=
quint16_MAX
-
val
;
}
reinterpret_cast
<
quint16
*>
(
planes
[
channelInfoIndex
])[
i
]
=
val
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment