#ifndef _FS_COMMON_C_H_
#define _FS_COMMON_C_H_

#ifdef __cplusplus
extern "C" {
#endif

#include "fx_stream_c.h"

typedef struct _FSDocEventCallback FSDocEventCallback;

typedef struct _FSFontMapperCallback FSFontMapperCallback;

typedef struct _FSIconProviderCallback FSIconProviderCallback;

typedef struct _FSActionCallback FSActionCallback;

typedef struct _FSSignatureCallback FSSignatureCallback;

typedef struct _FSSecurityCallback FSSecurityCallback;

typedef struct _FSAppProviderCallback FSAppProviderCallback;

typedef struct _FSTimeStampCallback FSTimeStampCallback;

FSErrorCode FSDK_Rect_IsAdjacent(const FSRectF rect1, const FSRectF rect2, float alignmentTolerance, float distanceTolerance, FS_INT32 direction, FS_BOOL* return_value);

FSErrorCode FSDK_Matrix_Translate(FSMatrix* matrix, float offsetX, float offsetY);

FSErrorCode FSDK_Matrix_Scale(FSMatrix* matrix, float scaleX, float scaleY);

FSErrorCode FSDK_Matrix_Rotate(FSMatrix* matrix, float angle);

FSErrorCode FSDK_Matrix_Shear(FSMatrix* matrix, float alpha, float beta);

FSErrorCode FSDK_Matrix_SetReverse(const FSMatrix reverseMatrix, FSMatrix* dstMatrix);

FSErrorCode FSDK_Matrix_Concat(const FSMatrix concat_matrix, FSMatrix* dst_matrix);

FSErrorCode FSDK_Matrix_TransformPoint(const FSMatrix matrix, FS_INT32* x, FS_INT32* y);

FSErrorCode FSDK_Matrix_TransformPointF(const FSMatrix matrix, float* x, float* y);

FSErrorCode FSDK_Matrix_TransformRect(const FSMatrix matrix, FSRectF* rect);

FSErrorCode FSDK_Matrix_TransformRectF(const FSMatrix matrix, FSRectF* rect);

FSErrorCode FSDK_BStr_Init(FS_BSTR* bstr);

FSErrorCode FSDK_BStr_SetLength(FS_BSTR* bstr, FS_UINT32 length);

FSErrorCode FSDK_BStr_Set(FS_BSTR* bstr, const char* str, FS_UINT32 length);

FSErrorCode FSDK_BStr_Clear(FS_BSTR* bstr);

FSErrorCode FSDK_WStr_Init(FS_WSTR* wstr);

FSErrorCode FSDK_WStr_SetLength(FS_WSTR* wstr, FS_UINT32 length);

FSErrorCode FSDK_WStr_Set(FS_WSTR* wstr, const wchar_t* str, FS_UINT32 length);

FSErrorCode FSDK_WStr_Clear(FS_WSTR* wstr);

FSErrorCode FSDK_WStr_UTF8Encode(FS_WSTR* src_wstr, FS_BSTR* dst_bstr);

FSErrorCode FSDK_WStr_UTF16LEEncode(FS_WSTR* src_wstr, FS_BSTR* dst_bstr);

FSErrorCode FSDK_BStr_UTF8Decode(FS_BSTR* src_wstr, FS_WSTR* dst_bstr);


typedef enum _FSRotation {
e_FSRotation0 = 0,
e_FSRotation90 = 1,
e_FSRotation180 = 2,
e_FSRotation270 = 3,
e_FSRotationRotationUnknown = 4,
}FSRotation;



typedef enum _FSRotationPointOptions {
e_FSRotationPointCenter = 0,
e_FSRotationPointLeftTop = 1,
e_FSRotationPointRightTop = 2,
e_FSRotationPointLeftBottom  = 3,
e_FSRotationPointRightBottom  = 4,
}FSRotationPointOptions;



typedef enum _FSState {
e_FSError = 0,
e_FSToBeContinued = 1,
e_FSFinished = 2,
}FSState;



typedef enum _FSFontTypes {
e_FSFontTypeType1 = 1,
e_FSFontTypeTrueType = 2,
e_FSFontTypeType3 = 3,
e_FSFontTypeCIDFont = 4,
}FSFontTypes;



typedef enum _FSStyles {
e_FSStyleFixedPitch = 0x0001,
e_FSStyleSerif = 0x0002,
e_FSStyleSymbolic = 0x0004,
e_FSStyleScript = 0x0008,
e_FSStyleNonSymbolic = 0x0020,
e_FSStyleItalic = 0x0040,
e_FSStyleAllCap = 0x10000,
e_FSStylesSmallCap = 0x20000,
e_FSStylesBold = 0x40000,
}FSStyles;



typedef enum _FSCharset {
e_FSCharsetANSI = 0,
e_FSCharsetDefault = 1,
e_FSCharsetSymbol = 2,
e_FSCharsetShift_JIS = 128,
e_FSCharsetHangeul = 129,
e_FSCharsetGB2312 = 134,
e_FSCharsetChineseBig5 = 136,
e_FSCharsetThai = 222,
e_FSCharsetEastEurope = 238,
e_FSCharsetRussian = 204,
e_FSCharsetGreek = 161,
e_FSCharsetTurkish = 162,
e_FSCharsetHebrew = 177,
e_FSCharsetArabic = 178,
e_FSCharsetBaltic = 186,
}FSCharset;



typedef enum _FSCIDCharset {
e_FSCIDCharsetCIDCharsetUnknown = 0,
e_FSCIDCharsetGB1 = 1,
e_FSCIDCharsetCNS1 = 2,
e_FSCIDCharsetJAPAN1 = 3,
e_FSCIDCharsetKOREA1 = 4,
e_FSCIDCharsetUNICODE = 5,
}FSCIDCharset;



typedef enum _FSStandardID {
e_FSStdIDCourier = 0,
e_FSStdIDCourierB = 1,
e_FSStdIDCourierBI = 2,
e_FSStdIDCourierI = 3,
e_FSStdIDHelvetica = 4,
e_FSStdIDHelveticaB = 5,
e_FSStdIDHelveticaBI = 6,
e_FSStdIDHelveticaI = 7,
e_FSStdIDTimes = 8,
e_FSStdIDTimesB = 9,
e_FSStdIDTimesBI = 10,
e_FSStdIDTimesI = 11,
e_FSStdIDSymbol = 12,
e_FSStdIDZapfDingbats = 13,
}FSStandardID;



typedef enum _FSPointType {
e_FSTypeMoveTo = 1,
e_FSTypeLineTo = 2,
e_FSTypeLineToCloseFigure  = 3,
e_FSTypeBezierTo = 4,
e_FSTypeBezierToCloseFigure = 5,
}FSPointType;



typedef enum _FSLineJoinStyle {
e_FSLineJoinMiter = 0,
e_FSLineJoinRound = 1,
e_FSLineJoinBevel = 2,
}FSLineJoinStyle;



typedef enum _FSLineCapStyle {
e_FSLineCapButt  = 0,
e_FSLineCapRound= 1,
e_FSLineCapSquare = 2,
}FSLineCapStyle;



typedef enum _FSAlignment {
e_FSAlignmentLeft = 0,
e_FSAlignmentCenter = 1,
e_FSAlignmentRight = 2,
}FSAlignment;



typedef enum _FSFillMode {
e_FSFillModeNone  = 0,
e_FSFillModeAlternate= 1,
e_FSFillModeWinding = 2,
}FSFillMode;



typedef enum _FSPosition {
e_FSPosTopLeft = 0,
e_FSPosTopCenter = 1,
e_FSPosTopRight = 2,
e_FSPosCenterLeft = 3,
e_FSPosCenter = 4,
e_FSPosCenterRight = 5,
e_FSPosBottomLeft = 6,
e_FSPosBottomCenter = 7,
e_FSPosBottomRight = 8,
}FSPosition;



typedef enum _FSModuleName {
e_FSModuleNameConnectedPDF = 1,
e_FSModuleNameXFA = 2,
e_FSModuleNameRedaction = 3,
e_FSModuleNameRMS = 4,
e_FSModuleNameOCR = 5,
e_FSModuleNameComparison = 6,
e_FSModuleNameCompliance = 7,
e_FSModuleNameOptimizer = 8,
e_FSModuleNameConversion = 9,
e_FSModuleNameLayoutRecognition = 10,
e_FSModuleNameAccessibility = 11,
e_FSModuleNameTableMaker = 12,
e_FSModuleNameDWG2PDF = 13,
e_FSModuleNameAdvEdit = 14,
e_FSModuleNamePDF2Office = 15,
e_FSModuleName3D = 16,
e_FSModuleNameOFD = 17,
e_FSModuleNameOffice2PDF = 18,
e_FSModuleNamePrint2PDF = 19,
}FSModuleName;



typedef enum _FSColorSpaceType {
e_FSColorSpaceInvalid  = 0,
e_FSColorSpaceDeviceGray = 1,
e_FSColorSpaceDeviceRGB = 2,
e_FSColorSpaceDeviceCMYK = 3,
e_FSColorSpaceCalGray = 4,
e_FSColorSpaceCalRGB = 5,
e_FSColorSpaceLab = 6,
e_FSColorSpaceICCBased = 7,
e_FSColorSpaceSeparation = 8,
e_FSColorSpaceDeviceN = 9,
e_FSColorSpaceIndexed = 10,
e_FSColorSpacePattern = 11,
e_FSColorSpaceICCBasedDeviceGray = 12,
e_FSColorSpaceICCBasedDeviceRGB = 13,
e_FSColorSpaceICCBasedDeviceCMYK = 14,
}FSColorSpaceType;



typedef enum _FSLocaleID {
e_FSLocaleIDUnspecified = 0,
e_FSLocaleIDHongKong = 1,
e_FSLocaleIDTaiwan = 2,
e_FSLocaleIDNetherlands = 3,
e_FSLocaleIDFrance = 4,
e_FSLocaleIDGermany = 5,
e_FSLocaleIDItaly = 6,
e_FSLocaleIDKorea = 7,
e_FSLocaleIDJapan = 8,
}FSLocaleID;



typedef enum _FSFileFormatType {
e_FSFileFormatTypeFDF = 0,
e_FSFileFormatTypeXFDF = 1,
e_FSFileFormatTypeHTML = 2,
e_FSFileFormatTypeXDP = 3,
e_FSFileFormatTypeXML = 4,
e_FSFileFormatTypeXFD = 5,
e_FSFileFormatTypePDF = 6,
e_FSFileFormatTypeTXT = 7,
}FSFileFormatType;


FSErrorCode FSDK_Codec_Base64Encode(const void* data_buffer, size_t length, FS_BSTR* return_value);
FSErrorCode FSDK_Codec_Base64Decode(const void* encoded_data_buffer, size_t length, FS_BSTR* return_value);
FSErrorCode FSDK_Codec_FlateCompress(const void* data_buffer, size_t length, FS_BSTR* return_value);
FSErrorCode FSDK_Codec_FlateDecompress(const void* compressed_data_buffer, size_t length, FS_BSTR* return_value);
typedef struct _FSNotifierCallback {
  void* user_data;
  void (*Release)(void* user_data);
  void (*OnOutOfMemory)(void* user_data);
  
}FSNotifierCallback;

FSErrorCode FSDK_Progressive_Release(FS_PROGRESSIVE_HANDLE progressive_handle);
FSErrorCode FSDK_Progressive_Continue(FS_PROGRESSIVE_HANDLE progressive_handle, FSState* return_value);
FSErrorCode FSDK_Progressive_GetRateOfProgress(FS_PROGRESSIVE_HANDLE progressive_handle, int* return_value);
typedef struct _FSRenderConfig {
  int graphics_objs_count_in_one_step;
}FSRenderConfig;

FSErrorCode FSDK_Library_Initialize(const char* sn, const char* key);
FSErrorCode FSDK_Library_Initialize0(const char* sn, const char* key, FS_BOOL is_optimize_memory, FS_BOOL enable_js_xfa_threadsafety);
FSErrorCode FSDK_Library_Reinitialize();
FSErrorCode FSDK_Library_Release();
FSErrorCode FSDK_Library_HasModuleLicenseRight( FSModuleName module_name, FS_BOOL* return_value);
FSErrorCode FSDK_Library_GetVersion(FS_BSTR* return_value);
FSErrorCode FSDK_Library_SetCacheSize(FS_UINT32 size, FS_BOOL* return_value);
FSErrorCode FSDK_Library_EnableJavaScript(FS_BOOL enable_javascript, FS_BOOL* return_value);
FSErrorCode FSDK_Library_SetAnnotIconProviderCallback( FSIconProviderCallback* annot_icon_provider, FS_BOOL* return_value);
FSErrorCode FSDK_Library_SetNotifierCallback(FSNotifierCallback* notifier, FS_BOOL* return_value);
FSErrorCode FSDK_Library_SetActionCallback(FSActionCallback* action_callback, FS_BOOL* return_value);
FSErrorCode FSDK_Library_SetDocEventCallback(FSDocEventCallback* callback, FS_BOOL* return_value);
FSErrorCode FSDK_Library_RegisterSignatureCallback(const char* filter, const char* sub_filter,
                                        FSSignatureCallback* signature_callback, FS_BOOL* return_value);
FSErrorCode FSDK_Library_UnregisterSignatureCallback(const char* filter, const char* sub_filter);
FSErrorCode FSDK_Library_RegisterSecurityCallback(const char* filter, void* callback, FS_BOOL* return_value);
FSErrorCode FSDK_Library_UnregisterSecurityCallback(const char* filter, FS_BOOL* return_value);
FSErrorCode FSDK_Library_SetTimeStampCallback( FSTimeStampCallback* timestamp_callback, FS_BOOL* return_value);
FSErrorCode FSDK_Library_RegisterXFAAppProviderCallback( FSAppProviderCallback* callback);
FSErrorCode FSDK_Library_SetRenderTextGamma(float gamma);
FSErrorCode FSDK_Library_SetLogFile(const wchar_t* log_file_path);
FSErrorCode FSDK_Library_SetLogFile0( FSStreamCallback* log_file);
FSErrorCode FSDK_Library_FlushLog();
FSErrorCode FSDK_Library_SetFontMapperCallback(FSFontMapperCallback* callback, FS_BOOL* return_value);
FSErrorCode FSDK_Library_SetDefaultICCProfilesPath(const wchar_t* icc_profile_folder_path);
FSErrorCode FSDK_Library_GetRenderConfig(FSRenderConfig* return_value);
FSErrorCode FSDK_Library_SetRenderConfig(const FSRenderConfig render_config);
FSErrorCode FSDK_Library_EnableThreadSafety(FS_BOOL is_enable_thread_safety);
FSErrorCode FSDK_Library_InitializeOFDEngine(const char* ofd_library_path);
FSErrorCode FSDK_Library_ReleaseOFDEngine();
FSErrorCode FSDK_Library_ExecuteJavaScript(const wchar_t* java_script, FS_WSTR* return_value);
FSErrorCode FSDK_Library_AddExternalFontPath(const wchar_t* font_path, FS_BOOL* return_value);
FSErrorCode FSDK_Library_MatchExternalFontsOnly(FS_BOOL only_match);
typedef struct _FSGraphState {
  float line_width;
  FSLineJoinStyle line_join;
  float miter_limit;
  FSLineCapStyle line_cap;
  float dash_phase;
  float* dash_array;
  FS_UINT32 array_length_dashes;
}FSGraphState;

typedef struct _FSDocEventCallback {
  void* user_data;
  void (*Release)(void* user_data);
  void (*OnDocWillOpen)(void* user_data);
  void (*OnDocOpened)(void* user_data, const FS_PDFDOC_HANDLE document, FSErrorCode error_code);
  void (*OnDocWillDestroy)(void* user_data, const FS_PDFDOC_HANDLE document);
  void (*OnDocWillSave)(void* user_data, const FS_PDFDOC_HANDLE document);
  void (*OnDocSaved)(void* user_data, const FS_PDFDOC_HANDLE document, FSErrorCode error_code);
  
}FSDocEventCallback;


typedef enum _FSFilter {
e_FSAll = 0,
e_FSEven = 1,
e_FSOdd = 2,
}FSFilter;


FSErrorCode FSDK_Range_Create(FS_RANGE_HANDLE* range_return_value);
FSErrorCode FSDK_Range_Create0(int index, FS_RANGE_HANDLE* range_return_value);
FSErrorCode FSDK_Range_Create1(int start_index, int end_index, FSFilter filter, FS_RANGE_HANDLE* range_return_value);
FSErrorCode FSDK_Range_Release(FS_RANGE_HANDLE range_handle);
FSErrorCode FSDK_Range_IsEmpty(FS_RANGE_HANDLE range_handle, FS_BOOL* return_value);
FSErrorCode FSDK_Range_AddSingle(FS_RANGE_HANDLE range_handle,  int index );
FSErrorCode FSDK_Range_AddSegment(FS_RANGE_HANDLE range_handle,  int start_index, int end_index, FSFilter filter);
FSErrorCode FSDK_Range_GetSegmentCount(FS_RANGE_HANDLE range_handle, int* return_value);
FSErrorCode FSDK_Range_GetSegmentStart(FS_RANGE_HANDLE range_handle, int segment_index, int* return_value);
FSErrorCode FSDK_Range_GetSegmentEnd(FS_RANGE_HANDLE range_handle, int segment_index, int* return_value);
FSErrorCode FSDK_Range_RemoveAll(FS_RANGE_HANDLE range_handle);
FSErrorCode FSDK_Font_Create(const wchar_t* name, FS_UINT32 styles, FSCharset charset, int weight, FS_FONT_HANDLE* font_return_value);
FSErrorCode FSDK_Font_Create0(FSStandardID font_id, FS_FONT_HANDLE* font_return_value);
FSErrorCode FSDK_Font_Create1(const wchar_t* font_file_path, int face_index, FSCharset charset, FS_FONT_HANDLE* font_return_value);
FSErrorCode FSDK_Font_Create2( FSStreamCallback* stream, FS_FONT_HANDLE* font_return_value);
FSErrorCode FSDK_Font_IsEmpty(FS_FONT_HANDLE font_handle, FS_BOOL* return_value);
FSErrorCode FSDK_Font_Release(FS_FONT_HANDLE font_handle);
FSErrorCode FSDK_Font_GetName(FS_FONT_HANDLE font_handle, FS_WSTR* return_value);
FSErrorCode FSDK_Font_GetFamilyName(FS_FONT_HANDLE font_handle, FS_BSTR* return_value);
FSErrorCode FSDK_Font_IsBold(FS_FONT_HANDLE font_handle, FS_BOOL* return_value);
FSErrorCode FSDK_Font_IsItalic(FS_FONT_HANDLE font_handle, FS_BOOL* return_value);
FSErrorCode FSDK_Font_IsEmbedded(FS_FONT_HANDLE font_handle, const FS_PDFDOC_HANDLE document, FS_BOOL* return_value);
FSErrorCode FSDK_Font_IsSupportEmbedded(FS_FONT_HANDLE font_handle, const FS_PDFDOC_HANDLE document, FS_BOOL* return_value);
FSErrorCode FSDK_Font_Embed(FS_FONT_HANDLE font_handle,  FS_PDFDOC_HANDLE document, FS_BOOL is_add_all_unicodes, FS_FONT_HANDLE* return_value);
FSErrorCode FSDK_Font_AddUnicodes(FS_FONT_HANDLE font_handle, const FS_PDFDOC_HANDLE document, const FS_UINT32* uint32array, FS_UINT32 array_length_unicode_array, FS_UINT32* return_unicodearray, FS_UINT32* return_array_length);
FSErrorCode FSDK_Font_GetAscent(FS_FONT_HANDLE font_handle, int* return_value);
FSErrorCode FSDK_Font_GetDescent(FS_FONT_HANDLE font_handle, int* return_value);
FSErrorCode FSDK_Font_GetCharBBox(FS_FONT_HANDLE font_handle, FS_UINT32 unicode, FSRectI* return_value);
FSErrorCode FSDK_Font_GetCharWidth(FS_FONT_HANDLE font_handle, FS_UINT32 unicode, float* return_value);
FSErrorCode FSDK_Font_GetCharBBox0(FS_FONT_HANDLE font_handle,  FS_UINT32 unicode,const FS_PDFDOC_HANDLE document, FSRectI* return_value);
FSErrorCode FSDK_Font_GetCharWidth0(FS_FONT_HANDLE font_handle,  FS_UINT32 unicode,const FS_PDFDOC_HANDLE document, float* return_value);
FSErrorCode FSDK_Font_GetStyles(FS_FONT_HANDLE font_handle, const FS_PDFDOC_HANDLE document, FS_UINT32* return_value);
FSErrorCode FSDK_Font_GetCIDCharset(FS_FONT_HANDLE font_handle, const FS_PDFDOC_HANDLE document, FSCIDCharset* return_value);
FSErrorCode FSDK_Font_IsStandardFont(FS_FONT_HANDLE font_handle, const FS_PDFDOC_HANDLE document, FS_BOOL* return_value);
FSErrorCode FSDK_Font_GetStandard14Font(FS_FONT_HANDLE font_handle, const FS_PDFDOC_HANDLE document, FSStandardID* return_value);
FSErrorCode FSDK_Font_GetFontType(FS_FONT_HANDLE font_handle, const FS_PDFDOC_HANDLE document, FSFontTypes* return_value);
FSErrorCode FSDK_Font_GetBaseFontName(FS_FONT_HANDLE font_handle, const FS_PDFDOC_HANDLE document, FS_BSTR* return_value);
FSErrorCode FSDK_Font_IsVertWriting(FS_FONT_HANDLE font_handle, const FS_PDFDOC_HANDLE document, FS_BOOL* return_value);
FSErrorCode FSDK_Font_GetEncoding(FS_FONT_HANDLE font_handle, const FS_PDFDOC_HANDLE document, FS_BSTR* return_value);
FSErrorCode FSDK_Font_SetEncoding(FS_FONT_HANDLE font_handle, const FS_PDFDOC_HANDLE document, const char* value, FS_BOOL* return_value);
FSErrorCode FSDK_Font_IsCharSupported(FS_FONT_HANDLE font_handle,  FS_UINT32 unicode, const FS_PDFDOC_HANDLE document, FS_BOOL* return_value);
typedef struct _FSFontMapResult {
  FSReaderCallback* file_read;
  int face_index;
}FSFontMapResult;

typedef struct _FSFontMapperCallback {
  void* user_data;
  void (*Release)(void* user_data);
  FSFontMapResult (*MapFont)(void* user_data, const char* font_name, FS_BOOL is_truetype, FS_UINT32 styles,
                                int weight, int italic_angle, FSCharset charset);
  void (*MapFont0)(void* user_data, const char* font_family_name, FSCharset charset,
                              FS_UINT32 styles, int weight, int italic_angle, FS_BSTR* return_stringarray, FS_UINT32* return_stringarray_length);
  
}FSFontMapperCallback;

FSErrorCode FSDK_Path_Create(FS_PATH_HANDLE* path_return_value);
FSErrorCode FSDK_Path_Release(FS_PATH_HANDLE path_handle);
FSErrorCode FSDK_Path_IsEmpty(FS_PATH_HANDLE path_handle, FS_BOOL* return_value);
FSErrorCode FSDK_Path_GetPointCount(FS_PATH_HANDLE path_handle, int* return_value);
FSErrorCode FSDK_Path_GetPoint(FS_PATH_HANDLE path_handle, int index, FSPointF* return_value);
FSErrorCode FSDK_Path_GetPointType(FS_PATH_HANDLE path_handle, int index, FSPointType* return_value);
FSErrorCode FSDK_Path_SetPoint(FS_PATH_HANDLE path_handle, int index, const FSPointF point, FSPointType type, FS_BOOL* return_value);
FSErrorCode FSDK_Path_MoveTo(FS_PATH_HANDLE path_handle, const FSPointF point, FS_BOOL* return_value);
FSErrorCode FSDK_Path_LineTo(FS_PATH_HANDLE path_handle, const FSPointF point, FS_BOOL* return_value);
FSErrorCode FSDK_Path_CubicBezierTo(FS_PATH_HANDLE path_handle, const FSPointF point1, const FSPointF point2, const FSPointF point3, FS_BOOL* return_value);
FSErrorCode FSDK_Path_CloseFigure(FS_PATH_HANDLE path_handle, FS_BOOL* return_value);
FSErrorCode FSDK_Path_RemovePoint(FS_PATH_HANDLE path_handle, int index, FS_BOOL* return_value);
FSErrorCode FSDK_Path_AppendRect(FS_PATH_HANDLE path_handle, const FSRectF rect, FS_BOOL* return_value);
FSErrorCode FSDK_Path_AppendEllipse(FS_PATH_HANDLE path_handle, const FSRectF rect, FS_BOOL* return_value);
FSErrorCode FSDK_Path_Transform(FS_PATH_HANDLE path_handle, const FSMatrix matrix);
FSErrorCode FSDK_Path_Clear(FS_PATH_HANDLE path_handle);
FSErrorCode FSDK_Path_IncreasePointCount(FS_PATH_HANDLE path_handle, int count);

typedef enum _FSRenderingIntent {
e_FSRenderIntentPerceptual  = 0,
e_FSRenderIntentRelColorimetric = 1,
e_FSRenderIntentSaturation = 2,
e_FSRenderIntentAbsColorimetric = 3,
}FSRenderingIntent;


FSErrorCode FSDK_ColorSpace_Create( FSColorSpaceType type, FS_COLORSPACE_HANDLE* colorspace_return_value);
FSErrorCode FSDK_ColorSpace_Release(FS_COLORSPACE_HANDLE colorspace_handle);
FSErrorCode FSDK_ColorSpace_IsEmpty(FS_COLORSPACE_HANDLE colorspace_handle, FS_BOOL* return_value);
FSErrorCode FSDK_ColorSpace_GetComponentCount(FS_COLORSPACE_HANDLE colorspace_handle, int* return_value);
FSErrorCode FSDK_ColorSpace_GetColorSpaceType(FS_COLORSPACE_HANDLE colorspace_handle, FSColorSpaceType* return_value);
FSErrorCode FSDK_ColorSpace_IsSpotColorSpace(FS_COLORSPACE_HANDLE colorspace_handle, FS_BOOL* return_value);
FSErrorCode FSDK_ColorSpace_GetComponentNames(FS_COLORSPACE_HANDLE colorspace_handle, FS_BSTR* return_stringarray, FS_UINT32* return_array_length);
FSErrorCode FSDK_ColorSpace_ConvertColor(FS_COLORSPACE_HANDLE colorspace_handle, const FS_COLOR_HANDLE color, FS_COLOR_HANDLE* return_value);
FSErrorCode FSDK_ColorSpace_ConvertColor0(FS_COLORSPACE_HANDLE colorspace_handle, int r_value, int g_value, int b_value, FS_COLOR_HANDLE* return_value);
FSErrorCode FSDK_ColorSpace_ConvertColor1(FS_COLORSPACE_HANDLE colorspace_handle, int c_value, int m_value, int y_value, int k_value, FS_COLOR_HANDLE* return_value);
FSErrorCode FSDK_Color_Create(FS_COLOR_HANDLE* color_return_value);
FSErrorCode FSDK_Color_Create0(const FS_COLORSPACE_HANDLE color_space, FS_COLOR_HANDLE* color_return_value);
FSErrorCode FSDK_Color_Release(FS_COLOR_HANDLE color_handle);
FSErrorCode FSDK_Color_IsEmpty(FS_COLOR_HANDLE color_handle, FS_BOOL* return_value);
FSErrorCode FSDK_Color_GetColorSpace(FS_COLOR_HANDLE color_handle, FS_COLORSPACE_HANDLE* return_value);
FSErrorCode FSDK_Color_GetValue(FS_COLOR_HANDLE color_handle, float* return_float_array, FS_UINT32* return_array_length);
FSErrorCode FSDK_Color_SetValue(FS_COLOR_HANDLE color_handle, const float* float_array, FS_UINT32 array_length_component_array);
FSErrorCode FSDK_Color_ConvertToRGB(FS_COLOR_HANDLE color_handle,  FSRenderingIntent intent, FS_COLOR_HANDLE* return_value);
FSErrorCode FSDK_Color_ConvertToCMYK(FS_COLOR_HANDLE color_handle,  FSRenderingIntent intent, FS_COLOR_HANDLE* return_value);
#ifdef __cplusplus
}
#endif
#endif
