Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mm2/Little-CMS.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLynx3d <151539+Lynx3d@users.noreply.github.com>2021-07-29 12:44:01 +0300
committerLynx3d <151539+Lynx3d@users.noreply.github.com>2021-07-29 12:44:01 +0300
commit83a7ba5584be3a5c526602005de0880feda23bcb (patch)
treeb389bf0709b2c62c9ce9d877fa636d360520c6e3 /plugins
parent076cf327b5f0368eb353e6a3d3996561511ab226 (diff)
Really fix alpha handling in fast float (hopefully...)
The alpha input pointers were missed in the first attempt. Also, the stride values were missing in FastEvaluateFloatGrayCurves and FastFloatGrayIdentity.
Diffstat (limited to 'plugins')
-rw-r--r--plugins/fast_float/src/fast_16_tethra.c1
-rw-r--r--plugins/fast_float/src/fast_8_tethra.c1
-rw-r--r--plugins/fast_float/src/fast_float_curves.c8
-rw-r--r--plugins/fast_float/src/fast_float_tethra.c1
4 files changed, 7 insertions, 4 deletions
diff --git a/plugins/fast_float/src/fast_16_tethra.c b/plugins/fast_float/src/fast_16_tethra.c
index d76c65a..846eaf6 100644
--- a/plugins/fast_float/src/fast_16_tethra.c
+++ b/plugins/fast_float/src/fast_16_tethra.c
@@ -293,6 +293,7 @@ void PerformanceEval16(struct _cmstransform_struct *CMMcargo,
{
res16 = *(const cmsUInt16Number*)ain;
TO_OUTPUT(out[OutChan], res16);
+ ain += SourceIncrements[TotalOut];
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 9a724a6..048b43e 100644
--- a/plugins/fast_float/src/fast_8_tethra.c
+++ b/plugins/fast_float/src/fast_8_tethra.c
@@ -253,6 +253,7 @@ void PerformanceEval8(struct _cmstransform_struct *CMMcargo,
if (ain) {
*out[TotalOut] = *ain;
+ ain += SourceIncrements[TotalOut];
out[TotalOut] += DestIncrements[TotalOut];
}
diff --git a/plugins/fast_float/src/fast_float_curves.c b/plugins/fast_float/src/fast_float_curves.c
index 2d598d2..b87e06f 100644
--- a/plugins/fast_float/src/fast_float_curves.c
+++ b/plugins/fast_float/src/fast_float_curves.c
@@ -261,8 +261,8 @@ static void FastEvaluateFloatGrayCurves(struct _cmstransform_struct* CMMcargo,
if (nalpha)
{
- ain = (const cmsUInt8Number*)Input + SourceStartingOrder[1];
- aout = (cmsUInt8Number*)Output + DestStartingOrder[1];
+ ain = (const cmsUInt8Number*)Input + SourceStartingOrder[1] + strideIn;
+ aout = (cmsUInt8Number*)Output + DestStartingOrder[1] + strideOut;
}
for (ii = 0; ii < PixelsPerLine; ii++) {
@@ -325,8 +325,8 @@ static void FastFloatGrayIdentity(struct _cmstransform_struct* CMMcargo,
if (nalpha)
{
- ain = (const cmsUInt8Number*)Input + SourceStartingOrder[1];
- aout = (cmsUInt8Number*)Output + DestStartingOrder[1];
+ ain = (const cmsUInt8Number*)Input + SourceStartingOrder[1] + strideIn;
+ aout = (cmsUInt8Number*)Output + DestStartingOrder[1] + strideOut;
}
diff --git a/plugins/fast_float/src/fast_float_tethra.c b/plugins/fast_float/src/fast_float_tethra.c
index 29ebde5..59b509f 100644
--- a/plugins/fast_float/src/fast_float_tethra.c
+++ b/plugins/fast_float/src/fast_float_tethra.c
@@ -212,6 +212,7 @@ void FloatCLUTEval(struct _cmstransform_struct* CMMcargo,
if (ain) {
*(cmsFloat32Number*)(out[TotalOut]) = *ain;
+ ain += SourceIncrements[TotalOut];
out[TotalOut] += DestIncrements[TotalOut];
}
}