~ubuntu-branches/ubuntu/quantal/imagemagick/quantal

« back to all changes in this revision

Viewing changes to magick/cache-private.h

  • Committer: Bazaar Package Importer
  • Author(s): Muharem Hrnjadovic
  • Date: 2009-06-04 13:01:13 UTC
  • mfrom: (1.1.5 upstream) (6.1.1 sid)
  • Revision ID: james.westby@ubuntu.com-20090604130113-my9114jxmafpwew3
Tags: 7:6.5.1.0-1.1ubuntu1
* Merge from debian unstable, remaining changes:
  - (Build-)depend on libltdl7-dev instead of libltdl3-dev (the armel buildds
    currently have both available).
  - Don't build-dep on librsvg, it brings in excessive dependencies

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/*
2
 
  Copyright 1999-2008 ImageMagick Studio LLC, a non-profit organization
 
2
  Copyright 1999-2009 ImageMagick Studio LLC, a non-profit organization
3
3
  dedicated to making software imaging solutions freely available.
4
4
  
5
5
  You may not use this file except in compliance with the License.
37
37
  *Cache;
38
38
 
39
39
typedef const IndexPacket
40
 
  *(*AcquireIndexesFromHandler)(const Image *);
 
40
  *(*GetVirtualIndexesFromHandler)(const Image *);
41
41
 
42
42
typedef IndexPacket
43
 
  *(*GetIndexesFromHandler)(const Image *);
 
43
  *(*GetAuthenticIndexesFromHandler)(const Image *);
44
44
 
45
45
typedef MagickBooleanType
46
 
  (*AcquireOnePixelFromHandler)(const Image *,const VirtualPixelMethod,
 
46
  (*GetOneAuthenticPixelFromHandler)(Image *,const long,const long,
 
47
    PixelPacket *,ExceptionInfo *),
 
48
  (*GetOneVirtualPixelFromHandler)(const Image *,const VirtualPixelMethod,
47
49
    const long,const long,PixelPacket *,ExceptionInfo *),
48
 
  (*GetOnePixelFromHandler)(Image *,const long,const long,PixelPacket *),
49
 
  (*SyncPixelHandler)(Image *);
 
50
  (*SyncAuthenticPixelsHandler)(Image *,ExceptionInfo *);
50
51
 
51
52
typedef const PixelPacket
52
 
  *(*AcquirePixelHandler)(const Image *,const VirtualPixelMethod,const long,
53
 
    const long,const unsigned long,const unsigned long,ExceptionInfo *);
54
 
 
55
 
typedef PixelPacket
56
 
  *(*GetPixelHandler)(Image *,const long,const long,const unsigned long,
57
 
    const unsigned long);
58
 
 
59
 
typedef PixelPacket
60
 
  *(*GetPixelsFromHandler)(const Image *);
61
 
 
62
 
typedef PixelPacket
63
 
  *(*SetPixelHandler)(Image *,const long,const long,const unsigned long,
64
 
    const unsigned long);
 
53
  *(*GetVirtualPixelHandler)(const Image *,const VirtualPixelMethod,const long,
 
54
    const long,const unsigned long,const unsigned long,ExceptionInfo *),
 
55
  *(*GetVirtualPixelsHandler)(const Image *);
 
56
 
 
57
typedef PixelPacket
 
58
  *(*GetAuthenticPixelsHandler)(Image *,const long,const long,
 
59
    const unsigned long,const unsigned long,ExceptionInfo *);
 
60
 
 
61
typedef PixelPacket
 
62
  *(*GetAuthenticPixelsFromHandler)(const Image *);
 
63
 
 
64
typedef PixelPacket
 
65
  *(*QueueAuthenticPixelsHandler)(Image *,const long,const long,
 
66
    const unsigned long,const unsigned long,ExceptionInfo *);
65
67
 
66
68
typedef void
67
69
  (*DestroyPixelHandler)(Image *);
68
70
 
69
71
typedef struct _CacheMethods
70
72
{
71
 
  AcquireIndexesFromHandler
72
 
    acquire_indexes_from_handler;
73
 
 
74
 
  AcquireOnePixelFromHandler
75
 
    acquire_one_pixel_from_handler;
76
 
 
77
 
  AcquirePixelHandler
78
 
    acquire_pixel_handler;
 
73
  GetVirtualPixelHandler
 
74
    get_virtual_pixel_handler;
 
75
 
 
76
  GetVirtualPixelsHandler
 
77
    get_virtual_pixels_handler;
 
78
 
 
79
  GetVirtualIndexesFromHandler
 
80
    get_virtual_indexes_from_handler;
 
81
 
 
82
  GetOneVirtualPixelFromHandler
 
83
    get_one_virtual_pixel_from_handler;
 
84
 
 
85
  GetAuthenticPixelsHandler
 
86
    get_authentic_pixels_handler;
 
87
 
 
88
  GetAuthenticIndexesFromHandler
 
89
    get_authentic_indexes_from_handler;
 
90
 
 
91
  GetOneAuthenticPixelFromHandler
 
92
    get_one_authentic_pixel_from_handler;
 
93
 
 
94
  GetAuthenticPixelsFromHandler
 
95
    get_authentic_pixels_from_handler;
 
96
 
 
97
  QueueAuthenticPixelsHandler
 
98
    queue_authentic_pixels_handler;
 
99
 
 
100
  SyncAuthenticPixelsHandler
 
101
    sync_authentic_pixels_handler;
79
102
 
80
103
  DestroyPixelHandler
81
104
    destroy_pixel_handler;
82
105
 
83
 
  GetIndexesFromHandler
84
 
    get_indexes_from_handler;
85
 
 
86
 
  GetOnePixelFromHandler
87
 
    get_one_pixel_from_handler;
88
 
 
89
 
  GetPixelHandler
90
 
    get_pixel_handler;
91
 
 
92
 
  GetPixelsFromHandler
93
 
    get_pixels_from_handler;
94
 
 
95
 
  SetPixelHandler
96
 
    set_pixel_handler;
97
 
 
98
 
  SyncPixelHandler
99
 
    sync_pixel_handler;
100
106
} CacheMethods;
101
107
 
102
108
typedef struct _NexusInfo
104
110
 
105
111
typedef struct _CacheInfo
106
112
{
107
 
  NexusInfo
108
 
    *nexus_info;
109
 
 
110
 
  unsigned long
111
 
    number_views;
112
 
 
113
113
  ClassType
114
114
    storage_class;
115
115
 
116
116
  ColorspaceType
117
117
    colorspace;
118
118
 
119
 
  volatile CacheType
 
119
  CacheType
120
120
    type;
121
121
 
122
122
  MagickBooleanType
132
132
  MagickSizeType
133
133
    length;
134
134
 
 
135
  VirtualPixelMethod
 
136
    virtual_pixel_method;
 
137
 
 
138
  unsigned long
 
139
    number_threads;
 
140
 
 
141
  NexusInfo
 
142
    **nexus_info;
 
143
 
135
144
  PixelPacket
136
145
    *pixels;
137
146
 
138
147
  IndexPacket
139
148
    *indexes;
140
149
 
141
 
  VirtualPixelMethod
142
 
    virtual_pixel_method;
143
 
 
144
 
  PixelPacket
145
 
    virtual_pixel;
 
150
  MagickBooleanType
 
151
    active_index_channel;
146
152
 
147
153
  int
148
154
    file;
149
155
 
150
 
  MagickSizeType
151
 
    serial_number;
152
 
 
153
156
  char
154
157
    filename[MaxTextExtent],
155
158
    cache_filename[MaxTextExtent];
165
168
#elif defined(__WINDOWS__)
166
169
  DWORD
167
170
#else
168
 
  unsigned long
 
171
  pid_t
169
172
#endif
170
173
    id;
171
174
 
172
 
  volatile long
 
175
  long
173
176
    reference_count;
174
177
 
175
178
  SemaphoreInfo
176
179
    *semaphore,
177
 
    *nexus_semaphore,
178
180
    *disk_semaphore;
179
181
 
 
182
  time_t
 
183
    timestamp;
 
184
 
180
185
  unsigned long
181
186
    signature;
182
187
} CacheInfo;
183
188
 
184
189
extern MagickExport Cache
185
 
  DestroyCacheInfo(Cache),
186
 
  ReferenceCache(Cache);
 
190
  AcquirePixelCacheInfo(const unsigned long),
 
191
  DestroyPixelCacheInfo(Cache),
 
192
  GetImagePixelCache(Image *,const MagickBooleanType,ExceptionInfo *),
 
193
  ReferencePixelCache(Cache);
187
194
 
188
195
extern MagickExport ClassType
189
 
  GetCacheClass(const Cache);
 
196
  GetPixelCacheStorageClass(const Cache);
190
197
 
191
198
extern MagickExport ColorspaceType
192
 
  GetCacheColorspace(const Cache);
 
199
  GetPixelCacheColorspace(const Cache);
193
200
 
194
201
extern MagickExport const IndexPacket
195
 
  *AcquireNexusIndexes(const Cache,const unsigned long);
 
202
  *GetVirtualIndexesFromNexus(const Cache,NexusInfo *);
 
203
 
 
204
extern MagickExport const PixelPacket
 
205
  *GetVirtualPixelsFromNexus(const Image *,const VirtualPixelMethod,const long,
 
206
    const long,const unsigned long,const unsigned long,NexusInfo *,
 
207
    ExceptionInfo *),
 
208
  *GetVirtualPixelsNexus(const Cache,NexusInfo *);
196
209
 
197
210
extern MagickExport IndexPacket
198
 
  *GetNexusIndexes(const Cache,const unsigned long);
 
211
  *GetPixelCacheNexusIndexes(const Cache,NexusInfo *);
199
212
 
200
213
extern MagickExport MagickBooleanType
201
 
  GetCacheInfo(Cache *);
 
214
  SyncAuthenticPixelCacheNexus(Image *,NexusInfo *,ExceptionInfo *);
 
215
 
 
216
extern MagickExport MagickSizeType
 
217
  GetPixelCacheNexusExtent(const Cache,NexusInfo *);
 
218
 
 
219
extern MagickExport NexusInfo
 
220
  **AcquirePixelCacheNexus(const unsigned long),
 
221
  **DestroyPixelCacheNexus(NexusInfo **,const unsigned long);
202
222
 
203
223
extern MagickExport PixelPacket
204
 
  *GetNexusPixels(const Cache,const unsigned long);
205
 
 
206
 
extern MagickExport unsigned long
207
 
  GetNexus(Cache);
 
224
  *GetAuthenticPixelCacheNexus(Image *,const long,const long,
 
225
    const unsigned long,const unsigned long,NexusInfo *,ExceptionInfo *),
 
226
  *GetPixelCacheNexusPixels(const Cache,NexusInfo *),
 
227
  *QueueAuthenticNexus(Image *,const long,const long,const unsigned long,
 
228
    const unsigned long,NexusInfo *,ExceptionInfo *);
208
229
 
209
230
extern MagickExport void
210
 
  CloneCacheMethods(Cache,const Cache),
211
 
  DestroyCacheNexus(Cache,const unsigned long),
212
 
  GetCacheMethods(CacheMethods *),
213
 
  SetCacheMethods(Cache,CacheMethods *);
 
231
  ClonePixelCacheMethods(Cache,const Cache),
 
232
  GetPixelCacheMethods(CacheMethods *),
 
233
  SetPixelCacheMethods(Cache,CacheMethods *);
214
234
 
215
235
#if defined(__cplusplus) || defined(c_plusplus)
216
236
}