summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarti Maria <marti.maria@littlecms.com>2021-09-23 19:10:09 +0200
committerGitHub <noreply@github.com>2021-09-23 19:10:09 +0200
commitc6d1c9c07cfd03642d154973d036fccc59a2075c (patch)
tree28c96dece7c9d2d0cf7ce3fcc5fcca054a3ba76a
parent67d6968f8ff00e9134a574ae919b7360f1d8ec94 (diff)
parentedab0f90cfba3812c82693f54fbe629e9462ff97 (diff)
downloadlcms2-c6d1c9c07cfd03642d154973d036fccc59a2075c.tar.gz
Merge pull request #282 from Lynx3d/cmyk-lab-copy-alpha-fixes
Fix float CMYK & Lab copy Alpha, and a previous mistake Looks great, thank you!
-rw-r--r--plugins/fast_float/src/fast_16_tethra.c2
-rw-r--r--plugins/fast_float/src/fast_8_tethra.c2
-rw-r--r--plugins/fast_float/src/fast_float_cmyk.c5
-rw-r--r--plugins/fast_float/src/fast_float_lab.c3
-rw-r--r--plugins/fast_float/src/fast_float_tethra.c2
5 files changed, 8 insertions, 6 deletions
diff --git a/plugins/fast_float/src/fast_16_tethra.c b/plugins/fast_float/src/fast_16_tethra.c
index 846eaf6..9fa7af4 100644
--- a/plugins/fast_float/src/fast_16_tethra.c
+++ b/plugins/fast_float/src/fast_16_tethra.c
@@ -293,7 +293,7 @@ void PerformanceEval16(struct _cmstransform_struct *CMMcargo,
{
res16 = *(const cmsUInt16Number*)ain;
TO_OUTPUT(out[OutChan], res16);
- ain += SourceIncrements[TotalOut];
+ ain += SourceIncrements[3];
out[TotalOut] += DestIncrements[TotalOut];
}
diff --git a/plugins/fast_float/src/fast_8_tethra.c b/plugins/fast_float/src/fast_8_tethra.c
index 76091d4..3302e01 100644
--- a/plugins/fast_float/src/fast_8_tethra.c
+++ b/plugins/fast_float/src/fast_8_tethra.c
@@ -253,7 +253,7 @@ void PerformanceEval8(struct _cmstransform_struct *CMMcargo,
if (ain) {
*out[TotalOut] = *ain;
- ain += SourceIncrements[TotalOut];
+ ain += SourceIncrements[3];
out[TotalOut] += DestIncrements[TotalOut];
}
diff --git a/plugins/fast_float/src/fast_float_cmyk.c b/plugins/fast_float/src/fast_float_cmyk.c
index a0a23de..0b68fad 100644
--- a/plugins/fast_float/src/fast_float_cmyk.c
+++ b/plugins/fast_float/src/fast_float_cmyk.c
@@ -304,8 +304,9 @@ void FloatCMYKCLUTEval(struct _cmstransform_struct *CMMcargo,
}
if (ain)
- *out[TotalOut] = *ain;
-
+ *(cmsFloat32Number*)(out[TotalOut]) = *(cmsFloat32Number*)ain;
+ ain += SourceIncrements[4];
+ out[TotalOut] += DestIncrements[TotalOut];
}
strideIn += Stride->BytesPerLineIn;
diff --git a/plugins/fast_float/src/fast_float_lab.c b/plugins/fast_float/src/fast_float_lab.c
index 2f31d7d..376e93d 100644
--- a/plugins/fast_float/src/fast_float_lab.c
+++ b/plugins/fast_float/src/fast_float_lab.c
@@ -317,7 +317,8 @@ void LabCLUTEval(struct _cmstransform_struct* CMMcargo,
if (xin)
{
- *(cmsFloat32Number*) (out[TotalOut]) = *xin;
+ *(cmsFloat32Number*) (out[TotalOut]) = *(cmsFloat32Number*)xin;
+ xin += SourceIncrements[3];
out[TotalOut] += DestIncrements[TotalOut];
}
}
diff --git a/plugins/fast_float/src/fast_float_tethra.c b/plugins/fast_float/src/fast_float_tethra.c
index d57eedd..8f95a6d 100644
--- a/plugins/fast_float/src/fast_float_tethra.c
+++ b/plugins/fast_float/src/fast_float_tethra.c
@@ -212,7 +212,7 @@ void FloatCLUTEval(struct _cmstransform_struct* CMMcargo,
if (ain) {
*(cmsFloat32Number*)(out[TotalOut]) = *(cmsFloat32Number*)ain;
- ain += SourceIncrements[TotalOut];
+ ain += SourceIncrements[3];
out[TotalOut] += DestIncrements[TotalOut];
}
}