Lines Matching refs:nexus_info
214 cache_info->nexus_info=AcquirePixelCacheNexus(cache_info->number_threads);
215 if (cache_info->nexus_info == (NexusInfo **) NULL)
257 **magick_restrict nexus_info;
262 nexus_info=(NexusInfo **) MagickAssumeAligned(AcquireAlignedMemory(
263 number_threads,sizeof(*nexus_info)));
264 if (nexus_info == (NexusInfo **) NULL)
266 nexus_info[0]=(NexusInfo *) AcquireQuantumMemory(number_threads,
267 sizeof(**nexus_info));
268 if (nexus_info[0] == (NexusInfo *) NULL)
270 (void) ResetMagickMemory(nexus_info[0],0,number_threads*sizeof(**nexus_info));
273 nexus_info[i]=(&nexus_info[0][i]);
274 nexus_info[i]->signature=MagickCoreSignature;
276 return(nexus_info);
972 if (cache_info->nexus_info != (NexusInfo **) NULL)
973 cache_info->nexus_info=DestroyPixelCacheNexus(cache_info->nexus_info,
1003 % NexusInfo **DestroyPixelCacheNexus(NexusInfo *nexus_info,
1008 % o nexus_info: the nexus to destroy.
1014 static inline void RelinquishCacheNexusPixels(NexusInfo *nexus_info)
1016 if (nexus_info->mapped == MagickFalse)
1017 (void) RelinquishAlignedMemory(nexus_info->cache);
1019 (void) UnmapBlob(nexus_info->cache,(size_t) nexus_info->length);
1020 nexus_info->cache=(Quantum *) NULL;
1021 nexus_info->pixels=(Quantum *) NULL;
1022 nexus_info->metacontent=(void *) NULL;
1023 nexus_info->length=0;
1024 nexus_info->mapped=MagickFalse;
1027 MagickPrivate NexusInfo **DestroyPixelCacheNexus(NexusInfo **nexus_info,
1033 assert(nexus_info != (NexusInfo **) NULL);
1036 if (nexus_info[i]->cache != (Quantum *) NULL)
1037 RelinquishCacheNexusPixels(nexus_info[i]);
1038 nexus_info[i]->signature=(~MagickCoreSignature);
1040 nexus_info[0]=(NexusInfo *) RelinquishMagickMemory(nexus_info[0]);
1041 nexus_info=(NexusInfo **) RelinquishAlignedMemory(nexus_info);
1042 return(nexus_info);
1094 return(cache_info->nexus_info[id]->metacontent);
1136 return(cache_info->nexus_info[id]->metacontent);
1221 % NexusInfo *nexus_info,ExceptionInfo *exception)
1230 % o nexus_info: the cache nexus to return.
1237 const ssize_t y,const size_t columns,const size_t rows,NexusInfo *nexus_info,
1252 nexus_info,exception);
1257 if (nexus_info->authentic_pixel_cache != MagickFalse)
1259 if (ReadPixelCachePixels(cache_info,nexus_info,exception) == MagickFalse)
1262 if (ReadPixelCacheMetacontent(cache_info,nexus_info,exception) == MagickFalse)
1305 return(cache_info->nexus_info[id]->pixels);
1350 return(cache_info->nexus_info[id]->pixels);
1426 cache_info->nexus_info[id],exception);
1484 cache_info->nexus_info[id],exception);
1528 return(GetPixelCacheNexusExtent(cache_info,cache_info->nexus_info[id]));
1588 (cache_info->nexus_info == (NexusInfo **) NULL))
1664 cache_info->nexus_info=(NexusInfo **) NULL;
1865 q=GetAuthenticPixelCacheNexus(image,x,y,1UL,1UL,cache_info->nexus_info[id],
1926 1UL,1UL,cache_info->nexus_info[id],exception);
1986 cache_info->nexus_info[id],exception);
2046 cache_info->nexus_info[id],exception);
2152 % NexusInfo *nexus_info)
2156 % o nexus_info: the nexus info.
2160 NexusInfo *magick_restrict nexus_info)
2171 extent=(MagickSizeType) nexus_info->region.width*nexus_info->region.height;
2391 cache_info->nexus_info[id]);
2413 % NexusInfo *nexus_info)
2419 % o nexus_info: the cache nexus to return the meta-content.
2423 NexusInfo *magick_restrict nexus_info)
2433 return(nexus_info->metacontent);
2482 cache_info->nexus_info[id]);
2506 % const size_t columns,const size_t rows,NexusInfo *nexus_info,
2518 % o nexus_info: the cache nexus to acquire.
2613 const size_t columns,const size_t rows,NexusInfo *nexus_info,
2672 pixels=SetPixelCacheNexusPixels(cache_info,ReadMode,®ion,nexus_info,
2677 offset=(MagickOffsetType) nexus_info->region.y*cache_info->columns+
2678 nexus_info->region.x;
2679 length=(MagickSizeType) (nexus_info->region.height-1L)*cache_info->columns+
2680 nexus_info->region.width-1L;
2692 if (nexus_info->authentic_pixel_cache != MagickFalse)
2694 status=ReadPixelCachePixels(cache_info,nexus_info,exception);
2699 status=ReadPixelCacheMetacontent(cache_info,nexus_info,exception);
2708 s=(unsigned char *) nexus_info->metacontent;
3064 cache_info->nexus_info[id],exception);
3109 return(GetVirtualPixelsNexus(cache_info,cache_info->nexus_info[id]));
3185 columns,rows,cache_info->nexus_info[id],exception);
3227 return(GetVirtualPixelsNexus(image->cache,cache_info->nexus_info[id]));
3248 % NexusInfo *nexus_info)
3254 % o nexus_info: the cache nexus to return the colormap pixels.
3258 NexusInfo *magick_restrict nexus_info)
3268 return((const Quantum *) nexus_info->pixels);
3898 % const MagickBooleanType clone,NexusInfo *nexus_info,
3908 % o nexus_info: the cache nexus to set.
3917 const MagickBooleanType clone,NexusInfo *nexus_info,ExceptionInfo *exception)
3966 pixels=SetPixelCacheNexusPixels(cache_info,WriteMode,®ion,nexus_info,
4025 cache_info->nexus_info[id],exception);
4113 cache_info->nexus_info[id],exception);
4135 % NexusInfo *nexus_info,ExceptionInfo *exception)
4141 % o nexus_info: the cache nexus to read the metacontent.
4182 CacheInfo *magick_restrict cache_info,NexusInfo *magick_restrict nexus_info,
4204 if (nexus_info->authentic_pixel_cache != MagickFalse)
4206 offset=(MagickOffsetType) nexus_info->region.y*cache_info->columns+
4207 nexus_info->region.x;
4208 length=(MagickSizeType) nexus_info->region.width*
4210 extent=length*nexus_info->region.height;
4211 rows=nexus_info->region.height;
4213 q=(unsigned char *) nexus_info->metacontent;
4225 if ((cache_info->columns == nexus_info->region.width) &&
4237 q+=cache_info->metacontent_extent*nexus_info->region.width;
4254 if ((cache_info->columns == nexus_info->region.width) &&
4269 q+=cache_info->metacontent_extent*nexus_info->region.width;
4285 region=nexus_info->region;
4286 if ((cache_info->columns != nexus_info->region.width) ||
4300 q+=cache_info->metacontent_extent*nexus_info->region.width;
4316 (CacheTick(nexus_info->region.y,cache_info->rows) != MagickFalse))
4319 nexus_info->region.width,(double) nexus_info->region.height,(double)
4320 nexus_info->region.x,(double) nexus_info->region.y);
4342 % NexusInfo *nexus_info,ExceptionInfo *exception)
4348 % o nexus_info: the cache nexus to read the pixels.
4354 CacheInfo *magick_restrict cache_info,NexusInfo *magick_restrict nexus_info,
4375 if (nexus_info->authentic_pixel_cache != MagickFalse)
4377 offset=(MagickOffsetType) nexus_info->region.y*cache_info->columns;
4378 if ((ssize_t) (offset/cache_info->columns) != nexus_info->region.y)
4380 offset+=nexus_info->region.x;
4382 length=(MagickSizeType) number_channels*nexus_info->region.width*
4384 if ((length/number_channels/sizeof(Quantum)) != nexus_info->region.width)
4386 rows=nexus_info->region.height;
4391 q=nexus_info->pixels;
4403 if ((cache_info->columns == nexus_info->region.width) &&
4414 q+=cache_info->number_channels*nexus_info->region.width;
4431 if ((cache_info->columns == nexus_info->region.width) &&
4444 q+=cache_info->number_channels*nexus_info->region.width;
4460 region=nexus_info->region;
4461 if ((cache_info->columns != nexus_info->region.width) ||
4475 q+=cache_info->number_channels*nexus_info->region.width;
4491 (CacheTick(nexus_info->region.y,cache_info->rows) != MagickFalse))
4494 nexus_info->region.width,(double) nexus_info->region.height,(double)
4495 nexus_info->region.x,(double) nexus_info->region.y);
4669 % const MapMode mode,const RectangleInfo *region,NexusInfo *nexus_info,
4681 % o nexus_info: the cache nexus to set.
4688 const CacheInfo *magick_restrict cache_info,NexusInfo *nexus_info,
4691 if (nexus_info->length != (MagickSizeType) ((size_t) nexus_info->length))
4693 nexus_info->mapped=MagickFalse;
4694 nexus_info->cache=(Quantum *) MagickAssumeAligned(AcquireAlignedMemory(1,
4695 (size_t) nexus_info->length));
4696 if (nexus_info->cache == (Quantum *) NULL)
4698 nexus_info->mapped=MagickTrue;
4699 nexus_info->cache=(Quantum *) MapBlob(-1,IOMode,0,(size_t)
4700 nexus_info->length);
4702 if (nexus_info->cache == (Quantum *) NULL)
4714 const NexusInfo *magick_restrict nexus_info)
4727 offset=(MagickOffsetType) nexus_info->region.y*cache_info->columns+
4728 nexus_info->region.x;
4729 status=nexus_info->pixels == (cache_info->pixels+offset*
4734 static inline void PrefetchPixelCacheNexusPixels(const NexusInfo *nexus_info,
4739 MagickCachePrefetch((unsigned char *) nexus_info->pixels,0,1);
4742 MagickCachePrefetch((unsigned char *) nexus_info->pixels,1,1);
4746 const MapMode mode,const RectangleInfo *region,NexusInfo *nexus_info,
4760 nexus_info->region=(*region);
4767 x=nexus_info->region.x+(ssize_t) nexus_info->region.width-1;
4768 y=nexus_info->region.y+(ssize_t) nexus_info->region.height-1;
4769 if (((nexus_info->region.x >= 0) && (x < (ssize_t) cache_info->columns) &&
4770 (nexus_info->region.y >= 0) && (y < (ssize_t) cache_info->rows)) &&
4771 ((nexus_info->region.height == 1UL) || ((nexus_info->region.x == 0) &&
4772 ((nexus_info->region.width == cache_info->columns) ||
4773 ((nexus_info->region.width % cache_info->columns) == 0)))))
4781 offset=(MagickOffsetType) nexus_info->region.y*cache_info->columns+
4782 nexus_info->region.x;
4783 nexus_info->pixels=cache_info->pixels+cache_info->number_channels*
4785 nexus_info->metacontent=(void *) NULL;
4787 nexus_info->metacontent=(unsigned char *) cache_info->metacontent+
4789 PrefetchPixelCacheNexusPixels(nexus_info,mode);
4790 nexus_info->authentic_pixel_cache=IsPixelCacheAuthentic(cache_info,
4791 nexus_info);
4792 return(nexus_info->pixels);
4798 number_pixels=(MagickSizeType) nexus_info->region.width*
4799 nexus_info->region.height;
4803 if (nexus_info->cache == (Quantum *) NULL)
4805 nexus_info->length=length;
4806 status=AcquireCacheNexusPixels(cache_info,nexus_info,exception);
4809 nexus_info->length=0;
4814 if (nexus_info->length < length)
4816 RelinquishCacheNexusPixels(nexus_info);
4817 nexus_info->length=length;
4818 status=AcquireCacheNexusPixels(cache_info,nexus_info,exception);
4821 nexus_info->length=0;
4825 nexus_info->pixels=nexus_info->cache;
4826 nexus_info->metacontent=(void *) NULL;
4828 nexus_info->metacontent=(void *) (nexus_info->pixels+number_pixels*
4830 PrefetchPixelCacheNexusPixels(nexus_info,mode);
4831 nexus_info->authentic_pixel_cache=IsPixelCacheAuthentic(cache_info,
4832 nexus_info);
4833 return(nexus_info->pixels);
5036 % NexusInfo *nexus_info,ExceptionInfo *exception)
5042 % o nexus_info: the cache nexus to sync.
5048 NexusInfo *magick_restrict nexus_info,ExceptionInfo *exception)
5067 if (nexus_info->authentic_pixel_cache != MagickFalse)
5073 status=WritePixelCachePixels(cache_info,nexus_info,exception);
5075 (WritePixelCacheMetacontent(cache_info,nexus_info,exception) == MagickFalse))
5128 status=SyncAuthenticPixelCacheNexus(image,cache_info->nexus_info[id],
5186 status=SyncAuthenticPixelCacheNexus(image,cache_info->nexus_info[id],
5249 % NexusInfo *nexus_info,ExceptionInfo *exception)
5255 % o nexus_info: the cache nexus to write the meta-content.
5261 NexusInfo *magick_restrict nexus_info,ExceptionInfo *exception)
5282 if (nexus_info->authentic_pixel_cache != MagickFalse)
5284 offset=(MagickOffsetType) nexus_info->region.y*cache_info->columns+
5285 nexus_info->region.x;
5286 length=(MagickSizeType) nexus_info->region.width*
5288 extent=(MagickSizeType) length*nexus_info->region.height;
5289 rows=nexus_info->region.height;
5291 p=(unsigned char *) nexus_info->metacontent;
5303 if ((cache_info->columns == nexus_info->region.width) &&
5314 p+=nexus_info->region.width*cache_info->metacontent_extent;
5332 if ((cache_info->columns == nexus_info->region.width) &&
5346 p+=cache_info->metacontent_extent*nexus_info->region.width;
5363 region=nexus_info->region;
5364 if ((cache_info->columns != nexus_info->region.width) ||
5378 p+=cache_info->metacontent_extent*nexus_info->region.width;
5394 (CacheTick(nexus_info->region.y,cache_info->rows) != MagickFalse))
5397 nexus_info->region.width,(double) nexus_info->region.height,(double)
5398 nexus_info->region.x,(double) nexus_info->region.y);
5420 % NexusInfo *nexus_info,ExceptionInfo *exception)
5426 % o nexus_info: the cache nexus to write the pixels.
5432 CacheInfo *magick_restrict cache_info,NexusInfo *magick_restrict nexus_info,
5452 if (nexus_info->authentic_pixel_cache != MagickFalse)
5454 offset=(MagickOffsetType) nexus_info->region.y*cache_info->columns+
5455 nexus_info->region.x;
5456 length=(MagickSizeType) cache_info->number_channels*nexus_info->region.width*
5458 extent=length*nexus_info->region.height;
5459 rows=nexus_info->region.height;
5461 p=nexus_info->pixels;
5473 if ((cache_info->columns == nexus_info->region.width) &&
5483 p+=cache_info->number_channels*nexus_info->region.width;
5501 if ((cache_info->columns == nexus_info->region.width) &&
5514 p+=cache_info->number_channels*nexus_info->region.width;
5531 region=nexus_info->region;
5532 if ((cache_info->columns != nexus_info->region.width) ||
5546 p+=cache_info->number_channels*nexus_info->region.width;
5562 (CacheTick(nexus_info->region.y,cache_info->rows) != MagickFalse))
5565 nexus_info->region.width,(double) nexus_info->region.height,(double)
5566 nexus_info->region.x,(double) nexus_info->region.y);