root / ImageMagick / branches / ImageMagick-6.3.5 / magick / delegate.h

Revision 7647, 2.9 kB (checked in by cristy, 15 months ago)
Line 
1/*
2  Copyright 1999-2007 ImageMagick Studio LLC, a non-profit organization
3  dedicated to making software imaging solutions freely available.
4 
5  You may not use this file except in compliance with the License.
6  obtain a copy of the License at
7 
8    http://www.imagemagick.org/script/license.php
9 
10  Unless required by applicable law or agreed to in writing, software
11  distributed under the License is distributed on an "AS IS" BASIS,
12  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  See the License for the specific language governing permissions and
14  limitations under the License.
15
16  MagickCore delegates methods.
17*/
18#ifndef _MAGICKCORE_DELEGATE_H
19#define _MAGICKCORE_DELEGATE_H
20
21#if defined(__cplusplus) || defined(c_plusplus)
22extern "C" {
23#endif
24
25#if defined(HasGS)
26#include "ghostscript/iapi.h"
27#include "ghostscript/ierrors.h"
28#endif
29
30#ifndef gs_main_instance_DEFINED
31# define gs_main_instance_DEFINED
32typedef struct gs_main_instance_s gs_main_instance;
33#endif
34
35#if !defined(MagickDLLCall)
36if defined(__WINDOWS__)
37#    define MagickDLLCall __stdcall
38else
39#    define MagickDLLCall
40endif
41#endif
42
43typedef struct _GhostscriptVectors
44{
45  int
46    (MagickDLLCall *exit)(gs_main_instance *);
47
48  int
49    (MagickDLLCall *init_with_args)(gs_main_instance *,int,char **);
50
51  int
52    (MagickDLLCall *new_instance)(gs_main_instance **,void *);
53
54  int
55    (MagickDLLCall *run_string)(gs_main_instance *,const char *,int,int *);
56
57  void
58    (MagickDLLCall *delete_instance)(gs_main_instance *);
59} GhostscriptVectors;
60
61typedef struct _DelegateInfo
62{
63  char
64    *path,
65    *decode,
66    *encode,
67    *commands;
68                                                                               
69  long
70    mode;
71                                                                               
72  MagickBooleanType
73    thread_support,
74    spawn,
75    stealth;
76                                                                               
77  struct _DelegateInfo
78    *previous,
79    *next;  /* deprecated, use GetDelegateInfoList() */
80
81  unsigned long
82    signature;
83} DelegateInfo;
84
85extern MagickExport char
86  *GetDelegateCommand(const ImageInfo *,Image *,const char *,const char *,
87    ExceptionInfo *),
88  **GetDelegateList(const char *,unsigned long *,ExceptionInfo *);
89
90extern MagickExport const char
91  *GetDelegateCommands(const DelegateInfo *);
92
93extern MagickExport const DelegateInfo
94  *GetDelegateInfo(const char *,const char *,ExceptionInfo *exception),
95  **GetDelegateInfoList(const char *,unsigned long *,ExceptionInfo *);
96
97extern MagickExport long
98  GetDelegateMode(const DelegateInfo *);
99
100extern MagickExport MagickBooleanType
101  GetDelegateThreadSupport(const DelegateInfo *),
102  InvokeDelegate(ImageInfo *,Image *,const char *,const char *,ExceptionInfo *),
103  ListDelegateInfo(FILE *,ExceptionInfo *);
104
105extern MagickExport void
106  DestroyDelegateList(void);
107
108#if defined(__cplusplus) || defined(c_plusplus)
109}
110#endif
111
112#endif
Note: See TracBrowser for help on using the browser.