diff --git a/meson.build b/meson.build index b5e417b..296c184 100644 --- a/meson.build +++ b/meson.build @@ -2,7 +2,7 @@ project('ICCConvert', ['c', 'cpp'], license: 'LGPL2.1+', default_options: ['buildtype=release', 'b_ndebug=if-release', 'c_std=c11', 'cpp_std=c++17', 'optimization=2'], meson_version: '>=0.51.0', - version: '6.0' + version: '6.1' ) sources = [ diff --git a/src/common.hpp b/src/common.hpp index a535f37..fab47ac 100644 --- a/src/common.hpp +++ b/src/common.hpp @@ -11,7 +11,7 @@ #include #define ICCC_PLUGIN_ID "yomiko.collection.iccconvert" -#define ICCC_PLUGIN_VERSION VS_MAKE_VERSION(6, 0) +#define ICCC_PLUGIN_VERSION VS_MAKE_VERSION(6, 1) #if defined (_WIN32) # define DETECTION_IMPLEMENTED 1 diff --git a/src/iccc.cc b/src/iccc.cc index 89e26dc..5f69200 100644 --- a/src/iccc.cc +++ b/src/iccc.cc @@ -5,10 +5,6 @@ #include #include -#ifndef TYPE_RGB_FLT_PLANAR -#define TYPE_RGB_FLT_PLANAR (FLOAT_SH(1)|COLORSPACE_SH(PT_RGB)|CHANNELS_SH(3)|BYTES_SH(4)|PLANAR_SH(1)) -#endif - constexpr double REC709_ALPHA = 1.09929682680944; constexpr double REC709_BETA = 0.018053968510807; @@ -388,7 +384,7 @@ void VS_CC icccCreate(const VSMap *in, VSMap *out, void *userData, VSCore *core, } else if (srcFormat == pfRGBS) { - d->inputDataType = TYPE_RGB_FLT_PLANAR; + d->inputDataType = TYPE_RGB_FLT | PLANAR_SH(1); d->outputDataType = d->inputDataType; } else @@ -453,7 +449,10 @@ void VS_CC icccCreate(const VSMap *in, VSMap *out, void *userData, VSCore *core, const char *intentString = vsapi->mapGetData(in, "intent", 0, &err); if (err || !intentString) - if (inputProfile) d->intent = cmsGetHeaderRenderingIntent(inputProfile); + { + if (inputProfile) + d->intent = cmsGetHeaderRenderingIntent(inputProfile); + } else { int itt = getIntent(intentString); @@ -577,7 +576,7 @@ void VS_CC iccpCreate(const VSMap *in, VSMap *out, void *userData, VSCore *core, } else if (srcFormat == pfRGBS) { - d->inputDataType = TYPE_RGB_FLT_PLANAR; + d->inputDataType = TYPE_RGB_FLT | PLANAR_SH(1); d->outputDataType = d->inputDataType; } else