summaryrefslogtreecommitdiff
path: root/plugins/fast_float/src/fast_float_sup.c
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/fast_float/src/fast_float_sup.c')
-rw-r--r--plugins/fast_float/src/fast_float_sup.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/plugins/fast_float/src/fast_float_sup.c b/plugins/fast_float/src/fast_float_sup.c
index a3362b4..2955525 100644
--- a/plugins/fast_float/src/fast_float_sup.c
+++ b/plugins/fast_float/src/fast_float_sup.c
@@ -22,7 +22,6 @@
#include "fast_float_internal.h"
-
// This is the main dispatcher
static
cmsBool Floating_Point_Transforms_Dispatcher(_cmsTransform2Fn* TransformFn,
@@ -39,6 +38,9 @@ cmsBool Floating_Point_Transforms_Dispatcher(_cmsTransform2Fn* TransformFn,
// Special flags for reversing are not supported
if (T_FLAVOR(*InputFormat) || T_FLAVOR(*OutputFormat)) return FALSE;
+ // Check consistency for alpha channel copy
+ if (*dwFlags & cmsFLAGS_COPY_ALPHA && (T_EXTRA(*InputFormat) != T_EXTRA(*OutputFormat))) return FALSE;
+
// Try to optimize as a set of curves plus a matrix plus a set of curves
if (OptimizeMatrixShaper15(TransformFn, UserData, FreeUserData, Lut, InputFormat, OutputFormat, dwFlags)) return TRUE;