MagickCore  6.8.5
cache-private.h
Go to the documentation of this file.
1 /*
2  Copyright 1999-2013 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 cache private methods.
17 */
18 #ifndef _MAGICKCORE_CACHE_PRIVATE_H
19 #define _MAGICKCORE_CACHE_PRIVATE_H
20 
21 #if defined(__cplusplus) || defined(c_plusplus)
22 extern "C" {
23 #endif
24 
25 #include <time.h>
26 #include "magick/cache.h"
28 #include "magick/random_.h"
29 #include "magick/thread-private.h"
30 #include "magick/semaphore.h"
31 
32 typedef void
34 
35 typedef const IndexPacket
36  *(*GetVirtualIndexesFromHandler)(const Image *);
37 
38 typedef IndexPacket
39  *(*GetAuthenticIndexesFromHandler)(const Image *);
40 
41 typedef MagickBooleanType
42  (*GetOneAuthenticPixelFromHandler)(Image *,const ssize_t,const ssize_t,
45  const ssize_t,const ssize_t,PixelPacket *,ExceptionInfo *),
47 
48 typedef const PixelPacket
49  *(*GetVirtualPixelHandler)(const Image *,const VirtualPixelMethod,
50  const ssize_t,const ssize_t,const size_t,const size_t,ExceptionInfo *),
51  *(*GetVirtualPixelsHandler)(const Image *);
52 
53 typedef PixelPacket
54  *(*GetAuthenticPixelsHandler)(Image *,const ssize_t,const ssize_t,
55  const size_t,const size_t,ExceptionInfo *);
56 
57 typedef PixelPacket
58  *(*GetAuthenticPixelsFromHandler)(const Image *);
59 
60 typedef PixelPacket
61  *(*QueueAuthenticPixelsHandler)(Image *,const ssize_t,const ssize_t,
62  const size_t,const size_t,ExceptionInfo *);
63 
64 typedef void
65  (*DestroyPixelHandler)(Image *);
66 
67 typedef struct _CacheMethods
68 {
71 
74 
77 
80 
83 
86 
89 
92 
95 
98 
101 } CacheMethods;
102 
103 typedef struct _NexusInfo
104 {
107 
110 
113 
114  PixelPacket
116  *pixels;
117 
120 
123 
124  size_t
126 }NexusInfo;
127 
128 typedef struct _CacheInfo
129 {
130  ClassType
132 
135 
136  size_t
138 
139  CacheType
141 
142  MapMode
144 
147 
148  size_t
150  rows;
151 
154 
157 
158  VirtualPixelMethod
160 
163 
164  size_t
166 
167  NexusInfo
169 
170  PixelPacket
172 
175 
178 
179  int
181 
182  char
185 
188 
189  RandomInfo
191 
192  size_t
194 
195  void
197 
200  debug;
201 
203  id;
204 
205  ssize_t
207 
211 
212  time_t
214 
215  size_t
217 } CacheInfo;
218 
219 extern MagickExport Cache
220  AcquirePixelCache(const size_t),
221  ClonePixelCache(const Cache),
224 
225 extern MagickExport CacheType
226  GetPixelCacheType(const Image *);
227 
228 extern MagickExport ClassType
230 
233 
234 extern MagickExport const IndexPacket
236 
237 extern MagickExport const PixelPacket
238  *GetVirtualPixelsFromNexus(const Image *,const VirtualPixelMethod,
239  const ssize_t,const ssize_t,const size_t,const size_t,NexusInfo *,
242 
244  SyncAuthenticPixelCacheNexus(Image *,NexusInfo *,ExceptionInfo *)
246 
248  GetPixelCacheNexusExtent(const Cache,NexusInfo *);
249 
250 extern MagickExport NexusInfo
251  **AcquirePixelCacheNexus(const size_t),
252  **DestroyPixelCacheNexus(NexusInfo **,const size_t);
253 
254 extern MagickExport PixelPacket
255  *GetAuthenticPixelCacheNexus(Image *,const ssize_t,const ssize_t,
256  const size_t,const size_t,NexusInfo *,ExceptionInfo *) magick_hot_spot,
257  *QueueAuthenticPixel(Image *,const ssize_t,const ssize_t,const size_t,
258  const size_t,const MagickBooleanType,NexusInfo *,ExceptionInfo *),
259  *QueueAuthenticPixelCacheNexus(Image *,const ssize_t,const ssize_t,
260  const size_t,const size_t,const MagickBooleanType,NexusInfo *,
261  ExceptionInfo *) magick_hot_spot;
262 
263 extern MagickExport size_t
264  GetPixelCacheChannels(const Cache);
265 
266 extern MagickExport void
267  ClonePixelCacheMethods(Cache,const Cache),
268  GetPixelCacheTileSize(const Image *,size_t *,size_t *),
270  SetPixelCacheMethods(Cache,CacheMethods *);
271 
272 extern MagickPrivate MagickBooleanType
273  SyncImagePixelCache(Image *,ExceptionInfo *);
274 
275 #if defined(__cplusplus) || defined(c_plusplus)
276 }
277 #endif
278 
279 #endif