// CodeGear C++Builder
// Copyright (c) 1995, 2015 by Embarcadero Technologies, Inc.
// All rights reserved

// (DO NOT EDIT: machine generated header) 'iemiscplugins.pas' rev: 30.00 (Windows)

#ifndef IemiscpluginsHPP
#define IemiscpluginsHPP

#pragma delphiheader begin
#pragma option push
#pragma option -w-      // All warnings off
#pragma option -Vx      // Zero-length empty class member 
#pragma pack(push,8)
#include <System.hpp>
#include <SysInit.hpp>
#include <Winapi.Windows.hpp>
#include <Winapi.Messages.hpp>
#include <System.Classes.hpp>
#include <Vcl.Graphics.hpp>
#include <System.SysUtils.hpp>
#include <hyiedefs.hpp>
#include <imageenio.hpp>
#include <hyieutils.hpp>
#include <iesettings.hpp>

//-- user supplied -----------------------------------------------------------

namespace Iemiscplugins
{
//-- forward type declarations -----------------------------------------------
class DELPHICLASS TIEMiscPluginsImageMagick;
//-- type declarations -------------------------------------------------------
typedef void * TIEImageMagick_MagickWand;

typedef System::LongBool TIEImageMagick_MagickBooleanType;

typedef unsigned TIEImageMagick_size_t;

typedef int TIEImageMagick_ssize_t;

typedef __int64 TIEImageMagick_MagickOffsetType;

typedef unsigned __int64 TIEImageMagick_MagickSizeType;

typedef void * TIEImageMagick_MagicInfo;

typedef void * TIEImageMagick_ExceptionInfo;

typedef int TIEImageMagick_ExceptionType;

typedef void * TIEImageMagick_PixelWand;

enum DECLSPEC_DENUM TIEImageMagick_StorageType : unsigned int { imck_UndefinedPixel, imck_CharPixel, imck_DoublePixel, imck_FloatPixel, imck_IntegerPixel, imck_LongPixel, imck_QuantumPixel, imck_ShortPixel };

enum DECLSPEC_DENUM TIEImageMagick_ChannelType : unsigned int { imck_UndefinedChannel, imck_RedChannel, imck_GrayChannel = 1, imck_CyanChannel = 1, imck_GreenChannel, imck_MagentaChannel = 2, imck_BlueChannel = 4, imck_YellowChannel = 4, imck_AlphaChannel = 8, imck_OpacityChannel = 8, imck_MatteChannel = 8, imck_BlackChannel = 32, imck_IndexChannel = 32, imck_CompositeChannels = 47, imck_AllChannels = 134217727, imck_TrueAlphaChannel = 64, imck_RGBChannels = 128, imck_GrayChannels = 128, imck_SyncChannels = 256, imck_DefaultChannels = 134217719 };

enum DECLSPEC_DENUM TIEImageMagick_ColorspaceType : unsigned int { imck_UndefinedColorspace, imck_RGBColorspace, imck_GRAYColorspace, imck_TransparentColorspace, imck_OHTAColorspace, imck_LabColorspace, imck_XYZColorspace, imck_YCbCrColorspace, imck_YCCColorspace, imck_YIQColorspace, imck_YPbPrColorspace, imck_YUVColorspace, imck_CMYKColorspace, imck_sRGBColorspace, imck_HSBColorspace, imck_HSLColorspace, imck_HWBColorspace, imck_Rec601LumaColorspace, imck_Rec601YCbCrColorspace, imck_Rec709LumaColorspace, imck_Rec709YCbCrColorspace, imck_LogColorspace, imck_CMYColorspace, imck_LuvColorspace, imck_HCLColorspace, imck_LCHColorspace, imck_LMSColorspace, imck_LCHabColorspace, imck_LCHuvColorspace, imck_scRGBColorspace, imck_HSIColorspace, imck_HSVColorspace, 
	imck_HCLpColorspace, imck_YDbDrColorspace };

enum DECLSPEC_DENUM TIEImageMagick_ResolutionType : unsigned int { imck_UndefinedResolution, imck_PixelsPerInchResolution, imck_PixelsPerCentimeterResolution };

enum DECLSPEC_DENUM TIEImageMagick_ImageType : unsigned int { imck_UndefinedType, imck_BilevelType, imck_GrayscaleType, imck_GrayscaleMatteType, imck_PaletteType, imck_PaletteMatteType, imck_TrueColorType, imck_TrueColorMatteType, imck_ColorSeparationType, imck_ColorSeparationMatteType, imck_OptimizeType, imck_PaletteBilevelMatteType };

typedef System::LongBool __cdecl (*TIEImageMagick_MagickProgressMonitor)(char * text, __int64 offset, unsigned __int64 span, void * client_data);

#pragma pack(push,4)
class PASCALIMPLEMENTATION TIEMiscPluginsImageMagick : public System::TObject
{
	typedef System::TObject inherited;
	
public:
	__classmethod bool __fastcall IsAvailable();
	__classmethod void __fastcall Initialize(bool reinitialize = true);
	__classmethod void __fastcall Finalize();
	__classmethod void __fastcall RegisterPlugin();
	
private:
	__classmethod NativeUInt __fastcall HandleWand(NativeUInt Handle = (NativeUInt)(0x0), bool Setup = false);
	__classmethod NativeUInt __fastcall HandleMagick(NativeUInt Handle = (NativeUInt)(0x0), bool Setup = false);
	__classmethod void __fastcall CheckCallWand(void * &exec, System::AnsiString name);
	__classmethod void __fastcall CheckCallMagick(void * &exec, System::AnsiString name);
	
public:
	__classmethod void __fastcall MagickWandGenesis();
	__classmethod void __fastcall MagickWandTerminus();
	__classmethod void * __fastcall NewMagickWand();
	__classmethod void * __fastcall DestroyMagickWand(void * wand);
	__classmethod System::LongBool __fastcall MagickReadImage(void * wand, char * filename);
	__classmethod System::LongBool __fastcall MagickReadImageBlob(void * wand, void * blob, unsigned length);
	__classmethod System::LongBool __fastcall MagickPingImageBlob(void * wand, void * blob, unsigned length);
	__classmethod System::LongBool __fastcall MagickPingImage(void * wand, char * filename);
	__classmethod void __fastcall MagickResetIterator(void * wand);
	__classmethod System::LongBool __fastcall MagickNextImage(void * wand);
	__classmethod System::LongBool __fastcall MagickSetIteratorIndex(void * wand, int index);
	__classmethod void __fastcall MagickSetLastIterator(void * wand);
	__classmethod int __fastcall MagickGetIteratorIndex(void * wand);
	__classmethod System::LongBool __fastcall MagickExportImagePixels(void * wand, int x, int y, unsigned columns, unsigned rows, char * map, TIEImageMagick_StorageType storage, void * pixels);
	__classmethod unsigned __fastcall MagickGetImageWidth(void * wand);
	__classmethod unsigned __fastcall MagickGetImageHeight(void * wand);
	__classmethod unsigned __fastcall MagickGetImageChannelDepth(void * wand, TIEImageMagick_ChannelType channel);
	__classmethod TIEImageMagick_ColorspaceType __fastcall MagickGetImageColorspace(void * wand);
	__classmethod System::LongBool __fastcall MagickSetImageColorspace(void * wand, TIEImageMagick_ColorspaceType colorspace);
	__classmethod System::LongBool __fastcall MagickTransformImageColorspace(void * wand, TIEImageMagick_ColorspaceType colorspace);
	__classmethod unsigned __fastcall MagickGetImageDepth(void * wand);
	__classmethod System::LongBool __fastcall MagickGetImageResolution(void * wand, double &x, double &y);
	__classmethod TIEImageMagick_ResolutionType __fastcall MagickGetImageUnits(void * wand);
	__classmethod char * __fastcall MagickGetImageFormat(void * wand);
	__classmethod TIEImageMagick_ImageType __fastcall MagickGetType(void * wand);
	__classmethod TIEImageMagick_MagickProgressMonitor __fastcall MagickSetProgressMonitor(void * wand, TIEImageMagick_MagickProgressMonitor progress_monitor, void * client_data);
	__classmethod System::LongBool __fastcall MagickSetImageProperty(void * wand, char * prop, char * value);
	__classmethod System::LongBool __fastcall MagickSetOption(void * wand, char * key, char * value);
	__classmethod char * __fastcall MagickGetException(void * wand, int &severity);
	__classmethod void * __fastcall MagickRelinquishMemory(void * resource);
	__classmethod System::LongBool __fastcall MagickSetColorspace(void * wand, TIEImageMagick_ColorspaceType colorspace);
	__classmethod System::LongBool __fastcall MagickSetDepth(void * wand, unsigned depth);
	__classmethod System::LongBool __fastcall MagickSetFormat(void * wand, char * format);
	__classmethod System::LongBool __fastcall MagickSetResolution(void * wand, double x_resolution, double y_resolution);
	__classmethod System::LongBool __fastcall MagickSetImageUnits(void * wand, TIEImageMagick_ResolutionType units);
	__classmethod System::PByte __fastcall MagickGetImageBlob(void * wand, unsigned &length);
	__classmethod System::LongBool __fastcall MagickWriteImage(void * wand, char * filename);
	__classmethod System::LongBool __fastcall MagickWriteImages(void * wand, char * filename, System::LongBool adjoin);
	__classmethod System::LongBool __fastcall MagickImportImagePixels(void * wand, int x, int y, unsigned columns, unsigned rows, char * map, TIEImageMagick_StorageType storage, void * pixels);
	__classmethod System::LongBool __fastcall MagickNewImage(void * wand, unsigned columns, unsigned rows, void * background);
	__classmethod void * __fastcall NewPixelWand();
	__classmethod void * __fastcall DestroyPixelWand(void * pixelWand);
	__classmethod void * __fastcall GetMagicInfo(void * magic, unsigned length, void * exception);
	__classmethod char * __fastcall GetMagicName(void * magic_info);
	__classmethod void * __fastcall AcquireExceptionInfo();
	__classmethod void * __fastcall DestroyExceptionInfo(void * e);
public:
	/* TObject.Create */ inline __fastcall TIEMiscPluginsImageMagick(void) : System::TObject() { }
	/* TObject.Destroy */ inline __fastcall virtual ~TIEMiscPluginsImageMagick(void) { }
	
};

#pragma pack(pop)

//-- var, const, procedure ---------------------------------------------------
static const System::Word iomscFITS = System::Word(0x2001);
static const System::Word iomscPCD = System::Word(0x2002);
static const System::Word iomscPCL = System::Word(0x2003);
static const System::Word iomscPDF = System::Word(0x2004);
static const System::Word iomscBIE = System::Word(0x2005);
static const System::Word iomscCIN = System::Word(0x2006);
static const System::Word iomscDDS = System::Word(0x2007);
static const System::Word iomscDFONT = System::Word(0x2008);
static const System::Word iomscDPX = System::Word(0x2009);
static const System::Word iomscJBIG = System::Word(0x200a);
static const System::Word iomscJNG = System::Word(0x200b);
static const System::Word iomscM2V = System::Word(0x200c);
static const System::Word iomscMAT = System::Word(0x200d);
static const System::Word iomscMIFF = System::Word(0x200e);
static const System::Word iomscMNG = System::Word(0x200f);
static const System::Word iomscMP4 = System::Word(0x2010);
static const System::Word iomscMSVG = System::Word(0x2011);
static const System::Word iomscPES = System::Word(0x2012);
static const System::Word iomscPS = System::Word(0x2013);
static const System::Word iomscPSB = System::Word(0x2014);
static const System::Word iomscPTIF = System::Word(0x2015);
static const System::Word iomscSVG = System::Word(0x2016);
static const System::Word iomscTIFF64 = System::Word(0x2017);
static const System::Word iomscXCF = System::Word(0x2018);
static const System::Word iomscXPS = System::Word(0x2019);
static const System::Word Min_ImageMagick_Type = System::Word(0x2001);
static const System::Word Max_ImageMagick_Type = System::Word(0x2019);
#define IEIMAGEMAGICK_WAND_DLL_FILENAME L"CORE_RL_wand_.dll"
#define IEIMAGEMAGICK_MAGICK_DLL_FILENAME L"CORE_RL_magick_.dll"
extern DELPHI_PACKAGE int __fastcall TIEMiscPluginsImageMagick_PDFFrameCount(System::Classes::TStream* Stream);
extern DELPHI_PACKAGE void __fastcall TIEMiscPluginsImageMagick_ReadImageStream(System::Classes::TStream* Stream, Hyieutils::TIEBitmap* Bitmap, Imageenio::TIOParamsVals* &IOParams, Hyiedefs::TProgressRec &Progress, bool Preview);
extern DELPHI_PACKAGE void __fastcall TIEMiscPluginsImageMagick_WriteImageStream(System::Classes::TStream* Stream, Hyieutils::TIEBitmap* Bitmap, Imageenio::TIOParamsVals* &IOParams, Hyiedefs::TProgressRec &Progress);
extern DELPHI_PACKAGE bool __fastcall TIEMiscPluginsImageMagick_TryImageStream(System::Classes::TStream* Stream, int TryingFormat);
}	/* namespace Iemiscplugins */
#if !defined(DELPHIHEADER_NO_IMPLICIT_NAMESPACE_USE) && !defined(NO_USING_NAMESPACE_IEMISCPLUGINS)
using namespace Iemiscplugins;
#endif
#pragma pack(pop)
#pragma option pop

#pragma delphiheader end.
//-- end unit ----------------------------------------------------------------
#endif	// IemiscpluginsHPP
