![]() |
Oyranos
0.9.7
Oyranos is a full featured Color Management System
|
littleCMS CMM module for Oyranos More...
#include <lcms2.h>
#include <stdarg.h>
#include <stdlib.h>
#include "oyArray2d_s_.h"
#include "oyCMM_s.h"
#include "oyCMMapi4_s.h"
#include "oyCMMapi4_s_.h"
#include "oyCMMapi6_s_.h"
#include "oyCMMapi7_s.h"
#include "oyCMMapi7_s_.h"
#include "oyCMMapi10_s_.h"
#include "oyCMMui_s_.h"
#include "oyConnectorImaging_s_.h"
#include "oyImage_s.h"
#include "oyProfiles_s.h"
#include "oyStructList_s.h"
#include "oyranos_cmm.h"
#include "oyranos_config_internal.h"
#include "oyranos_generic.h"
#include "oyranos_helper.h"
#include "oyranos_i18n.h"
#include "oyranos_io.h"
#include "oyranos_image.h"
#include "oyranos_object_internal.h"
#include "oyranos_string.h"
#include <math.h>
#include <string.h>
#include "lcm2_profiler.c"
Macros | |
#define | l2cmsPROOF_LUT_GRID_RASTER 53 |
Functions | |
void | l2cmsErrorHandlerFunction (cmsContext ContextID, cmsUInt32Number ErrorCode, const char *ErrorText) |
int | l2cmsCMMMessageFuncSet (oyMessage_f l2cms_msg_func) |
l2cmsTransformWrap_s * | l2cmsTransformWrap_Set_ (cmsHTRANSFORM xform, icColorSpaceSignature color_in, icColorSpaceSignature color_out, oyPixel_t oy_pixel_layout_in, oyPixel_t oy_pixel_layout_out, oyPointer_s *oy) |
fill a l2cmsTransformWrap_s struct More... | |
int | l2cmsCMMTransform_GetWrap_ (oyPointer_s *cmm_ptr, l2cmsTransformWrap_s **s) |
convert to l2cms transform wrapper struct More... | |
int | l2cmsCMMDeleteTransformWrap (oyPointer *wrap) |
l2cmsProfileWrap_s * | l2cmsCMMProfile_GetWrap_ (oyPointer_s *cmm_ptr) |
convert to l2cms profile wrapper struct More... | |
int | l2cmsCMMProfileReleaseWrap (oyPointer *p) |
release a l2cms profile wrapper struct More... | |
int | l2cmsCMMCheckPointer (oyPointer_s *cmm_ptr, const char *resource) |
int | oyPixelToLcm2PixelLayout_ (oyPixel_t pixel_layout, icColorSpaceSignature color_space) |
char * | l2cmsFilterNode_GetText (oyFilterNode_s *node, oyNAME_e type OY_UNUSED, oyAlloc_f allocateFunc) |
implement oyCMMFilterNode_GetText_f() More... | |
char * | l2cmsFlagsToText (int flags) |
debugging helper More... | |
cmsHPROFILE | l2cmsGamutCheckAbstract (oyProfile_s *proof, cmsUInt32Number flags, int intent, int intent_proof, uint32_t icc_profile_flags) |
convert a proofing profile into a abstract one More... | |
oyPointer | l2cmsCMMColorConversion_ToMem_ (cmsHTRANSFORM *xform, oyOptions_s *opts, size_t *size, oyAlloc_f allocateFunc) |
cmsHPROFILE | l2cmsAddProfile (oyProfile_s *p) |
add a profile from Oyranos to the l2cms profile stack More... | |
l2cmsProfileWrap_s * | l2cmsAddProofProfile (oyProfile_s *proof, cmsUInt32Number flags, int intent, int intent_proof, uint32_t icc_profile_flags) |
add a abstract proofing profile to the l2cms profile stack More... | |
oyPointer | l2cmsFilterNode_CmmIccContextToMem (oyFilterNode_s *node, size_t *size, oyAlloc_f allocateFunc) |
implement oyCMMFilterNode_CreateContext_f() More... | |
int | l2cmsModuleData_Convert (oyPointer_s *data_in, oyPointer_s *data_out, oyFilterNode_s *node) |
Convert a ICC device link to LittleCMS 2 color transformThe function might be used to provide a module specific context. Implements oyModuleData_Convert_f. More... | |
int | l2cmsFilterPlug_CmmIccRun (oyFilterPlug_s *requestor_plug, oyPixelAccess_s *ticket) |
implement oyCMMFilterPlug_GetNext_f() More... | |
int | l2cmsCMMInit (oyStruct_s *filter OY_UNUSED) |
API requirement. More... | |
int | l2cmsCMMData_Open (oyStruct_s *data, oyPointer_s *oy) |
oyCMMProfileOpen_t implementation More... | |
cmsHTRANSFORM | l2cmsCMMConversionContextCreate_ (oyFilterNode_s *node, cmsHPROFILE *lps, int profiles_n, oyProfiles_s *simulation, int proof_n, int proof, oyPixel_t oy_pixel_layout_in, oyPixel_t oy_pixel_layout_out, oyOptions_s *opts, l2cmsTransformWrap_s **ltw, oyPointer_s *oy) |
create a CMM transform More... | |
int | l2cmsGetOptionsUI (oyCMMapiFilter_s *module OY_UNUSED, oyOptions_s *options, int flags, char **ui_text, oyAlloc_f allocateFunc) |
return XFORMS for matching options More... | |
oyImage_s * | lcm2ParseCGATS (const char *cgats) |
Parse a CGATS text. More... | |
int | l2cmsMOptions_Handle4 (oyOptions_s *options, const char *command, oyOptions_s **result) |
const char * | l2cmsInfoGetTextProfileC4 (const char *select, oyNAME_e type, oyStruct_s *context OY_UNUSED) |
oyProfile_s * | lcm2AbstractWhitePoint (double cie_a, double cie_b, uint32_t icc_profile_flags) |
create a White point correction profile More... | |
int | l2cmsMOptions_Handle3 (oyOptions_s *options, const char *command, oyOptions_s **result) |
const char * | l2cmsInfoGetTextProfileC3 (const char *select, oyNAME_e type, oyStruct_s *context OY_UNUSED) |
int | l2cmsMOptions_Handle2 (oyOptions_s *options, const char *command, oyOptions_s **result) |
const char * | l2cmsInfoGetTextProfileC2 (const char *select, oyNAME_e type, oyStruct_s *context OY_UNUSED) |
oyProfile_s * | l2cmsCreateICCMatrixProfile (float gamma, float rx, float ry, float gx, float gy, float bx, float by, float wx, float wy, int icc_profile_flags) |
create a profile from primaries, white point and one gamma value More... | |
int | l2cmsMOptions_Handle (oyOptions_s *options, const char *command, oyOptions_s **result) |
const char * | l2cmsInfoGetTextProfileC (const char *select, oyNAME_e type, oyStruct_s *context OY_UNUSED) |
const char * | l2cmsApi4UiGetText (const char *select, oyNAME_e type, oyStruct_s *context) |
const char * | l2cmsInfoGetText (const char *select, oyNAME_e type, oyStruct_s *context OY_UNUSED) |
Variables | |
oyCMMapi4_s_ | l2cms_api4_cmm |
lcms2 ICC CMM Context Setup and UI Node More... | |
oyCMMapi10_s_ | l2cms_api10_cmm4 |
Node for Parsing a CGATS text. More... | |
oyCMMapi10_s_ | l2cms_api10_cmm3 |
Node for Creating White Point Effect Profiles. More... | |
oyCMMapi10_s_ | l2cms_api10_cmm2 |
Node for Creating Proofing Effect Profiles. More... | |
oyCMMapi10_s_ | l2cms_api10_cmm |
Node for Creating simple Color Matrix Profiles. More... | |
oyCMMapi6_s_ | l2cms_api6_cmm |
Node for Converting a Device Link into a lcms2 CMM Context. More... | |
oyCMMapi7_s_ | l2cms_api7_cmm |
lcms2 ICC CMM Pixel Processor Engine Node More... | |
oyCMMui_s_ | l2cms_api4_ui |
lcms2 ICC CMM Node UI More... | |
oyCMM_s | lcm2_cmm_module |
l2cms Module Infos More... | |
littleCMS CMM module for Oyranos
Oyranos is an open source Color Management System
#define l2cmsPROOF_LUT_GRID_RASTER 53 |
The proofing LUTs grid size may improove the sharpness of out of color marking, but at the prise of lost speed and increased memory consumption. 53 is the grid size used internally in l2cms' gamut marking code.
Referenced by l2cmsCMMConversionContextCreate_(), and l2cmsGamutCheckAbstract().
cmsHPROFILE l2cmsAddProfile | ( | oyProfile_s * | p | ) |
add a profile from Oyranos to the l2cms profile stack
Function l2cmsAddProfile Look in the Oyranos cache for a CMM internal representation
References l2cmsCMMData_Open(), l2cmsCMMProfile_GetWrap_(), oy_debug, oyCONNECTOR_EVENT_INCOMPATIBLE_OPTION, oyNAME_NAME, oyNAME_NICK, oyNAME_PATTERN, oyOBJECT_PROFILE_S, oyOBJECT_PROFILES_S, oyValueUInt32(), and oyProfile_s::type_.
Referenced by l2cmsFilterNode_CmmIccContextToMem(), and l2cmsGamutCheckAbstract().
l2cmsProfileWrap_s * l2cmsAddProofProfile | ( | oyProfile_s * | proof, |
cmsUInt32Number | flags, | ||
int | intent, | ||
int | intent_proof, | ||
uint32_t | icc_profile_flags | ||
) |
add a abstract proofing profile to the l2cms profile stack
Function l2cmsAddProofProfile Look in the Oyranos cache for a CMM internal representation or generate a new abstract profile containing the proofing profiles changes. This can be a proofing color space simulation or out of gamut marking.
References l2cmsCMMProfile_GetWrap_(), l2cmsCMMProfileReleaseWrap(), l2cmsErrorHandlerFunction(), l2cmsGamutCheckAbstract(), lcm2WriteProfileToMem(), oyProfile_s::oy_, oy_debug, oyNAME_NAME, oyNAME_NICK, oyObject_GetName(), oyOBJECT_PROFILE_S, and oyProfile_s::type_.
Referenced by l2cmsCMMConversionContextCreate_(), and l2cmsMOptions_Handle2().
int l2cmsCMMCheckPointer | ( | oyPointer_s * | cmm_ptr, |
const char * | resource | ||
) |
Function l2cmsCMMCheckPointer
Referenced by l2cmsCMMProfile_GetWrap_(), and l2cmsCMMTransform_GetWrap_().
oyPointer l2cmsCMMColorConversion_ToMem_ | ( | cmsHTRANSFORM * | xform, |
oyOptions_s * | opts, | ||
size_t * | size, | ||
oyAlloc_f | allocateFunc | ||
) |
Function l2cmsCMMColorConversion_ToMem_
convert a l2cms color conversion context to a device link
References lcm2WriteProfileToMem(), OY_TYPE_STD, oyDOUBLE, oyFilterRegistrationMatch(), oyFLOAT, oyHALF, oyOBJECT_CMM_API4_S, oyOBJECT_CONNECTOR_IMAGING_S, oyUINT16, and oyUINT8.
Referenced by l2cmsFilterNode_CmmIccContextToMem().
cmsHTRANSFORM l2cmsCMMConversionContextCreate_ | ( | oyFilterNode_s * | node, |
cmsHPROFILE * | lps, | ||
int | profiles_n, | ||
oyProfiles_s * | simulation, | ||
int | proof_n, | ||
int | proof, | ||
oyPixel_t | oy_pixel_layout_in, | ||
oyPixel_t | oy_pixel_layout_out, | ||
oyOptions_s * | opts, | ||
l2cmsTransformWrap_s ** | ltw, | ||
oyPointer_s * | oy | ||
) |
create a CMM transform
Function l2cmsCMMConversionContextCreate_
References l2cmsAddProofProfile(), l2cmsFlagsToText(), l2cmsPROOF_LUT_GRID_RASTER, l2cmsTransformWrap_Set_(), oy_debug, oyICCColorSpaceGetName(), oyICCDeviceClassDescription(), and oyPixelToLcm2PixelLayout_().
Referenced by l2cmsFilterNode_CmmIccContextToMem(), and l2cmsModuleData_Convert().
int l2cmsCMMData_Open | ( | oyStruct_s * | data, |
oyPointer_s * | oy | ||
) |
oyCMMProfileOpen_t implementation
l2cmsCMMDataOpen()
References l2cmsCMMProfileReleaseWrap(), l2cmsErrorHandlerFunction(), oy_debug, oyOBJECT_PROFILE_S, and oyStruct_s::type_.
Referenced by l2cmsAddProfile().
int l2cmsCMMDeleteTransformWrap | ( | oyPointer * | wrap | ) |
Function l2cmsCMMDeleteTransformWrap
Referenced by l2cmsTransformWrap_Set_().
int l2cmsCMMInit | ( | oyStruct_s *filter | OY_UNUSED | ) |
API requirement.
Function l2cmsCMMInit
References l2cmsErrorHandlerFunction().
int l2cmsCMMMessageFuncSet | ( | oyMessage_f | message_func | ) |
Function l2cmsCMMMessageFuncSet
References lcm2MessageFuncSet(), OY_DOMAIN_INTERNAL, OY_TOP_SHARED, and OY_TYPE_STD.
l2cmsProfileWrap_s * l2cmsCMMProfile_GetWrap_ | ( | oyPointer_s * | cmm_ptr | ) |
convert to l2cms profile wrapper struct
Function l2cmsCMMProfile_GetWrap_
References l2cmsCMMCheckPointer(), and oy_debug.
Referenced by l2cmsAddProfile(), and l2cmsAddProofProfile().
int l2cmsCMMProfileReleaseWrap | ( | oyPointer * | p | ) |
release a l2cms profile wrapper struct
Function l2cmsCMMProfileReleaseWrap
Referenced by l2cmsAddProofProfile(), and l2cmsCMMData_Open().
int l2cmsCMMTransform_GetWrap_ | ( | oyPointer_s * | cmm_ptr, |
l2cmsTransformWrap_s ** | s | ||
) |
convert to l2cms transform wrapper struct
Function l2cmsCMMTransform_GetWrap_
References l2cmsCMMCheckPointer().
Referenced by l2cmsFilterPlug_CmmIccRun().
void l2cmsErrorHandlerFunction | ( | cmsContext | ContextID, |
cmsUInt32Number ErrorCode | OY_UNUSED, | ||
const char * | ErrorText | ||
) |
Function l2cmsErrorHandlerFunction
Referenced by l2cmsAddProofProfile(), l2cmsCMMData_Open(), l2cmsCMMInit(), l2cmsGamutCheckAbstract(), and l2cmsModuleData_Convert().
oyPointer l2cmsFilterNode_CmmIccContextToMem | ( | oyFilterNode_s * | node, |
size_t * | size, | ||
oyAlloc_f | allocateFunc | ||
) |
implement oyCMMFilterNode_CreateContext_f()
l2cmsFilterNode_CmmIccContextToMem()
References l2cmsAddProfile(), l2cmsCMMColorConversion_ToMem_(), l2cmsCMMConversionContextCreate_(), l2cmsFilterNode_GetText(), oy_debug, oyCONNECTOR_EVENT_INCOMPATIBLE_DATA, oyDataTypeGetSize(), oyDataTypeToText(), oyICCColorSpaceGetName(), oyICCDeviceClassDescription(), oyLAYOUT, oyNAME_DESCRIPTION, oyNAME_NAME, oyNAME_NICK, oyNAME_PATTERN, oyOBJECT_IMAGE_S, oyOBJECT_PROFILE_S, oyPOFF_X, oySIGNATURE_CLASS, oySIGNATURE_COLOR_SPACE, oySIGNATURE_PCS, oyStruct_GetAllocator(), oyToByteswap_m, oyToChannels_m, oyToColorOffset_m, oyToDataType_m, oyToFlavor_m, oyToSwapColorChannels_m, oyValueUInt32(), and oyImage_s::type_.
char * l2cmsFilterNode_GetText | ( | oyFilterNode_s * | node, |
oyNAME_e type | OY_UNUSED, | ||
oyAlloc_f | allocateFunc | ||
) |
implement oyCMMFilterNode_GetText_f()
Function l2cmsFilterNode_GetText
References OY_SELECT_COMMON, OY_TYPE_STD, oyBOOLEAN_UNION, oyNAME_NAME, oyNAME_PATTERN, oyOBJECT_PROFILE_S, and oyOPTIONSOURCE_FILTER.
Referenced by l2cmsFilterNode_CmmIccContextToMem(), l2cmsFilterPlug_CmmIccRun(), and l2cmsModuleData_Convert().
int l2cmsFilterPlug_CmmIccRun | ( | oyFilterPlug_s * | requestor_plug, |
oyPixelAccess_s * | ticket | ||
) |
implement oyCMMFilterPlug_GetNext_f()
Function l2cmsFilterPlug_CmmIccRun
References l2cmsCMMTransform_GetWrap_(), l2cmsFilterNode_GetText(), oyPixelAccess_s::oy_, OY_CREATE_NEW, oy_debug, OY_TYPE_STD, oyCONNECTOR_EVENT_INCOMPATIBLE_CONTEXT, oyCONNECTOR_EVENT_INCOMPATIBLE_DATA, oyCONNECTOR_EVENT_OK, oyDataTypeGetSize(), oyDOUBLE, oyFLOAT, oyHALF, oyLAYOUT, oyNAME_NICK, oyToChannels_m, oyToDataType_m, oyUINT16, and oyUINT8.
char * l2cmsFlagsToText | ( | int | flags | ) |
debugging helper
Function l2cmsFlagsToText
Referenced by l2cmsCMMConversionContextCreate_(), and l2cmsTransformWrap_Set_().
int l2cmsGetOptionsUI | ( | oyCMMapiFilter_s *module | OY_UNUSED, |
oyOptions_s * | options, | ||
int | flags, | ||
char ** | ui_text, | ||
oyAlloc_f | allocateFunc | ||
) |
return XFORMS for matching options
Function l2cmsGetOptionsUI
References OY_DOMAIN_INTERNAL, OY_TOP_SHARED, and OY_TYPE_STD.
const char* l2cmsInfoGetText | ( | const char * | select, |
oyNAME_e | type, | ||
oyStruct_s *context | OY_UNUSED | ||
) |
This function implements oyCMMinfoGetText_f.
References oyNAME_NAME, oyNAME_NICK, and oyOBJECT_ICON_S.
Referenced by l2cmsApi4UiGetText().
l2cmsTransformWrap_s * l2cmsTransformWrap_Set_ | ( | cmsHTRANSFORM | xform, |
icColorSpaceSignature | color_in, | ||
icColorSpaceSignature | color_out, | ||
oyPixel_t | oy_pixel_layout_in, | ||
oyPixel_t | oy_pixel_layout_out, | ||
oyPointer_s * | oy | ||
) |
fill a l2cmsTransformWrap_s struct
Function l2cmsTransformWrap_Set_
References l2cmsCMMDeleteTransformWrap(), l2cmsFlagsToText(), and oy_debug.
Referenced by l2cmsCMMConversionContextCreate_().
int oyPixelToLcm2PixelLayout_ | ( | oyPixel_t | pixel_layout, |
icColorSpaceSignature | color_space | ||
) |
Function oyPixelToLcm2PixelLayout_
References oyDOUBLE, oyFLOAT, oyHALF, oyToByteswap_m, oyToChannels_m, oyToColorOffset_m, oyToDataType_m, oyToFlavor_m, oyToPlanar_m, oyToSwapColorChannels_m, oyUINT16, and oyUINT8.
Referenced by l2cmsCMMConversionContextCreate_().
oyCMM_s lcm2_cmm_module |
l2cms Module Infos
lcm2_cmm_module