- Add ImageMagick 6.8.3-1 sources
This commit is contained in:
parent
b8db71063c
commit
615ec83706
3424 changed files with 1398702 additions and 0 deletions
237
ImageMagick-6.8.3-1/www/source/analyze.c
Normal file
237
ImageMagick-6.8.3-1/www/source/analyze.c
Normal file
|
@ -0,0 +1,237 @@
|
|||
/*
|
||||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
% %
|
||||
% %
|
||||
% AAA N N AAA L Y Y ZZZZZ EEEEE %
|
||||
% A A NN N A A L Y Y ZZ E %
|
||||
% AAAAA N N N AAAAA L Y ZZZ EEE %
|
||||
% A A N NN A A L Y ZZ E %
|
||||
% A A N N A A LLLLL Y ZZZZZ EEEEE %
|
||||
% %
|
||||
% Analyze An Image %
|
||||
% %
|
||||
% Software Design %
|
||||
% Bill Corbis %
|
||||
% December 1998 %
|
||||
% %
|
||||
% %
|
||||
% Copyright 1999-2011 ImageMagick Studio LLC, a non-profit organization %
|
||||
% dedicated to making software imaging solutions freely available. %
|
||||
% %
|
||||
% You may not use this file except in compliance with the License. You may %
|
||||
% obtain a copy of the License at %
|
||||
% %
|
||||
% http://www.imagemagick.org/script/license.php %
|
||||
% %
|
||||
% Unless required by applicable law or agreed to in writing, software %
|
||||
% distributed under the License is distributed on an "AS IS" BASIS, %
|
||||
% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. %
|
||||
% See the License for the specific language governing permissions and %
|
||||
% limitations under the License. %
|
||||
% %
|
||||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
%
|
||||
*/
|
||||
|
||||
/*
|
||||
Include declarations.
|
||||
*/
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <time.h>
|
||||
#include <assert.h>
|
||||
#include <math.h>
|
||||
#include "magick/MagickCore.h"
|
||||
|
||||
/*
|
||||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
% %
|
||||
% %
|
||||
% %
|
||||
% a n a l y z e I m a g e %
|
||||
% %
|
||||
% %
|
||||
% %
|
||||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
%
|
||||
% analyzeImage() computes the brightness and saturation mean, standard
|
||||
% deviation, kurtosis and skewness and stores these values as attributes
|
||||
% of the image.
|
||||
%
|
||||
% The format of the analyzeImage method is:
|
||||
%
|
||||
% size_t analyzeImage(Image *images,const int argc,
|
||||
% char **argv,ExceptionInfo *exception)
|
||||
%
|
||||
% A description of each parameter follows:
|
||||
%
|
||||
% o image: the address of a structure of type Image.
|
||||
%
|
||||
% o argc: Specifies a pointer to an integer describing the number of
|
||||
% elements in the argument vector.
|
||||
%
|
||||
% o argv: Specifies a pointer to a text array containing the command line
|
||||
% arguments.
|
||||
%
|
||||
% o exception: return any errors or warnings in this structure.
|
||||
%
|
||||
*/
|
||||
ModuleExport size_t analyzeImage(Image **images,const int argc,
|
||||
const char **argv,ExceptionInfo *exception)
|
||||
{
|
||||
char
|
||||
text[MaxTextExtent];
|
||||
|
||||
double
|
||||
area,
|
||||
brightness,
|
||||
brightness_mean,
|
||||
brightness_standard_deviation,
|
||||
brightness_kurtosis,
|
||||
brightness_skewness,
|
||||
brightness_sum_x,
|
||||
brightness_sum_x2,
|
||||
brightness_sum_x3,
|
||||
brightness_sum_x4,
|
||||
hue,
|
||||
saturation,
|
||||
saturation_mean,
|
||||
saturation_standard_deviation,
|
||||
saturation_kurtosis,
|
||||
saturation_skewness,
|
||||
saturation_sum_x,
|
||||
saturation_sum_x2,
|
||||
saturation_sum_x3,
|
||||
saturation_sum_x4;
|
||||
|
||||
Image
|
||||
*image;
|
||||
|
||||
assert(images != (Image **) NULL);
|
||||
assert(*images != (Image *) NULL);
|
||||
assert((*images)->signature == MagickSignature);
|
||||
(void) argc;
|
||||
(void) argv;
|
||||
image=(*images);
|
||||
for ( ; image != (Image *) NULL; image=GetNextImageInList(image))
|
||||
{
|
||||
CacheView
|
||||
*image_view;
|
||||
|
||||
MagickBooleanType
|
||||
status;
|
||||
|
||||
ssize_t
|
||||
y;
|
||||
|
||||
brightness_sum_x=0.0;
|
||||
brightness_sum_x2=0.0;
|
||||
brightness_sum_x3=0.0;
|
||||
brightness_sum_x4=0.0;
|
||||
brightness_mean=0.0;
|
||||
brightness_standard_deviation=0.0;
|
||||
brightness_kurtosis=0.0;
|
||||
brightness_skewness=0.0;
|
||||
saturation_sum_x=0.0;
|
||||
saturation_sum_x2=0.0;
|
||||
saturation_sum_x3=0.0;
|
||||
saturation_sum_x4=0.0;
|
||||
saturation_mean=0.0;
|
||||
saturation_standard_deviation=0.0;
|
||||
saturation_kurtosis=0.0;
|
||||
saturation_skewness=0.0;
|
||||
area=0.0;
|
||||
status=MagickTrue;
|
||||
image_view=AcquireCacheView(image);
|
||||
#if defined(MAGICKCORE_OPENMP_SUPPORT)
|
||||
#pragma omp parallel for schedule(dynamic,4) shared(status)
|
||||
#endif
|
||||
for (y=0; y < (ssize_t) image->rows; y++)
|
||||
{
|
||||
register const PixelPacket
|
||||
*p;
|
||||
|
||||
register ssize_t
|
||||
x;
|
||||
|
||||
if (status == MagickFalse)
|
||||
continue;
|
||||
p=GetCacheViewVirtualPixels(image_view,0,y,image->columns,1,exception);
|
||||
if (p == (const PixelPacket *) NULL)
|
||||
{
|
||||
status=MagickFalse;
|
||||
continue;
|
||||
}
|
||||
for (x=0; x < (ssize_t) image->columns; x++)
|
||||
{
|
||||
ConvertRGBToHSB(GetPixelRed(p),GetPixelGreen(p),
|
||||
GetPixelBlue(p),&hue,&saturation,&brightness);
|
||||
brightness*=QuantumRange;
|
||||
brightness_sum_x+=brightness;
|
||||
brightness_sum_x2+=brightness*brightness;
|
||||
brightness_sum_x3+=brightness*brightness*brightness;
|
||||
brightness_sum_x4+=brightness*brightness*brightness*brightness;
|
||||
saturation*=QuantumRange;
|
||||
saturation_sum_x+=saturation;
|
||||
saturation_sum_x2+=saturation*saturation;
|
||||
saturation_sum_x3+=saturation*saturation*saturation;
|
||||
saturation_sum_x4+=saturation*saturation*saturation*saturation;
|
||||
area++;
|
||||
p++;
|
||||
}
|
||||
}
|
||||
image_view=DestroyCacheView(image_view);
|
||||
if (area <= 0.0)
|
||||
break;
|
||||
brightness_mean=brightness_sum_x/area;
|
||||
(void) FormatMagickString(text,MaxTextExtent,"%g",brightness_mean);
|
||||
(void) SetImageProperty(image,"filter:brightness:mean",text);
|
||||
brightness_standard_deviation=sqrt(brightness_sum_x2/area-(brightness_sum_x/
|
||||
area*brightness_sum_x/area));
|
||||
(void) FormatMagickString(text,MaxTextExtent,"%g",
|
||||
brightness_standard_deviation);
|
||||
(void) SetImageProperty(image,"filter:brightness:standard-deviation",text);
|
||||
if (brightness_standard_deviation != 0)
|
||||
brightness_kurtosis=(brightness_sum_x4/area-4.0*brightness_mean*
|
||||
brightness_sum_x3/area+6.0*brightness_mean*brightness_mean*
|
||||
brightness_sum_x2/area-3.0*brightness_mean*brightness_mean*
|
||||
brightness_mean*brightness_mean)/(brightness_standard_deviation*
|
||||
brightness_standard_deviation*brightness_standard_deviation*
|
||||
brightness_standard_deviation)-3.0;
|
||||
(void) FormatMagickString(text,MaxTextExtent,"%g",brightness_kurtosis);
|
||||
(void) SetImageProperty(image,"filter:brightness:kurtosis",text);
|
||||
if (brightness_standard_deviation != 0)
|
||||
brightness_skewness=(brightness_sum_x3/area-3.0*brightness_mean*
|
||||
brightness_sum_x2/area+2.0*brightness_mean*brightness_mean*
|
||||
brightness_mean)/(brightness_standard_deviation*
|
||||
brightness_standard_deviation*brightness_standard_deviation);
|
||||
(void) FormatMagickString(text,MaxTextExtent,"%g",brightness_skewness);
|
||||
(void) SetImageProperty(image,"filter:brightness:skewness",text);
|
||||
saturation_mean=saturation_sum_x/area;
|
||||
(void) FormatMagickString(text,MaxTextExtent,"%g",saturation_mean);
|
||||
(void) SetImageProperty(image,"filter:saturation:mean",text);
|
||||
saturation_standard_deviation=sqrt(saturation_sum_x2/area-(saturation_sum_x/
|
||||
area*saturation_sum_x/area));
|
||||
(void) FormatMagickString(text,MaxTextExtent,"%g",
|
||||
saturation_standard_deviation);
|
||||
(void) SetImageProperty(image,"filter:saturation:standard-deviation",text);
|
||||
if (saturation_standard_deviation != 0)
|
||||
saturation_kurtosis=(saturation_sum_x4/area-4.0*saturation_mean*
|
||||
saturation_sum_x3/area+6.0*saturation_mean*saturation_mean*
|
||||
saturation_sum_x2/area-3.0*saturation_mean*saturation_mean*
|
||||
saturation_mean*saturation_mean)/(saturation_standard_deviation*
|
||||
saturation_standard_deviation*saturation_standard_deviation*
|
||||
saturation_standard_deviation)-3.0;
|
||||
(void) FormatMagickString(text,MaxTextExtent,"%g",saturation_kurtosis);
|
||||
(void) SetImageProperty(image,"filter:saturation:kurtosis",text);
|
||||
if (saturation_standard_deviation != 0)
|
||||
saturation_skewness=(saturation_sum_x3/area-3.0*saturation_mean*
|
||||
saturation_sum_x2/area+2.0*saturation_mean*saturation_mean*
|
||||
saturation_mean)/(saturation_standard_deviation*
|
||||
saturation_standard_deviation*saturation_standard_deviation);
|
||||
(void) FormatMagickString(text,MaxTextExtent,"%g",saturation_skewness);
|
||||
(void) SetImageProperty(image,"filter:saturation:skewness",text);
|
||||
}
|
||||
return(MagickImageFilterSignature);
|
||||
}
|
22
ImageMagick-6.8.3-1/www/source/coder.xml
Normal file
22
ImageMagick-6.8.3-1/www/source/coder.xml
Normal file
|
@ -0,0 +1,22 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE codermap [
|
||||
<!ELEMENT codermap (coder)*>
|
||||
<!ELEMENT coder (#PCDATA)>
|
||||
<!ATTLIST coder magick CDATA #REQUIRED>
|
||||
<!ATTLIST coder name CDATA #REQUIRED>
|
||||
]>
|
||||
<!--
|
||||
Associate an image format with the specified coder module.
|
||||
|
||||
ImageMagick has a number of coder modules to support the reading and/or
|
||||
writing of an image format (e.g. JPEG). Some coder modules support more
|
||||
than one associated image format and the mapping between an associated
|
||||
format and its respective coder module is defined in this configuration
|
||||
file. For example, the PNG coder module not only supports the PNG image
|
||||
format, but the JNG and MNG formats as well.
|
||||
-->
|
||||
<codermap>
|
||||
<!-- <coder magick="GIF87" name="GIF"/> -->
|
||||
<!-- <coder magick="JPG" name="JPEG"/> -->
|
||||
<!-- <coder magick="PGM" name="PNM"/> -->
|
||||
</codermap>
|
28
ImageMagick-6.8.3-1/www/source/colors.xml
Normal file
28
ImageMagick-6.8.3-1/www/source/colors.xml
Normal file
|
@ -0,0 +1,28 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE colormap [
|
||||
<!ELEMENT colormap (color)+>
|
||||
<!ELEMENT color (#PCDATA)>
|
||||
<!ATTLIST color name CDATA "0">
|
||||
<!ATTLIST color color CDATA "rgb(0,0,0)">
|
||||
<!ATTLIST color compliance CDATA "SVG">
|
||||
]>
|
||||
<!--
|
||||
Associate a color name with its red, green, blue, and alpha intensities.
|
||||
|
||||
A number of methods and options require a color parameter. It is often
|
||||
convenient to refer to a color by name (e.g. white) rather than by hex
|
||||
value (e.g. #fff). This file maps a color name to its equivalent red,
|
||||
green, blue, and alpha intensities (e.g. for white, red = 255, green =
|
||||
255, blue = 255, and alpha = 0).
|
||||
-->
|
||||
<colormap>
|
||||
<!-- <color name="none" color="rgba(0,0,0,0)" compliance="SVG, XPM"/> -->
|
||||
<!-- <color name="black" color="rgb(0,0,0)" compliance="SVG, X11, XPM"/> -->
|
||||
<!-- <color name="red" color="rgb(255,0,0)" compliance="SVG, X11, XPM"/> -->
|
||||
<!-- <color name="magenta" color="rgb(255,0,255)" compliance="SVG, X11, XPM"/> -->
|
||||
<!-- <color name="green" color="rgb(0,128,0)" compliance="SVG"/> -->
|
||||
<!-- <color name="cyan" color="rgb(0,255,255)" compliance="SVG, X11, XPM"/> -->
|
||||
<!-- <color name="blue" color="rgb(0,0,255)" compliance="SVG, X11, XPM"/> -->
|
||||
<!-- <color name="yellow" color="rgb(255,255,0)" compliance="SVG, X11, XPM"/> -->
|
||||
<!-- <color name="white" color="rgb(255,255,255)" compliance="SVG, X11"/> -->
|
||||
</colormap>
|
45
ImageMagick-6.8.3-1/www/source/configure.xml
Normal file
45
ImageMagick-6.8.3-1/www/source/configure.xml
Normal file
|
@ -0,0 +1,45 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE configuremap [
|
||||
<!ELEMENT configuremap (configure)+>
|
||||
<!ELEMENT configure (#PCDATA)>
|
||||
<!ATTLIST configure name CDATA #REQUIRED>
|
||||
<!ATTLIST configure value CDATA #REQUIRED>
|
||||
]>
|
||||
<configuremap>
|
||||
<configure name="NAME" value="ImageMagick"/>
|
||||
<configure name="VERSION" value="7.0.0"/>
|
||||
<configure name="LIB_VERSION" value="0x700"/>
|
||||
<configure name="LIB_VERSION_NUMBER" value="7,0,0,0"/>
|
||||
<configure name="SVN_REVISION" value="5819" />
|
||||
<configure name="RELEASE_DATE" value="2011-10-30"/>
|
||||
<configure name="CONFIGURE" value="./configure "/>
|
||||
<configure name="PREFIX" value="/usr/local"/>
|
||||
<configure name="EXEC-PREFIX" value="/usr/local"/>
|
||||
<configure name="INCLUDE_PATH" value="/usr/local/include/ImageMagick"/>
|
||||
<configure name="CONFIGURE_PATH" value="/usr/local/etc/ImageMagick/"/>
|
||||
<configure name="SHARE_PATH" value="/usr/local/share/ImageMagick-7.0.0"/>
|
||||
<configure name="DOCUMENTATION_PATH" value="/usr/local/share/doc/ImageMagick/"/>
|
||||
<configure name="EXECUTABLE_PATH" value="/usr/local/bin"/>
|
||||
<configure name="LIBRARY_PATH" value="/usr/local/lib/ImageMagick-7.0.0"/>
|
||||
<configure name="CODER_PATH" value="/usr/local/lib/ImageMagick-7.0.0/modules-Q16/coders"/>
|
||||
<configure name="FILTER_PATH" value="/usr/local/lib/ImageMagick-7.0.0/modules-Q16/filters"/>
|
||||
<configure name="CC" value="gcc -std=gnu99 -std=gnu99"/>
|
||||
<configure name="CFLAGS" value="-fopenmp -g -O2 -Wall -pthread"/>
|
||||
<configure name="CPPFLAGS" value="-I/usr/local/include/ImageMagick"/>
|
||||
<configure name="PCFLAGS" value="-fopenmp"/>
|
||||
<configure name="DEFS" value="-DHAVE_CONFIG_H"/>
|
||||
<configure name="LDFLAGS" value="-L/usr/local/lib -L/usr/lib"/>
|
||||
<configure name="LIBS" value="-lMagickCore -llcms2 -ltiff -lfreetype -ljasper -ljpeg -lpng12 -ldjvulibre -lfontconfig -lXext -lXt -lSM -lICE -lX11 -llzma -lbz2 -pthread -lpangoft2-1.0 -lpango-1.0 -lfreetype -lfontconfig -lgobject-2.0 -lgmodule-2.0 -lgthread-2.0 -lrt -lglib-2.0 -lxml2 -lgvc -lgraph -lcdt -lz -lm -lgomp -lpthread -lltdl"/>
|
||||
<configure name="CXX" value="g++"/>
|
||||
<configure name="CXXFLAGS" value="-g -O2 -pthread"/>
|
||||
<configure name="DISTCHECK_CONFIG_FLAGS" value="--disable-deprecated --with-quantum-depth=16 --with-umem=no --with-autotrace=no --with-gslib=no --with-fontpath= --with-perl=no"/>
|
||||
<configure name="TARGET_CPU" value="x86_64"/>
|
||||
<configure name="TARGET_VENDOR" value="unknown"/>
|
||||
<configure name="TARGET_OS" value="linux-gnu"/>
|
||||
<configure name="HOST" value="x86_64-unknown-linux-gnu"/>
|
||||
<configure name="FEATURES" value="OpenMP "/>
|
||||
<configure name="DELEGATES" value="bzlib djvu fontconfig freetype gvc jpeg jng jp2 lcms2 lzma png tiff x11 xml zlib"/>
|
||||
<configure name="COPYRIGHT" value="Copyright (C) 1999-2011 ImageMagick Studio LLC"/>
|
||||
<configure name="WEBSITE" value="http://www.imagemagick.org"/>
|
||||
<configure name="QuantumDepth" value="16"/>
|
||||
</configuremap>
|
106
ImageMagick-6.8.3-1/www/source/contrast.c
Normal file
106
ImageMagick-6.8.3-1/www/source/contrast.c
Normal file
|
@ -0,0 +1,106 @@
|
|||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <math.h>
|
||||
#include <wand/MagickWand.h>
|
||||
|
||||
int main(int argc,char **argv)
|
||||
{
|
||||
#define QuantumScale ((MagickRealType) 1.0/(MagickRealType) QuantumRange)
|
||||
#define SigmoidalContrast(x) \
|
||||
(QuantumRange*(1.0/(1+exp(10.0*(0.5-QuantumScale*x)))-0.0066928509)*1.0092503)
|
||||
#define ThrowWandException(wand) \
|
||||
{ \
|
||||
char \
|
||||
*description; \
|
||||
\
|
||||
ExceptionType \
|
||||
severity; \
|
||||
\
|
||||
description=MagickGetException(wand,&severity); \
|
||||
(void) fprintf(stderr,"%s %s %lu %s\n",GetMagickModule(),description); \
|
||||
description=(char *) MagickRelinquishMemory(description); \
|
||||
exit(-1); \
|
||||
}
|
||||
|
||||
MagickBooleanType
|
||||
status;
|
||||
|
||||
MagickPixelPacket
|
||||
pixel;
|
||||
|
||||
MagickWand
|
||||
*contrast_wand,
|
||||
*image_wand;
|
||||
|
||||
PixelIterator
|
||||
*contrast_iterator,
|
||||
*iterator;
|
||||
|
||||
PixelWand
|
||||
**contrast_pixels,
|
||||
**pixels;
|
||||
|
||||
register ssize_t
|
||||
x;
|
||||
|
||||
size_t
|
||||
width;
|
||||
|
||||
ssize_t
|
||||
y;
|
||||
|
||||
if (argc != 3)
|
||||
{
|
||||
(void) fprintf(stdout,"Usage: %s image sigmoidal-image\n",argv[0]);
|
||||
exit(0);
|
||||
}
|
||||
/*
|
||||
Read an image.
|
||||
*/
|
||||
MagickWandGenesis();
|
||||
image_wand=NewMagickWand();
|
||||
status=MagickReadImage(image_wand,argv[1]);
|
||||
if (status == MagickFalse)
|
||||
ThrowWandException(image_wand);
|
||||
contrast_wand=CloneMagickWand(image_wand);
|
||||
/*
|
||||
Sigmoidal non-linearity contrast control.
|
||||
*/
|
||||
iterator=NewPixelIterator(image_wand);
|
||||
contrast_iterator=NewPixelIterator(contrast_wand);
|
||||
if ((iterator == (PixelIterator *) NULL) ||
|
||||
(contrast_iterator == (PixelIterator *) NULL))
|
||||
ThrowWandException(image_wand);
|
||||
for (y=0; y < (ssize_t) MagickGetImageHeight(image_wand); y++)
|
||||
{
|
||||
pixels=PixelGetNextIteratorRow(iterator,&width);
|
||||
contrast_pixels=PixelGetNextIteratorRow(contrast_iterator,&width);
|
||||
if ((pixels == (PixelWand **) NULL) ||
|
||||
(contrast_pixels == (PixelWand **) NULL))
|
||||
break;
|
||||
for (x=0; x < (ssize_t) width; x++)
|
||||
{
|
||||
PixelGetMagickColor(pixels[x],&pixel);
|
||||
pixel.red=SigmoidalContrast(pixel.red);
|
||||
pixel.green=SigmoidalContrast(pixel.green);
|
||||
pixel.blue=SigmoidalContrast(pixel.blue);
|
||||
pixel.index=SigmoidalContrast(pixel.index);
|
||||
PixelSetMagickColor(contrast_pixels[x],&pixel);
|
||||
}
|
||||
(void) PixelSyncIterator(contrast_iterator);
|
||||
}
|
||||
if (y < (ssize_t) MagickGetImageHeight(image_wand))
|
||||
ThrowWandException(image_wand);
|
||||
contrast_iterator=DestroyPixelIterator(contrast_iterator);
|
||||
iterator=DestroyPixelIterator(iterator);
|
||||
image_wand=DestroyMagickWand(image_wand);
|
||||
/*
|
||||
Write the image then destroy it.
|
||||
*/
|
||||
status=MagickWriteImages(contrast_wand,argv[2],MagickTrue);
|
||||
if (status == MagickFalse)
|
||||
ThrowWandException(image_wand);
|
||||
contrast_wand=DestroyMagickWand(contrast_wand);
|
||||
MagickWandTerminus();
|
||||
return(0);
|
||||
}
|
63
ImageMagick-6.8.3-1/www/source/core.c
Normal file
63
ImageMagick-6.8.3-1/www/source/core.c
Normal file
|
@ -0,0 +1,63 @@
|
|||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <time.h>
|
||||
#include <magick/MagickCore.h>
|
||||
|
||||
int main(int argc,char **argv)
|
||||
{
|
||||
ExceptionInfo
|
||||
*exception;
|
||||
|
||||
Image
|
||||
*image,
|
||||
*images,
|
||||
*resize_image,
|
||||
*thumbnails;
|
||||
|
||||
ImageInfo
|
||||
*image_info;
|
||||
|
||||
if (argc != 3)
|
||||
{
|
||||
(void) fprintf(stdout,"Usage: %s image thumbnail\n",argv[0]);
|
||||
exit(0);
|
||||
}
|
||||
/*
|
||||
Initialize the image info structure and read an image.
|
||||
*/
|
||||
MagickCoreGenesis(*argv,MagickTrue);
|
||||
exception=AcquireExceptionInfo();
|
||||
image_info=CloneImageInfo((ImageInfo *) NULL);
|
||||
(void) strcpy(image_info->filename,argv[1]);
|
||||
images=ReadImage(image_info,exception);
|
||||
if (exception->severity != UndefinedException)
|
||||
CatchException(exception);
|
||||
if (images == (Image *) NULL)
|
||||
exit(1);
|
||||
/*
|
||||
Convert the image to a thumbnail.
|
||||
*/
|
||||
thumbnails=NewImageList();
|
||||
while ((image=RemoveFirstImageFromList(&images)) != (Image *) NULL)
|
||||
{
|
||||
resize_image=ResizeImage(image,106,80,LanczosFilter,1.0,exception);
|
||||
if (resize_image == (Image *) NULL)
|
||||
MagickError(exception->severity,exception->reason,exception->description);
|
||||
(void) AppendImageToList(&thumbnails,resize_image);
|
||||
DestroyImage(image);
|
||||
}
|
||||
/*
|
||||
Write the image thumbnail.
|
||||
*/
|
||||
(void) strcpy(thumbnails->filename,argv[2]);
|
||||
WriteImage(image_info,thumbnails);
|
||||
/*
|
||||
Destroy the image thumbnail and exit.
|
||||
*/
|
||||
thumbnails=DestroyImageList(thumbnails);
|
||||
image_info=DestroyImageInfo(image_info);
|
||||
exception=DestroyExceptionInfo(exception);
|
||||
MagickCoreTerminus();
|
||||
return(0);
|
||||
}
|
116
ImageMagick-6.8.3-1/www/source/core/sigmoidal-contrast.c
Normal file
116
ImageMagick-6.8.3-1/www/source/core/sigmoidal-contrast.c
Normal file
|
@ -0,0 +1,116 @@
|
|||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <math.h>
|
||||
#include <magick/MagickCore.h>
|
||||
|
||||
static MagickBooleanType SigmoidalContrast(ImageView *contrast_view,
|
||||
const ssize_t y,const int id,void *context)
|
||||
{
|
||||
#define QuantumScale ((MagickRealType) 1.0/(MagickRealType) QuantumRange)
|
||||
#define SigmoidalContrast(x) \
|
||||
(QuantumRange*(1.0/(1+exp(10.0*(0.5-QuantumScale*x)))-0.0066928509)*1.0092503)
|
||||
|
||||
RectangleInfo
|
||||
extent;
|
||||
|
||||
register IndexPacket
|
||||
*indexes;
|
||||
|
||||
register PixelPacket
|
||||
*pixels;
|
||||
|
||||
register ssize_t
|
||||
x;
|
||||
|
||||
extent=GetImageViewExtent(contrast_view);
|
||||
pixels=GetImageViewAuthenticPixels(contrast_view);
|
||||
for (x=0; x < (ssize_t) (extent.width-extent.height); x++)
|
||||
{
|
||||
pixels[x].red=RoundToQuantum(SigmoidalContrast(pixels[x].red));
|
||||
pixels[x].green=RoundToQuantum(SigmoidalContrast(pixels[x].green));
|
||||
pixels[x].blue=RoundToQuantum(SigmoidalContrast(pixels[x].blue));
|
||||
pixels[x].opacity=RoundToQuantum(SigmoidalContrast(pixels[x].opacity));
|
||||
}
|
||||
indexes=GetImageViewAuthenticIndexes(contrast_view);
|
||||
if (indexes != (IndexPacket *) NULL)
|
||||
for (x=0; x < (ssize_t) (extent.width-extent.height); x++)
|
||||
indexes[x]=(IndexPacket) RoundToQuantum(SigmoidalContrast(indexes[x]));
|
||||
return(MagickTrue);
|
||||
}
|
||||
|
||||
int main(int argc,char **argv)
|
||||
{
|
||||
#define ThrowImageException(image) \
|
||||
{ \
|
||||
\
|
||||
CatchException(exception); \
|
||||
if (contrast_image != (Image *) NULL) \
|
||||
contrast_image=DestroyImage(contrast_image); \
|
||||
exit(-1); \
|
||||
}
|
||||
#define ThrowViewException(view) \
|
||||
{ \
|
||||
char \
|
||||
*description; \
|
||||
\
|
||||
ExceptionType \
|
||||
severity; \
|
||||
\
|
||||
description=GetImageViewException(view,&severity); \
|
||||
(void) fprintf(stderr,"%s %s %lu %s\n",GetMagickModule(),description); \
|
||||
description=(char *) MagickRelinquishMemory(description); \
|
||||
exit(-1); \
|
||||
}
|
||||
|
||||
ExceptionInfo
|
||||
*exception;
|
||||
|
||||
Image
|
||||
*contrast_image;
|
||||
|
||||
ImageInfo
|
||||
*image_info;
|
||||
|
||||
ImageView
|
||||
*contrast_view;
|
||||
|
||||
MagickBooleanType
|
||||
status;
|
||||
|
||||
if (argc != 3)
|
||||
{
|
||||
(void) fprintf(stdout,"Usage: %s image sigmoidal-image\n",argv[0]);
|
||||
exit(0);
|
||||
}
|
||||
/*
|
||||
Read an image.
|
||||
*/
|
||||
MagickCoreGenesis(*argv,MagickTrue);
|
||||
image_info=AcquireImageInfo();
|
||||
(void) CopyMagickString(image_info->filename,argv[1],MaxTextExtent);
|
||||
exception=AcquireExceptionInfo();
|
||||
contrast_image=ReadImage(image_info,exception);
|
||||
if (contrast_image == (Image *) NULL)
|
||||
ThrowImageException(contrast_image);
|
||||
/*
|
||||
Sigmoidal non-linearity contrast control.
|
||||
*/
|
||||
contrast_view=NewImageView(contrast_image);
|
||||
if (contrast_view == (ImageView *) NULL)
|
||||
ThrowImageException(contrast_image);
|
||||
status=UpdateImageViewIterator(contrast_view,SigmoidalContrast,(void *) NULL);
|
||||
if (status == MagickFalse)
|
||||
ThrowImageException(contrast_image);
|
||||
contrast_view=DestroyImageView(contrast_view);
|
||||
/*
|
||||
Write the image then destroy it.
|
||||
*/
|
||||
status=WriteImages(image_info,contrast_image,argv[2],exception);
|
||||
if (status == MagickFalse)
|
||||
ThrowImageException(contrast_image);
|
||||
contrast_image=DestroyImage(contrast_image);
|
||||
exception=DestroyExceptionInfo(exception);
|
||||
image_info=DestroyImageInfo(image_info);
|
||||
MagickCoreTerminus();
|
||||
return(0);
|
||||
}
|
112
ImageMagick-6.8.3-1/www/source/delegates.xml
Normal file
112
ImageMagick-6.8.3-1/www/source/delegates.xml
Normal file
|
@ -0,0 +1,112 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE delegatemap [
|
||||
<!ELEMENT delegatemap (delegate)+>
|
||||
<!ELEMENT delegate (#PCDATA)>
|
||||
<!ATTLIST delegate decode CDATA #IMPLIED>
|
||||
<!ATTLIST delegate encode CDATA #IMPLIED>
|
||||
<!ATTLIST delegate mode CDATA #IMPLIED>
|
||||
<!ATTLIST delegate spawn CDATA #IMPLIED>
|
||||
<!ATTLIST delegate stealth CDATA #IMPLIED>
|
||||
<!ATTLIST delegate thread-support CDATA #IMPLIED>
|
||||
<!ATTLIST delegate command CDATA #REQUIRED>
|
||||
]>
|
||||
<!--
|
||||
Delegate command file.
|
||||
|
||||
Commands which specify
|
||||
|
||||
decode="in_format" encode="out_format"
|
||||
|
||||
specify the rules for converting from in_format to out_format These
|
||||
rules may be used to translate directly between formats.
|
||||
|
||||
Commands which specify only
|
||||
|
||||
decode="in_format"
|
||||
|
||||
specify the rules for converting from in_format to some format that
|
||||
ImageMagick will automatically recognize. These rules are used to
|
||||
decode formats.
|
||||
|
||||
Commands which specify only
|
||||
|
||||
encode="out_format"
|
||||
|
||||
specify the rules for an "encoder" which may accept any input format.
|
||||
|
||||
For delegates other than ps:*, pcl:*, and mpeg:* the substitution rules are
|
||||
as follows:
|
||||
|
||||
%i input image filename
|
||||
%o output image filename
|
||||
%u unique temporary filename
|
||||
%Z unique temporary filename
|
||||
%# input image signature
|
||||
%b image file size
|
||||
%c input image comment
|
||||
%g image geometry
|
||||
%h image rows (height)
|
||||
%k input image number colors
|
||||
%l image label
|
||||
%m input image format
|
||||
%p page number
|
||||
%q input image depth
|
||||
%s scene number
|
||||
%w image columns (width)
|
||||
%x input image x resolution
|
||||
%y input image y resolution
|
||||
|
||||
Set option delegate:bimodal=true to process bimodal delegates otherwise they
|
||||
are ignored.
|
||||
-->
|
||||
<delegatemap>
|
||||
<delegate decode="autotrace" stealth="True" command=""convert" "%i" "pnm:%u"\n"autotrace" -input-format pnm -output-format svg -output-file "%o" "%u""/>
|
||||
<delegate decode="blender" command=""blender" -b "%i" -F PNG -o "%o""\n"convert" -concatenate "%o*.png" "%o""/>
|
||||
<delegate decode="browse" stealth="True" spawn="True" command=""xdg-open" http://www.imagemagick.org/"/>
|
||||
<delegate decode="cdr" command=""uniconvertor" "%i" "%o.svg"; mv "%o.svg" "%o""/>
|
||||
<delegate decode="cgm" thread-support="False" command=""ralcgm" -d ps -oC < "%i" > "%o" 2> "%Z""/>
|
||||
<delegate decode="dvi" command=""dvips" -q -o "%o" "%i""/>
|
||||
<delegate decode="dng:decode" command=""ufraw-batch" --silent --create-id=also --out-type=png --out-depth=16 "--output=%u.png" "%i""/>
|
||||
<delegate decode="edit" stealth="True" command=""xterm" -title "Edit Image Comment" -e vi "%o""/>
|
||||
<delegate decode="eps" encode="pdf" mode="bi" command=""gs" -q -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 "-sDEVICE=pdfwrite" "-sOutputFile=%o" "-f%i""/>
|
||||
<delegate decode="eps" encode="ps" mode="bi" command=""gs" -q -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=2 "-sDEVICE=pswrite" "-sOutputFile=%o" "-f%i""/>
|
||||
<delegate decode="fig" command=""fig2dev" -L ps "%i" "%o""/>
|
||||
<delegate decode="plt" command=""echo" "set size 1.25,0.62; set terminal postscript portrait color solid; set output \'%o\'; load \'%i\'" > "%u";"gnuplot" "%u""/>
|
||||
<delegate decode="hpg" command=""hp2xx" -q -m eps -f `basename "%o"` "%i"; mv -f `basename "%o"` "%o""/>
|
||||
<delegate decode="hpgl" command="if [ -e hp2xx -o -e /usr/bin/hp2xx ]; then hp2xx -q -m eps -f `basename "%o"` "%i"; mv -f `basename "%o"` "%o"; else echo "You need to install hp2xx to use HPGL files with ImageMagick."; exit 1; fi"/>
|
||||
<delegate decode="htm" command=""html2ps" -U -o "%o" "%i""/>
|
||||
<delegate decode="html" command=""html2ps" -U -o "%o" "%i""/>
|
||||
<delegate decode="https" command=""curl" -s -k -o "%o" "https:%M""/>
|
||||
<delegate decode="ilbm" command=""ilbmtoppm" "%i" > "%o""/>
|
||||
<delegate decode="man" command=""groff" -man -Tps "%i" > "%o""/>
|
||||
<delegate decode="mpeg:decode" command=""ffmpeg" -v -1 -vframes %S -i "%i" -vcodec pam -an -f rawvideo -y "%u.pam" 2> "%Z""/>
|
||||
<delegate encode="mpeg:encode" stealth="True" command=""ffmpeg" -v -1 -mbd rd -trellis 2 -cmp 2 -subcmp 2 -g 300 -i "%M%%d.jpg" "%u.%m" 2> "%Z""/>
|
||||
<delegate decode="sid" command=""mrsidgeodecode" -if sid -i "%i" -of tif -o "%o" > "%u""/>
|
||||
<delegate decode="pcl:color" stealth="True" command=""pcl6" -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=2 "-sDEVICE=ppmraw" -dTextAlphaBits=%u -dGraphicsAlphaBits=%u "-r%s" %s "-sOutputFile=%s" "%s""/>
|
||||
<delegate decode="pcl:cmyk" stealth="True" command=""pcl6" -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=2 "-sDEVICE=pamcmyk32" -dTextAlphaBits=%u -dGraphicsAlphaBits=%u "-r%s" %s "-sOutputFile=%s" "%s""/>
|
||||
<delegate decode="pcl:mono" stealth="True" command=""pcl6" -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=2 "-sDEVICE=pbmraw" -dTextAlphaBits=%u -dGraphicsAlphaBits=%u "-r%s" %s "-sOutputFile=%s" "%s""/>
|
||||
<delegate decode="pdf" encode="eps" mode="bi" command=""gs" -q -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=2 "-sDEVICE=epswrite" "-sOutputFile=%o" "-f%i""/>
|
||||
<delegate decode="pdf" encode="ps" mode="bi" command=""gs" -q -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=2 "-sDEVICE=pswrite" "-sOutputFile=%o" "-f%i""/>
|
||||
<delegate decode="tiff" encode="launch" mode="encode" command=""gimp" "%i""/>
|
||||
<delegate decode="pnm" encode="ilbm" mode="encode" command=""ppmtoilbm" -24if "%i" > "%o""/>
|
||||
<delegate decode="pov" command=""povray" "+i%i" -D0 +o"%o" +fn%q +w%w +h%h +a -q9 -kfi"%s" -kff"%n"\n"convert" -concatenate "%o*.png" "%o""/>
|
||||
<delegate decode="ps" encode="eps" mode="bi" command=""gs" -q -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=2 "-sDEVICE=epswrite" "-sOutputFile=%o" "-f%i""/>
|
||||
<delegate decode="ps" encode="pdf" mode="bi" command=""gs" -q -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=2 "-sDEVICE=pdfwrite" "-sOutputFile=%o" "-f%i""/>
|
||||
<delegate decode="ps" encode="print" mode="encode" command="lpr "%i""/>
|
||||
<delegate decode="ps:alpha" stealth="True" command=""gs" -q -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=2 "-sDEVICE=pngalpha" -dTextAlphaBits=%u -dGraphicsAlphaBits=%u "-r%s" %s "-sOutputFile=%s" "-f%s" "-f%s""/>
|
||||
<delegate decode="ps:cmyk" stealth="True" command=""gs" -q -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=2 "-sDEVICE=pam" -dTextAlphaBits=%u -dGraphicsAlphaBits=%u "-r%s" %s "-sOutputFile=%s" "-f%s" "-f%s""/>
|
||||
<delegate decode="ps:color" stealth="True" command=""gs" -q -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=2 "-sDEVICE=pnmraw" -dTextAlphaBits=%u -dGraphicsAlphaBits=%u "-r%s" %s "-sOutputFile=%s" "-f%s" "-f%s""/>
|
||||
<delegate decode="ps:mono" stealth="True" command=""gs" -q -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=2 "-sDEVICE=pbmraw" -dTextAlphaBits=%u -dGraphicsAlphaBits=%u "-r%s" %s "-sOutputFile=%s" "-f%s" "-f%s""/>
|
||||
<delegate decode="rgba" encode="rle" mode="encode" command=""rawtorle" -o "%o" -v "%i""/>
|
||||
<delegate decode="scan" command=""scanimage" -d "%i" > "%o""/>
|
||||
<delegate decode="scanx" command=""scanimage" > "%o""/>
|
||||
<delegate decode="miff" encode="show" spawn="True" command=""/usr/local/bin/display" -delay 0 -window-group %[group] -title "%l " "ephemeral:%i""/>
|
||||
<delegate decode="shtml" command=""html2ps" -U -o "%o" "%i""/>
|
||||
<delegate decode="svg" command=""rsvg" "%i" "%o""/>
|
||||
<delegate decode="txt" encode="ps" mode="bi" command=""enscript" -o "%o" "%i""/>
|
||||
<delegate decode="miff" encode="win" stealth="True" spawn="True" command=""/usr/local/bin/display" -immutable -delay 0 -window-group %[group] -title "%l " "ephemeral:%i""/>
|
||||
<delegate decode="wmf" command=""wmf2eps" -o "%o" "%i""/>
|
||||
<delegate decode="xps:color" stealth="True" command=""gxps" -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=2 "-sDEVICE=ppmraw" -dTextAlphaBits=%u -dGraphicsAlphaBits=%u "-r%s" %s "-sOutputFile=%s" "%s""/>
|
||||
<delegate decode="xps:cmyk" stealth="True" command=""gxps" -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=2 "-sDEVICE=bmpsep8" -dTextAlphaBits=%u -dGraphicsAlphaBits=%u "-r%s" %s "-sOutputFile=%s" "%s""/>
|
||||
<delegate decode="xps:mono" stealth="True" command=""gxps" -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=2 "-sDEVICE=pbmraw" -dTextAlphaBits=%u -dGraphicsAlphaBits=%u "-r%s" %s "-sOutputFile=%s" "%s""/>
|
||||
</delegatemap>
|
1577
ImageMagick-6.8.3-1/www/source/english.xml
Normal file
1577
ImageMagick-6.8.3-1/www/source/english.xml
Normal file
File diff suppressed because it is too large
Load diff
460
ImageMagick-6.8.3-1/www/source/examples.pl
Normal file
460
ImageMagick-6.8.3-1/www/source/examples.pl
Normal file
|
@ -0,0 +1,460 @@
|
|||
#!/usr/bin/perl
|
||||
#
|
||||
# Overall demo of the major PerlMagick methods.
|
||||
#
|
||||
use Image::Magick;
|
||||
|
||||
#
|
||||
# Read model & smile image.
|
||||
#
|
||||
print "Read...\n";
|
||||
$null=Image::Magick->new;
|
||||
$null->Set(size=>'70x70');
|
||||
$x=$null->ReadImage('NULL:black');
|
||||
warn "$x" if "$x";
|
||||
|
||||
$model=Image::Magick->new();
|
||||
$x=$model->ReadImage('model.gif');
|
||||
warn "$x" if "$x";
|
||||
$model->Label('Magick');
|
||||
$model->Set(background=>'white');
|
||||
|
||||
$smile=Image::Magick->new;
|
||||
$x=$smile->ReadImage('smile.gif');
|
||||
warn "$x" if "$x";
|
||||
$smile->Label('Smile');
|
||||
$smile->Set(background=>'white');
|
||||
#
|
||||
# Create image stack.
|
||||
#
|
||||
print "Transform image...\n";
|
||||
$images=Image::Magick->new();
|
||||
|
||||
print "Adaptive Blur...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Adaptive Blur');
|
||||
$example->AdaptiveBlur('0x1');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Adaptive Resize...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Adaptive Resize');
|
||||
$example->AdaptiveResize('60%');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Adaptive Sharpen...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Adaptive Sharpen');
|
||||
$example->AdaptiveSharpen('0x1');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Adaptive Threshold...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Adaptive Threshold');
|
||||
$example->AdaptiveThreshold('5x5+5%');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Add Noise...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Add Noise');
|
||||
$example->AddNoise("Laplacian");
|
||||
push(@$images,$example);
|
||||
|
||||
print "Annotate...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Annotate');
|
||||
$example->Annotate(text=>'Magick',geometry=>'+0+20',font=>'Generic.ttf',
|
||||
fill=>'gold',gravity=>'North',pointsize=>14);
|
||||
push(@$images,$example);
|
||||
|
||||
print "Auto-gamma...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Auto Gamma');
|
||||
$example->AutoGamma();
|
||||
push(@$images,$example);
|
||||
|
||||
print "Auto-level...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Auto Level');
|
||||
$example->AutoLevel();
|
||||
push(@$images,$example);
|
||||
|
||||
print "Blur...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Blur');
|
||||
$example->Blur('0.0x1.0');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Border...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Border');
|
||||
$example->Border(geometry=>'6x6',color=>'gold');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Channel...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Channel');
|
||||
$example->Channel(channel=>'red');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Charcoal...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Charcoal');
|
||||
$example->Charcoal('0x1');
|
||||
push(@$images,$example);
|
||||
|
||||
print "ColorMatrix...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('ColorMatrix');
|
||||
$example->ColorMatrix([1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0.5, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1]);
|
||||
push(@$images,$example);
|
||||
|
||||
print "Composite...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Composite');
|
||||
$example->Composite(image=>$smile,compose=>'over',geometry=>'+35+65');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Contrast...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Contrast');
|
||||
$example->Contrast();
|
||||
push(@$images,$example);
|
||||
|
||||
print "Contrast Stretch...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Contrast Stretch');
|
||||
$example->ContrastStretch('5%');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Convolve...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Convolve');
|
||||
$example->Convolve([1, 1, 1, 1, 4, 1, 1, 1, 1]);
|
||||
push(@$images,$example);
|
||||
|
||||
print "Crop...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Crop');
|
||||
$example->Crop(geometry=>'80x80+25+50');
|
||||
$example->Set(page=>'0x0+0+0');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Despeckle...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Despeckle');
|
||||
$example->Despeckle();
|
||||
push(@$images,$example);
|
||||
|
||||
print "Distort...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Distort');
|
||||
$example->Distort(method=>'arc',points=>[60],'virtual-pixel'=>'white');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Draw...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Draw');
|
||||
$example->Draw(fill=>'none',stroke=>'gold',primitive=>'circle',
|
||||
points=>'60,90 60,120',strokewidth=>2);
|
||||
push(@$images,$example);
|
||||
|
||||
print "Detect Edges...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Detect Edges');
|
||||
$example->Edge();
|
||||
push(@$images,$example);
|
||||
|
||||
print "Emboss...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Emboss');
|
||||
$example->Emboss('0x1');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Equalize...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Equalize');
|
||||
$example->Equalize();
|
||||
push(@$images,$example);
|
||||
|
||||
print "Implode...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Explode');
|
||||
$example->Implode(-1);
|
||||
push(@$images,$example);
|
||||
|
||||
print "Flip...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Flip');
|
||||
$example->Flip();
|
||||
push(@$images,$example);
|
||||
|
||||
print "Flop...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Flop');
|
||||
$example->Flop();
|
||||
push(@$images,$example);
|
||||
|
||||
print "Frame...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Frame');
|
||||
$example->Frame('15x15+3+3');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Fx...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Fx');
|
||||
push(@$images,$example->Fx(expression=>'0.5*u'));
|
||||
|
||||
print "Gamma...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Gamma');
|
||||
$example->Gamma(1.6);
|
||||
push(@$images,$example);
|
||||
|
||||
print "Gaussian Blur...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Gaussian Blur');
|
||||
$example->GaussianBlur('0.0x1.5');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Gradient...\n";
|
||||
$gradient=Image::Magick->new;
|
||||
$gradient->Set(size=>'130x194');
|
||||
$x=$gradient->ReadImage('gradient:#20a0ff-#ffff00');
|
||||
warn "$x" if "$x";
|
||||
$gradient->Label('Gradient');
|
||||
push(@$images,$gradient);
|
||||
|
||||
print "Grayscale...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Grayscale');
|
||||
$example->Set(type=>'grayscale');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Implode...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Implode');
|
||||
$example->Implode(0.5);
|
||||
push(@$images,$example);
|
||||
|
||||
print "Level...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Level');
|
||||
$example->Level('20%');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Median Filter...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Median Filter');
|
||||
$example->MedianFilter();
|
||||
push(@$images,$example);
|
||||
|
||||
print "Modulate...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Modulate');
|
||||
$example->Modulate(brightness=>110,saturation=>110,hue=>110);
|
||||
push(@$images,$example);
|
||||
$example=$model->Clone();
|
||||
|
||||
print "Monochrome...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Monochrome');
|
||||
$example->Quantize(colorspace=>'gray',colors=>2,dither=>'false');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Morphology...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Morphology');
|
||||
$example->Morphology(method=>'Dilate',kernel=>'Diamond',iterations=>3);
|
||||
push(@$images,$example);
|
||||
|
||||
print "Motion Blur...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Motion Blur');
|
||||
$example->MotionBlur('0x13+10-10');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Negate...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Negate');
|
||||
$example->Negate();
|
||||
push(@$images,$example);
|
||||
|
||||
print "Normalize...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Normalize');
|
||||
$example->Normalize();
|
||||
push(@$images,$example);
|
||||
|
||||
print "Oil Paint...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Oil Paint');
|
||||
$example->OilPaint();
|
||||
push(@$images,$example);
|
||||
|
||||
print "Plasma...\n";
|
||||
$plasma=Image::Magick->new;
|
||||
$plasma->Set(size=>'130x194');
|
||||
$x=$plasma->ReadImage('plasma:fractal');
|
||||
warn "$x" if "$x";
|
||||
$plasma->Label('Plasma');
|
||||
push(@$images,$plasma);
|
||||
|
||||
print "Polaroid...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Polaroid');
|
||||
$example->Polaroid(caption=>'Magick',rotate=>-5.0,gravity=>'center');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Quantize...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Quantize');
|
||||
$example->Quantize();
|
||||
push(@$images,$example);
|
||||
|
||||
print "Radial Blur...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Radial Blur');
|
||||
$example->RadialBlur(10);
|
||||
push(@$images,$example);
|
||||
|
||||
print "Raise...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Raise');
|
||||
$example->Raise('10x10');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Reduce Noise...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Reduce Noise');
|
||||
$example->ReduceNoise();
|
||||
push(@$images,$example);
|
||||
|
||||
print "Resize...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Resize');
|
||||
$example->Resize('60%');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Roll...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Roll');
|
||||
$example->Roll(geometry=>'+20+10');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Rotate...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Rotate');
|
||||
$example->Rotate(45);
|
||||
push(@$images,$example);
|
||||
|
||||
print "Sample...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Sample');
|
||||
$example->Sample('60%');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Scale...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Scale');
|
||||
$example->Scale('60%');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Segment...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Segment');
|
||||
$example->Segment();
|
||||
push(@$images,$example);
|
||||
|
||||
print "Shade...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Shade');
|
||||
$example->Shade(geometry=>'30x30',gray=>'true');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Sharpen...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Sharpen');
|
||||
$example->Sharpen('0.0x1.0');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Shave...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Shave');
|
||||
$example->Shave('10x10');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Shear...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Shear');
|
||||
$example->Shear('-20x20');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Sketch...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Sketch');
|
||||
$example->Set(colorspace=>'Gray');
|
||||
$example->Sketch('0x20+120');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Sigmoidal Contrast...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Sigmoidal Contrast');
|
||||
$example->SigmoidalContrast("3x50%");
|
||||
push(@$images,$example);
|
||||
|
||||
print "Spread...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Spread');
|
||||
$example->Spread();
|
||||
push(@$images,$example);
|
||||
|
||||
print "Solarize...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Solarize');
|
||||
$example->Solarize();
|
||||
push(@$images,$example);
|
||||
|
||||
print "Swirl...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Swirl');
|
||||
$example->Swirl(90);
|
||||
push(@$images,$example);
|
||||
|
||||
print "Unsharp Mask...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Unsharp Mask');
|
||||
$example->UnsharpMask('0.0x1.0');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Vignette...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Vignette');
|
||||
$example->Vignette('0x20');
|
||||
push(@$images,$example);
|
||||
|
||||
print "Wave...\n";
|
||||
$example=$model->Clone();
|
||||
$example->Label('Wave');
|
||||
$example->Wave('25x150');
|
||||
push(@$images,$example);
|
||||
#
|
||||
# Create image montage.
|
||||
#
|
||||
print "Montage...\n";
|
||||
$montage=$images->Montage(geometry=>'128x160+8+4>',gravity=>'Center',
|
||||
tile=>'5x+10+200',compose=>'over',background=>'#ffffff',
|
||||
font=>'Generic.ttf',pointsize=>18,fill=>'#600',stroke=>'none',
|
||||
shadow=>'true');
|
||||
|
||||
$logo=Image::Magick->new();
|
||||
$logo->Read('logo:');
|
||||
$logo->Zoom('40%');
|
||||
$montage->Composite(image=>$logo,gravity=>'North');
|
||||
|
||||
print "Write...\n";
|
||||
$montage->Set(matte=>'false');
|
||||
$montage->Write('demo.jpg');
|
||||
print "Display...\n";
|
||||
$montage->Write('win:');
|
1556
ImageMagick-6.8.3-1/www/source/francais.xml
Normal file
1556
ImageMagick-6.8.3-1/www/source/francais.xml
Normal file
File diff suppressed because it is too large
Load diff
9
ImageMagick-6.8.3-1/www/source/incantation.msl
Normal file
9
ImageMagick-6.8.3-1/www/source/incantation.msl
Normal file
|
@ -0,0 +1,9 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<image size="400x400">
|
||||
<read filename="image.gif" />
|
||||
<get width="base-width" height="base-height" />
|
||||
<resize geometry="%[dimensions]" />
|
||||
<get width="width" height="height" />
|
||||
<print output="Image sized from %[base-width]x%[base-height] to %[width]x%[height].\n" />
|
||||
<write filename="image.png" />
|
||||
</image>
|
47
ImageMagick-6.8.3-1/www/source/locale.xml
Normal file
47
ImageMagick-6.8.3-1/www/source/locale.xml
Normal file
|
@ -0,0 +1,47 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE localemap [
|
||||
<!ELEMENT localemap (include)+>
|
||||
<!ELEMENT include (#PCDATA)>
|
||||
<!ATTLIST include locale CDATA #REQUIRED>
|
||||
<!ATTLIST include file CDATA #REQUIRED>
|
||||
]>
|
||||
<localemap>
|
||||
<include locale="no_NO.ISO-8859-1" file="bokmal.xml"/>
|
||||
<include locale="ca_ES.ISO-8859-1" file="catalan.xml"/>
|
||||
<include locale="hr_HR.ISO-8859-2" file="croatian.xml"/>
|
||||
<include locale="cs_CZ.ISO-8859-2" file="czech.xml"/>
|
||||
<include locale="da_DK.ISO-8859-1" file="danish.xml"/>
|
||||
<include locale="de_DE.ISO-8859-1" file="deutsch.xml"/>
|
||||
<include locale="nl_NL.ISO-8859-1" file="dutch.xml"/>
|
||||
<include locale="C" file="english.xml"/>
|
||||
<include locale="et_EE.ISO-8859-1" file="estonian.xml"/>
|
||||
<include locale="fi_FI.ISO-8859-1" file="finnish.xml"/>
|
||||
<include locale="fr_FR.ISO-8859-1" file="francais.xml"/>
|
||||
<include locale="fr_FR.ISO-8859-1" file="francais.xml"/>
|
||||
<include locale="fr_FR.UTF-8" file="francais.xml"/>
|
||||
<include locale="gl_ES.ISO-8859-1" file="galego.xml"/>
|
||||
<include locale="gl_ES.ISO-8859-1" file="galician.xml"/>
|
||||
<include locale="de_DE.ISO-8859-1" file="german.xml"/>
|
||||
<include locale="el_GR.ISO-8859-7" file="greek.xml"/>
|
||||
<include locale="en_US.UTF-8" file="english.xml"/>
|
||||
<include locale="iw_IL.ISO-8859-8" file="hebrew.xml"/>
|
||||
<include locale="hr_HR.ISO-8859-2" file="hrvatski.xml"/>
|
||||
<include locale="hu_HU.ISO-8859-2" file="hungarian.xml"/>
|
||||
<include locale="is_IS.ISO-8859-1" file="icelandic.xml"/>
|
||||
<include locale="it_IT.ISO-8859-1" file="italian.xml"/>
|
||||
<include locale="ja_JP.eucJP" file="japanese.xml"/>
|
||||
<include locale="ko_KR.eucKR" file="korean.xml"/>
|
||||
<include locale="lt_LT.ISO-8859-13" file="lithuanian.xml"/>
|
||||
<include locale="no_NO.ISO-8859-1" file="norwegian.xml"/>
|
||||
<include locale="nn_NO.ISO-8859-1" file="nynorsk.xml"/>
|
||||
<include locale="pl_PL.ISO-8859-2" file="polish.xml"/>
|
||||
<include locale="pt_PT.ISO-8859-1" file="portuguese.xml"/>
|
||||
<include locale="ro_RO.ISO-8859-2" file="romanian.xml"/>
|
||||
<include locale="ru_RU.ISO-8859-5" file="russian.xml"/>
|
||||
<include locale="sk_SK.ISO-8859-2" file="slovak.xml"/>
|
||||
<include locale="sl_SI.ISO-8859-2" file="slovene.xml"/>
|
||||
<include locale="es_ES.ISO-8859-1" file="spanish.xml"/>
|
||||
<include locale="sv_SE.ISO-8859-1" file="swedish.xml"/>
|
||||
<include locale="th_TH.TIS-620" file="thai.xml"/>
|
||||
<include locale="tr_TR.ISO-8859-9" file="turkish.xml"/>
|
||||
</localemap>
|
40
ImageMagick-6.8.3-1/www/source/log.xml
Normal file
40
ImageMagick-6.8.3-1/www/source/log.xml
Normal file
|
@ -0,0 +1,40 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE logmap [
|
||||
<!ELEMENT logmap (log)+>
|
||||
<!ELEMENT log (#PCDATA)>
|
||||
<!ATTLIST log events CDATA #IMPLIED>
|
||||
<!ATTLIST log output CDATA #IMPLIED>
|
||||
<!ATTLIST log filename CDATA #IMPLIED>
|
||||
<!ATTLIST log generations CDATA #IMPLIED>
|
||||
<!ATTLIST log limit CDATA #IMPLIED>
|
||||
<!ATTLIST log format CDATA #IMPLIED>
|
||||
]>
|
||||
<!--
|
||||
The format of the log is defined by embedding special format characters:
|
||||
|
||||
%c client
|
||||
%d domain
|
||||
%e event
|
||||
%f function
|
||||
%g generation
|
||||
%i thread id
|
||||
%l line
|
||||
%m module
|
||||
%n log name
|
||||
%p process id
|
||||
%r real CPU time
|
||||
%t wall clock time
|
||||
%u user CPU time
|
||||
%v version
|
||||
%% percent sign
|
||||
\n newline
|
||||
\r carriage return
|
||||
-->
|
||||
<logmap>
|
||||
<log events="None"/>
|
||||
<log output="console"/>
|
||||
<log filename="Magick-%g.log"/>
|
||||
<log generations="3"/>
|
||||
<log limit="2000"/>
|
||||
<log format="%t %r %u %v %d %c[%p]: %m/%f/%l/%d\n %e"/>
|
||||
</logmap>
|
23
ImageMagick-6.8.3-1/www/source/magic.xml
Normal file
23
ImageMagick-6.8.3-1/www/source/magic.xml
Normal file
|
@ -0,0 +1,23 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE magicmap [
|
||||
<!ELEMENT magicmap (magic)+>
|
||||
<!ELEMENT magic (#PCDATA)>
|
||||
<!ATTLIST magic name CDATA #REQUIRED>
|
||||
<!ATTLIST magic offset CDATA "0">
|
||||
<!ATTLIST magic target CDATA #REQUIRED>
|
||||
]>
|
||||
<!--
|
||||
Associate an image format with a unique identifier.
|
||||
|
||||
Many image formats have identifiers that uniquely identify a particular
|
||||
image format. For example, the GIF image format always begins with GIF8
|
||||
as the first 4 characters of the image. ImageMagick uses this information
|
||||
to quickly determine the type of image it is dealing with when it reads
|
||||
an image.
|
||||
-->
|
||||
<magicmap>
|
||||
<!-- <magic name="GIF" offset="0" target="GIF8"/> -->
|
||||
<!-- <magic name="JPEG" offset="0" target="\377\330\377"/> -->
|
||||
<!-- <magic name="PNG" offset="0" target="\211PNG\r\n\032\n"/> -->
|
||||
<!-- <magic name="TIFF" offset="0" target="\115\115\000\052"/> -->
|
||||
</magicmap>
|
450
ImageMagick-6.8.3-1/www/source/mgk.c
Normal file
450
ImageMagick-6.8.3-1/www/source/mgk.c
Normal file
|
@ -0,0 +1,450 @@
|
|||
/*
|
||||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
% %
|
||||
% %
|
||||
% %
|
||||
% M M GGGG K K %
|
||||
% MM MM G K K %
|
||||
% M M M G GG KKK %
|
||||
% M M G G K K %
|
||||
% M M GGG K K %
|
||||
% %
|
||||
% %
|
||||
% Read/Write MGK Image Format. %
|
||||
% %
|
||||
% Software Design %
|
||||
% John Cristy %
|
||||
% July 1992 %
|
||||
% %
|
||||
% %
|
||||
% Copyright 1999-2011 ImageMagick Studio LLC, a non-profit organization %
|
||||
% dedicated to making software imaging solutions freely available. %
|
||||
% %
|
||||
% You may not use this file except in compliance with the License. You may %
|
||||
% obtain a copy of the License at %
|
||||
% %
|
||||
% http://www.imagemagick.org/script/license.php %
|
||||
% %
|
||||
% Unless required by applicable law or agreed to in writing, software %
|
||||
% distributed under the License is distributed on an "AS IS" BASIS, %
|
||||
% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. %
|
||||
% See the License for the specific language governing permissions and %
|
||||
% limitations under the License. %
|
||||
% %
|
||||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
%
|
||||
%
|
||||
*/
|
||||
|
||||
/*
|
||||
Include declarations.
|
||||
*/
|
||||
#include "magick/studio.h"
|
||||
#include "magick/blob.h"
|
||||
#include "magick/blob-private.h"
|
||||
#include "magick/cache.h"
|
||||
#include "magick/colorspace.h"
|
||||
#include "magick/exception.h"
|
||||
#include "magick/exception-private.h"
|
||||
#include "magick/image.h"
|
||||
#include "magick/image-private.h"
|
||||
#include "magick/list.h"
|
||||
#include "magick/magick.h"
|
||||
#include "magick/memory_.h"
|
||||
#include "magick/monitor.h"
|
||||
#include "magick/monitor-private.h"
|
||||
#include "magick/quantum-private.h"
|
||||
#include "magick/static.h"
|
||||
#include "magick/string_.h"
|
||||
#include "magick/module.h"
|
||||
|
||||
/*
|
||||
Forward declarations.
|
||||
*/
|
||||
static MagickBooleanType
|
||||
WriteMGKImage(const ImageInfo *,Image *);
|
||||
|
||||
/*
|
||||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
% %
|
||||
% %
|
||||
% %
|
||||
% I s M G K %
|
||||
% %
|
||||
% %
|
||||
% %
|
||||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
%
|
||||
% IsMGK() returns MagickTrue if the image format type, identified by the
|
||||
% magick string, is MGK.
|
||||
%
|
||||
% The format of the IsMGK method is:
|
||||
%
|
||||
% MagickBooleanType IsMGK(const unsigned char *magick,const size_t length)
|
||||
%
|
||||
% A description of each parameter follows:
|
||||
%
|
||||
% o magick: This string is generally the first few bytes of an image file
|
||||
% or blob.
|
||||
%
|
||||
% o length: Specifies the length of the magick string.
|
||||
%
|
||||
*/
|
||||
static MagickBooleanType IsMGK(const unsigned char *magick,const size_t length)
|
||||
{
|
||||
if (length < 7)
|
||||
return(MagickFalse);
|
||||
if (LocaleNCompare((char *) magick,"id=mgk",7) == 0)
|
||||
return(MagickTrue);
|
||||
return(MagickFalse);
|
||||
}
|
||||
|
||||
/*
|
||||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
% %
|
||||
% %
|
||||
% %
|
||||
% R e a d M G K I m a g e %
|
||||
% %
|
||||
% %
|
||||
% %
|
||||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
%
|
||||
% ReadMGKImage() reads a MGK image file and returns it. It allocates
|
||||
% the memory necessary for the new Image structure and returns a pointer to
|
||||
% the new image.
|
||||
%
|
||||
% The format of the ReadMGKImage method is:
|
||||
%
|
||||
% Image *ReadMGKImage(const ImageInfo *image_info,
|
||||
% ExceptionInfo *exception)
|
||||
%
|
||||
% A description of each parameter follows:
|
||||
%
|
||||
% o image_info: the image info.
|
||||
%
|
||||
% o exception: return any errors or warnings in this structure.
|
||||
%
|
||||
*/
|
||||
static Image *ReadMGKImage(const ImageInfo *image_info,
|
||||
ExceptionInfo *exception)
|
||||
{
|
||||
char
|
||||
buffer[MaxTextExtent];
|
||||
|
||||
Image
|
||||
*image;
|
||||
|
||||
MagickBooleanType
|
||||
status;
|
||||
|
||||
register ssize_t
|
||||
x;
|
||||
|
||||
register PixelPacket
|
||||
*q;
|
||||
|
||||
register unsigned char
|
||||
*p;
|
||||
|
||||
ssize_t
|
||||
count,
|
||||
y;
|
||||
|
||||
size_t
|
||||
columns,
|
||||
rows;
|
||||
|
||||
unsigned char
|
||||
*pixels;
|
||||
|
||||
/*
|
||||
Open image file.
|
||||
*/
|
||||
assert(image_info != (const ImageInfo *) NULL);
|
||||
assert(image_info->signature == MagickSignature);
|
||||
if (image_info->debug != MagickFalse)
|
||||
(void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",
|
||||
image_info->filename);
|
||||
assert(exception != (ExceptionInfo *) NULL);
|
||||
assert(exception->signature == MagickSignature);
|
||||
image=AcquireImage(image_info);
|
||||
status=OpenBlob(image_info,image,ReadBinaryBlobMode,exception);
|
||||
if (status == MagickFalse)
|
||||
{
|
||||
image=DestroyImageList(image);
|
||||
return((Image *) NULL);
|
||||
}
|
||||
/*
|
||||
Read MGK image.
|
||||
*/
|
||||
(void) ReadBlobString(image,buffer); /* read magic number */
|
||||
if (IsMGK(buffer,7) == MagickFalse)
|
||||
ThrowReaderException(CorruptImageError,"ImproperImageHeader");
|
||||
(void) ReadBlobString(image,buffer);
|
||||
count=(ssize_t) sscanf(buffer,"%lu %lu\n",&columns,&rows);
|
||||
if (count <= 0)
|
||||
ThrowReaderException(CorruptImageError,"ImproperImageHeader");
|
||||
do
|
||||
{
|
||||
/*
|
||||
Initialize image structure.
|
||||
*/
|
||||
image->columns=columns;
|
||||
image->rows=rows;
|
||||
image->depth=8;
|
||||
if ((image_info->ping != MagickFalse) && (image_info->number_scenes != 0))
|
||||
if (image->scene >= (image_info->scene+image_info->number_scenes-1))
|
||||
break;
|
||||
/*
|
||||
Convert MGK raster image to pixel packets.
|
||||
*/
|
||||
if (SetImageExtent(image,0,0) == MagickFalse)
|
||||
{
|
||||
InheritException(exception,&image->exception);
|
||||
return(DestroyImageList(image));
|
||||
}
|
||||
pixels=(unsigned char *) AcquireQuantumMemory((size_t) image->columns,
|
||||
3UL*sizeof(*pixels));
|
||||
if (pixels == (unsigned char *) NULL)
|
||||
ThrowReaderException(ResourceLimitError,"MemoryAllocationFailed");
|
||||
for (y=0; y < (ssize_t) image->rows; y++)
|
||||
{
|
||||
count=(ssize_t) ReadBlob(image,(size_t) (3*image->columns),pixels);
|
||||
if (count != (ssize_t) (3*image->columns))
|
||||
ThrowReaderException(CorruptImageError,"UnableToReadImageData");
|
||||
p=pixels;
|
||||
q=QueueAuthenticPixels(image,0,y,image->columns,1,exception);
|
||||
if (q == (PixelPacket *) NULL)
|
||||
break;
|
||||
for (x=0; x < (ssize_t) image->columns; x++)
|
||||
{
|
||||
SetPixelRed(q,ScaleCharToQuantum(*p++));
|
||||
SetPixelGreen(q,ScaleCharToQuantum(*p++));
|
||||
SetPixelBlue(q,ScaleCharToQuantum(*p++));
|
||||
q++;
|
||||
}
|
||||
if (SyncAuthenticPixels(image,exception) == MagickFalse)
|
||||
break;
|
||||
if ((image->previous == (Image *) NULL) &&
|
||||
(SetImageProgress(image,LoadImageTag,y,image->rows) == MagickFalse))
|
||||
break;
|
||||
}
|
||||
pixels=(unsigned char *) RelinquishMagickMemory(pixels);
|
||||
if (EOFBlob(image) != MagickFalse)
|
||||
{
|
||||
ThrowFileException(exception,CorruptImageError,"UnexpectedEndOfFile",
|
||||
image->filename);
|
||||
break;
|
||||
}
|
||||
/*
|
||||
Proceed to next image.
|
||||
*/
|
||||
if (image_info->number_scenes != 0)
|
||||
if (image->scene >= (image_info->scene+image_info->number_scenes-1))
|
||||
break;
|
||||
*buffer='\0';
|
||||
(void) ReadBlobString(image,buffer);
|
||||
count=(ssize_t) sscanf(buffer,"%lu %lu\n",&columns,&rows);
|
||||
if (count > 0)
|
||||
{
|
||||
/*
|
||||
Allocate next image structure.
|
||||
*/
|
||||
AcquireNextImage(image_info,image);
|
||||
if (GetNextImageInList(image) == (Image *) NULL)
|
||||
{
|
||||
image=DestroyImageList(image);
|
||||
return((Image *) NULL);
|
||||
}
|
||||
image=SyncNextImageInList(image);
|
||||
if (image->progress_monitor != (MagickProgressMonitor) NULL)
|
||||
{
|
||||
status=SetImageProgress(image,LoadImageTag,TellBlob(image),
|
||||
GetBlobSize(image));
|
||||
if (status == MagickFalse)
|
||||
break;
|
||||
}
|
||||
}
|
||||
} while (count > 0);
|
||||
(void) CloseBlob(image);
|
||||
return(GetFirstImageInList(image));
|
||||
}
|
||||
|
||||
/*
|
||||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
% %
|
||||
% %
|
||||
% %
|
||||
% R e g i s t e r M G K I m a g e %
|
||||
% %
|
||||
% %
|
||||
% %
|
||||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
%
|
||||
% RegisterMGKImage() adds attributes for the MGK image format to
|
||||
% the list of supported formats. The attributes include the image format
|
||||
% tag, a method to read and/or write the format, whether the format
|
||||
% supports the saving of more than one frame to the same file or blob,
|
||||
% whether the format supports native in-memory I/O, and a brief
|
||||
% description of the format.
|
||||
%
|
||||
% The format of the RegisterMGKImage method is:
|
||||
%
|
||||
% size_t RegisterMGKImage(void)
|
||||
%
|
||||
*/
|
||||
ModuleExport size_t RegisterMGKImage(void)
|
||||
{
|
||||
MagickInfo
|
||||
*entry;
|
||||
|
||||
entry=SetMagickInfo("MGK");
|
||||
entry->decoder=(DecodeImageHandler *) ReadMGKImage;
|
||||
entry->encoder=(EncodeImageHandler *) WriteMGKImage;
|
||||
entry->magick=(IsImageFormatHandler *) IsMGK;
|
||||
entry->description=ConstantString("MGK");
|
||||
entry->module=ConstantString("MGK");
|
||||
(void) RegisterMagickInfo(entry);
|
||||
return(MagickImageCoderSignature);
|
||||
}
|
||||
|
||||
/*
|
||||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
% %
|
||||
% %
|
||||
% %
|
||||
% U n r e g i s t e r M G K I m a g e %
|
||||
% %
|
||||
% %
|
||||
% %
|
||||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
%
|
||||
% UnregisterMGKImage() removes format registrations made by the
|
||||
% MGK module from the list of supported formats.
|
||||
%
|
||||
% The format of the UnregisterMGKImage method is:
|
||||
%
|
||||
% UnregisterMGKImage(void)
|
||||
%
|
||||
*/
|
||||
ModuleExport void UnregisterMGKImage(void)
|
||||
{
|
||||
(void) UnregisterMagickInfo("MGK");
|
||||
}
|
||||
|
||||
/*
|
||||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
% %
|
||||
% %
|
||||
% %
|
||||
% W r i t e M G K I m a g e %
|
||||
% %
|
||||
% %
|
||||
% %
|
||||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
%
|
||||
% WriteMGKImage() writes an image to a file in red, green, and blue
|
||||
% MGK rasterfile format.
|
||||
%
|
||||
% The format of the WriteMGKImage method is:
|
||||
%
|
||||
% MagickBooleanType WriteMGKImage(const ImageInfo *image_info,
|
||||
% Image *image)
|
||||
%
|
||||
% A description of each parameter follows.
|
||||
%
|
||||
% o image_info: the image info.
|
||||
%
|
||||
% o image: The image.
|
||||
%
|
||||
*/
|
||||
static MagickBooleanType WriteMGKImage(const ImageInfo *image_info,
|
||||
Image *image)
|
||||
{
|
||||
char
|
||||
buffer[MaxTextExtent];
|
||||
|
||||
MagickBooleanType
|
||||
status;
|
||||
|
||||
MagickOffsetType
|
||||
scene;
|
||||
|
||||
register const PixelPacket
|
||||
*p;
|
||||
|
||||
register ssize_t
|
||||
x;
|
||||
|
||||
register unsigned char
|
||||
*q;
|
||||
|
||||
ssize_t
|
||||
y;
|
||||
|
||||
unsigned char
|
||||
*pixels;
|
||||
|
||||
/*
|
||||
Open output image file.
|
||||
*/
|
||||
assert(image_info != (const ImageInfo *) NULL);
|
||||
assert(image_info->signature == MagickSignature);
|
||||
assert(image != (Image *) NULL);
|
||||
assert(image->signature == MagickSignature);
|
||||
if (image->debug != MagickFalse)
|
||||
(void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename);
|
||||
status=OpenBlob(image_info,image,WriteBinaryBlobMode,&image->exception);
|
||||
if (status == MagickFalse)
|
||||
return(status);
|
||||
scene=0;
|
||||
do
|
||||
{
|
||||
/*
|
||||
Allocate memory for pixels.
|
||||
*/
|
||||
if (image->colorspace != RGBColorspace)
|
||||
(void) SetImageColorspace(image,RGBColorspace);
|
||||
pixels=(unsigned char *) AcquireQuantumMemory((size_t) image->columns,
|
||||
3UL*sizeof(*pixels));
|
||||
if (pixels == (unsigned char *) NULL)
|
||||
ThrowWriterException(ResourceLimitError,"MemoryAllocationFailed");
|
||||
/*
|
||||
Initialize raster file header.
|
||||
*/
|
||||
(void) WriteBlobString(image,"id=mgk\n");
|
||||
(void) FormatMagickString(buffer,MaxTextExtent,"%lu %lu\n",image->columns,
|
||||
image->rows);
|
||||
(void) WriteBlobString(image,buffer);
|
||||
for (y=0; y < (ssize_t) image->rows; y++)
|
||||
{
|
||||
p=AcquireImagePixels(image,0,y,image->columns,1,&image->exception);
|
||||
if (p == (const PixelPacket *) NULL)
|
||||
break;
|
||||
q=pixels;
|
||||
for (x=0; x < (ssize_t) image->columns; x++)
|
||||
{
|
||||
*q++=ScaleQuantumToChar(GetRedSample(p));
|
||||
*q++=ScaleQuantumToChar(GetGreenSample(p));
|
||||
*q++=ScaleQuantumToChar(GetBlueSample(p));
|
||||
p++;
|
||||
}
|
||||
(void) WriteBlob(image,(size_t) (q-pixels),pixels);
|
||||
if ((image->previous == (Image *) NULL) &&
|
||||
(SetImageProgress(image,SaveImageTag,y,image->rows) == MagickFalse))
|
||||
break;
|
||||
}
|
||||
pixels=(unsigned char *) RelinquishMagickMemory(pixels);
|
||||
if (GetNextImageInList(image) == (Image *) NULL)
|
||||
break;
|
||||
image=SyncNextImageInList(image);
|
||||
status=SetImageProgress(image,SaveImagesTag,scene,
|
||||
GetImageListLength(image));
|
||||
if (status == MagickFalse)
|
||||
break;
|
||||
scene++;
|
||||
} while (image_info->adjoin != MagickFalse);
|
||||
(void) CloseBlob(image);
|
||||
return(MagickTrue);
|
||||
}
|
1141
ImageMagick-6.8.3-1/www/source/mime.xml
Normal file
1141
ImageMagick-6.8.3-1/www/source/mime.xml
Normal file
File diff suppressed because it is too large
Load diff
150
ImageMagick-6.8.3-1/www/source/piechart.mvg
Normal file
150
ImageMagick-6.8.3-1/www/source/piechart.mvg
Normal file
|
@ -0,0 +1,150 @@
|
|||
push graphic-context
|
||||
viewbox 0 0 624 369
|
||||
affine 0.283636 0 0 0.283846 -0 -0
|
||||
push graphic-context
|
||||
push graphic-context
|
||||
fill 'darkslateblue'
|
||||
stroke 'blue'
|
||||
stroke-width 1
|
||||
rectangle 1,1 2199,1299
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
font-size 40
|
||||
fill 'white'
|
||||
stroke-width 1
|
||||
text 600,1100 'Average: 20.0'
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
fill 'red'
|
||||
stroke 'black'
|
||||
stroke-width 5
|
||||
path 'M700.0,600.0 L340.0,600.0 A360.0,360.0 0 0,1 408.1452123287954,389.2376150414973 z'
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
font-size 40
|
||||
fill 'white'
|
||||
stroke-width 1
|
||||
text 1400,140 'MagickWand for PHP'
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
font-size 30
|
||||
fill 'white'
|
||||
stroke-width 1
|
||||
text 1800,140 '(10.0%)'
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
fill 'red'
|
||||
stroke 'black'
|
||||
stroke-width 4
|
||||
rectangle 1330,100 1370,140
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
fill 'yellow'
|
||||
stroke 'black'
|
||||
stroke-width 5
|
||||
path 'M700.0,600.0 L408.1452123287954,389.2376150414973 A360.0,360.0 0 0,1 976.5894480359858,369.56936567559273 z'
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
font-size 40
|
||||
fill 'white'
|
||||
stroke-width 1
|
||||
text 1400,220 'MagickCore'
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
font-size 30
|
||||
fill 'white'
|
||||
stroke-width 1
|
||||
text 1800,220 '(29.0%)'
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
fill 'yellow'
|
||||
stroke 'black'
|
||||
stroke-width 4
|
||||
rectangle 1330,180 1370,220
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
fill 'fuchsia'
|
||||
stroke 'black'
|
||||
stroke-width 5
|
||||
path 'M700.0,600.0 L976.5894480359858,369.56936567559273 A360.0,360.0 0 0,1 964.2680466142854,844.4634932636567 z'
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
font-size 40
|
||||
fill 'white'
|
||||
stroke-width 1
|
||||
text 1400,300 'MagickWand'
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
font-size 30
|
||||
fill 'white'
|
||||
stroke-width 1
|
||||
text 1800,300 '(22.9%)'
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
fill 'fuchsia'
|
||||
stroke 'black'
|
||||
stroke-width 4
|
||||
rectangle 1330,260 1370,300
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
fill 'blue'
|
||||
stroke 'black'
|
||||
stroke-width 5
|
||||
path 'M700.0,600.0 L964.2680466142854,844.4634932636567 A360.0,360.0 0 0,1 757.853099990584,955.3210081341651 z'
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
font-size 40
|
||||
fill 'white'
|
||||
stroke-width 1
|
||||
text 1400,380 'JMagick'
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
font-size 30
|
||||
fill 'white'
|
||||
stroke-width 1
|
||||
text 1800,380 '(10.6%)'
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
fill 'blue'
|
||||
stroke 'black'
|
||||
stroke-width 4
|
||||
rectangle 1330,340 1370,380
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
fill 'lime'
|
||||
stroke 'black'
|
||||
stroke-width 5
|
||||
path 'M700.0,600.0 L757.853099990584,955.3210081341651 A360.0,360.0 0 0,1 340.0,600.0 z'
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
font-size 40
|
||||
fill 'white'
|
||||
stroke-width 1
|
||||
text 1400,460 'Magick++'
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
font-size 30
|
||||
fill 'white'
|
||||
stroke-width 1
|
||||
text 1800,460 '(27.5%)'
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
fill 'lime'
|
||||
stroke 'black'
|
||||
stroke-width 4
|
||||
rectangle 1330,420 1370,460
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
font-size 100
|
||||
fill 'white'
|
||||
stroke-width 1
|
||||
text 100,150 'ImageMagick'
|
||||
pop graphic-context
|
||||
push graphic-context
|
||||
fill 'none'
|
||||
stroke 'black'
|
||||
stroke-width 5
|
||||
circle 700,600 700,960
|
||||
pop graphic-context
|
||||
pop graphic-context
|
||||
pop graphic-context
|
32
ImageMagick-6.8.3-1/www/source/piechart.svg
Normal file
32
ImageMagick-6.8.3-1/www/source/piechart.svg
Normal file
|
@ -0,0 +1,32 @@
|
|||
<?xml version='1.0' standalone='no'?>
|
||||
<!DOCTYPE svg PUBLIC '-//W3C//DTD SVG 20001102//EN'
|
||||
'http://www.w3.org/TR/2000/CR-SVG-20001102/DTD/svg-20001102.dtd'>
|
||||
<svg width='22cm' height='13cm' viewBox='0 0 2200 1300'>
|
||||
<g>
|
||||
<rect x='1' y='1' width='2198' height='1298' style='fill:darkslateblue; stroke:blue; stroke-width:1'/>
|
||||
<text style='font-size: 40; fill: white; stroke-width: 1' x='600' y='1100'>Average: 20.0</text>
|
||||
<path d='M700.0,600.0 L340.0,600.0 A360.0,360.0 0 0,1 408.1452123287954,389.2376150414973 z' style='fill:red; stroke:black; stroke-width:5'/>
|
||||
<text style='font-size: 40; fill: white; stroke-width: 1' x='1400' y='140'>MagickWand for PHP</text>
|
||||
<text style='font-size: 30; fill: white; stroke-width: 1' x='1800' y='140'>(10.0%)</text>
|
||||
<rect x='1330' y='100' width='40' height='40' style='fill:red; stroke:black; stroke-width:4'/>
|
||||
<path d='M700.0,600.0 L408.1452123287954,389.2376150414973 A360.0,360.0 0 0,1 976.5894480359858,369.56936567559273 z' style='fill:yellow; stroke:black; stroke-width:5'/>
|
||||
<text style='font-size: 40; fill: white; stroke-width: 1' x='1400' y='220'>MagickCore</text>
|
||||
<text style='font-size: 30; fill: white; stroke-width: 1' x='1800' y='220'>(29.0%)</text>
|
||||
<rect x='1330' y='180' width='40' height='40' style='fill:yellow; stroke:black; stroke-width:4'/>
|
||||
<path d='M700.0,600.0 L976.5894480359858,369.56936567559273 A360.0,360.0 0 0,1 964.2680466142854,844.4634932636567 z' style='fill:fuchsia; stroke:black; stroke-width:5'/>
|
||||
<text style='font-size: 40; fill: white; stroke-width: 1'
|
||||
x='1400' y='300'>MagickWand</text>
|
||||
<text style='font-size: 30; fill: white; stroke-width: 1' x='1800' y='300'>(22.9%)</text>
|
||||
<rect x='1330' y='260' width='40' height='40' style='fill:fuchsia; stroke:black; stroke-width:4'/>
|
||||
<path d='M700.0,600.0 L964.2680466142854,844.4634932636567 A360.0,360.0 0 0,1 757.853099990584,955.3210081341651 z' style='fill:blue; stroke:black; stroke-width:5'/>
|
||||
<text style='font-size: 40; fill: white; stroke-width: 1' x='1400' y='380'>JMagick</text>
|
||||
<text style='font-size: 30; fill: white; stroke-width: 1' x='1800' y='380'>(10.6%)</text>
|
||||
<rect x='1330' y='340' width='40' height='40' style='fill:blue; stroke:black; stroke-width:4'/>
|
||||
<path d='M700.0,600.0 L757.853099990584,955.3210081341651 A360.0,360.0 0 0,1 340.0,600.0 z' style='fill:lime; stroke:black; stroke-width:5'/>
|
||||
<text style='font-size: 40; fill: white; stroke-width: 1' x='1400' y='460'>Magick++</text>
|
||||
<text style='font-size: 30; fill: white; stroke-width: 1' x='1800' y='460'>(27.5%)</text>
|
||||
<rect x='1330' y='420' width='40' height='40' style='fill:lime; stroke:black; stroke-width:4'/>
|
||||
<text style='font-size: 100; fill: white; stroke-width: 1' x='100' y='150'>ImageMagick</text>
|
||||
<circle cx='700' cy='600' r='360' style='fill: none; stroke: black; stroke-width:5' />
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 2.8 KiB |
58
ImageMagick-6.8.3-1/www/source/policy.xml
Normal file
58
ImageMagick-6.8.3-1/www/source/policy.xml
Normal file
|
@ -0,0 +1,58 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE policymap [
|
||||
<!ELEMENT policymap (policy)+>
|
||||
<!ELEMENT policy (#PCDATA)>
|
||||
<!ATTLIST policy domain (delegate|coder|filter|path|resource) #IMPLIED>
|
||||
<!ATTLIST policy name CDATA #IMPLIED>
|
||||
<!ATTLIST policy rights CDATA #IMPLIED>
|
||||
<!ATTLIST policy pattern CDATA #IMPLIED>
|
||||
<!ATTLIST policy value CDATA #IMPLIED>
|
||||
]>
|
||||
<!--
|
||||
Configure ImageMagick policies.
|
||||
|
||||
Domains include system, delegate, coder, filter, path, or resource.
|
||||
|
||||
Rights include none, read, write, and execute. Use | to combine them,
|
||||
for example: "read | write" to permit read from, or write to, a path.
|
||||
|
||||
Use a glob expression as a pattern.
|
||||
|
||||
Suppose we do not want users to process MPEG video images:
|
||||
|
||||
<policy domain="delegate" rights="none" pattern="mpeg:decode" />
|
||||
|
||||
Here we do not want users reading images from HTTP:
|
||||
|
||||
<policy domain="coder" rights="none" pattern="HTTP" />
|
||||
|
||||
Lets prevent users from executing any image filters:
|
||||
|
||||
<policy domain="filter" rights="none" pattern="*" />
|
||||
|
||||
The /repository file system is restricted to read only. We use a glob
|
||||
expression to match all paths that start with /repository:
|
||||
|
||||
<policy domain="path" rights="read" pattern="/repository/*" />
|
||||
|
||||
Any large image is cached to disk rather than memory:
|
||||
|
||||
<policy domain="resource" name="area" value="1GB"/>
|
||||
|
||||
Define arguments for the memory, map, area, and disk resources with
|
||||
SI prefixes (.e.g 100MB). In addition, resource policies are maximums for
|
||||
each instance of ImageMagick (e.g. policy memory limit 1GB, -limit 2GB
|
||||
exceeds policy maximum so memory limit is 1GB).
|
||||
-->
|
||||
<policymap>
|
||||
<!-- <policy domain="system" name="precision" value="6"/> -->
|
||||
<!-- <policy domain="resource" name="temporary-path" value="/tmp"/> -->
|
||||
<!-- <policy domain="resource" name="memory" value="2GiB"/> -->
|
||||
<!-- <policy domain="resource" name="map" value="4GiB"/> -->
|
||||
<!-- <policy domain="resource" name="area" value="1GB"/> -->
|
||||
<!-- <policy domain="resource" name="disk" value="16EB"/> -->
|
||||
<!-- <policy domain="resource" name="file" value="768"/> -->
|
||||
<!-- <policy domain="resource" name="thread" value="4"/> -->
|
||||
<!-- <policy domain="resource" name="throttle" value="0"/> -->
|
||||
<!-- <policy domain="resource" name="time" value="3600"/> -->
|
||||
</policymap>
|
334
ImageMagick-6.8.3-1/www/source/thresholds.xml
Normal file
334
ImageMagick-6.8.3-1/www/source/thresholds.xml
Normal file
|
@ -0,0 +1,334 @@
|
|||
<?xml version="1.0" encoding="ISO-8859-1"?>
|
||||
<!DOCTYPE thresholds [
|
||||
<!ELEMENT thresholds (threshold)+>
|
||||
<!ELEMENT threshold (description , levels)>
|
||||
<!ELEMENT description (CDATA)>
|
||||
<!ELEMENT levels (CDATA)>
|
||||
<!ATTLIST threshold map ID #REQUIRED>
|
||||
<!ATTLIST levels width CDATA #REQUIRED>
|
||||
<!ATTLIST levels height CDATA #REQUIRED>
|
||||
<!ATTLIST levels divisor CDATA #REQUIRED>
|
||||
]>
|
||||
<!--
|
||||
Threshold Maps for Ordered Posterized Dither
|
||||
|
||||
Each "<threshold>" element defines the map name, description, and an array
|
||||
of "levels" used to provide the threshold map for ordered dithering and
|
||||
digital halftoning.
|
||||
|
||||
The "alias" attribute provides a backward compatible name for this threshold
|
||||
map (pre-dating IM v6.2.9-6), and are deprecated.
|
||||
|
||||
The description is a english description of what the threshold map achieves
|
||||
and is only used for 'listing' the maps.
|
||||
|
||||
The map itself is a rectangular array of integers or threshold "levels"
|
||||
of the given "width" and "height" declared within the enclosing <levels>
|
||||
element. That is "width*height" integers or "levels" *must* be provided
|
||||
within each map.
|
||||
|
||||
Each of the "levels" integer values (each value representing the threshold
|
||||
intensity "level/divisor" at which that pixel is turned on. The "levels"
|
||||
integers given can be any postive integers between "0" and the "divisor",
|
||||
excluding those limits.
|
||||
|
||||
The "divisor" not only defines the upper limit and threshold divisor for each
|
||||
"level" but also the total number of pseudo-levels the threshold mapping
|
||||
creates and fills with a dither pattern. That is a ordered bitmap dither
|
||||
of a pure greyscale gradient will use a maximum of "divisor" ordered bitmap
|
||||
patterns, including the patterns with all the pixels 'on' and all the pixel
|
||||
'off'. It may define less patterns than that, but the color channels will
|
||||
be thresholded in units based on "divisor".
|
||||
|
||||
Alternatively for a multi-level posterization, ImageMagick inserts
|
||||
"divisor-2" dither patterns (as defined by the threshold map) between each of
|
||||
channel color level produced.
|
||||
|
||||
For example the map "o2x2" has a divisor of 5, which will define 3 bitmap
|
||||
patterns plus the patterns with all pixels 'on' and 'off'. A greyscale
|
||||
gradient will thus have 5 distinct areas.
|
||||
-->
|
||||
<thresholds>
|
||||
|
||||
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
Minimal Dither and Non-Dither Threshold Maps
|
||||
-->
|
||||
<threshold map="threshold" alias="1x1">
|
||||
<description>Threshold 1x1 (non-dither)</description>
|
||||
<levels width="1" height="1" divisor="2">
|
||||
1
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
<threshold map="checks" alias="2x1">
|
||||
<description>Checkerboard 2x1 (dither)</description>
|
||||
<levels width="2" height="2" divisor="3">
|
||||
1 2
|
||||
2 1
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
(dispersed) Ordered Dither Patterns
|
||||
-->
|
||||
<threshold map="o2x2" alias="2x2">
|
||||
<description>Ordered 2x2 (dispersed)</description>
|
||||
<levels width="2" height="2" divisor="5">
|
||||
1 3
|
||||
4 2
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
<threshold map="o3x3" alias="3x3">
|
||||
<description>Ordered 3x3 (dispersed)</description>
|
||||
<levels width="3" height="3" divisor="10">
|
||||
3 7 4
|
||||
6 1 9
|
||||
2 8 5
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
<threshold map="o4x4" alias="4x4">
|
||||
<!--
|
||||
From "Dithering Algorithms"
|
||||
http://www.efg2.com/Lab/Library/ImageProcessing/DHALF.TXT
|
||||
-->
|
||||
<description>Ordered 4x4 (dispersed)</description>
|
||||
<levels width="4" height="4" divisor="17">
|
||||
1 9 3 11
|
||||
13 5 15 7
|
||||
4 12 2 10
|
||||
16 8 14 6
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
<threshold map="o8x8" alias="8x8">
|
||||
<!-- Extracted from original 'OrderedDither()' Function -->
|
||||
<description>Ordered 8x8 (dispersed)</description>
|
||||
<levels width="8" height="8" divisor="65">
|
||||
1 49 13 61 4 52 16 64
|
||||
33 17 45 29 36 20 48 32
|
||||
9 57 5 53 12 60 8 56
|
||||
41 25 37 21 44 28 40 24
|
||||
3 51 15 63 2 50 14 62
|
||||
35 19 47 31 34 18 46 30
|
||||
11 59 7 55 10 58 6 54
|
||||
43 27 39 23 42 26 38 22
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
Halftones - Angled 45 degrees
|
||||
|
||||
Initially added to ImageMagick by Glenn Randers-Pehrson, IM v6.2.8-6,
|
||||
modified to be more symmetrical with intensity by Anthony, IM v6.2.9-7
|
||||
|
||||
These patterns initially start as circles, but then form diamonds
|
||||
pattern at the 50% threshold level, before forming negated circles,
|
||||
as it approached the other threshold extereme.
|
||||
-->
|
||||
<threshold map="h4x4a" alias="4x1">
|
||||
<description>Halftone 4x4 (angled)</description>
|
||||
<levels width="4" height="4" divisor="9">
|
||||
4 2 7 5
|
||||
3 1 8 6
|
||||
7 5 4 2
|
||||
8 6 3 1
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
<threshold map="h6x6a" alias="6x1">
|
||||
<description>Halftone 6x6 (angled)</description>
|
||||
<levels width="6" height="6" divisor="19">
|
||||
14 13 10 8 2 3
|
||||
16 18 12 7 1 4
|
||||
15 17 11 9 6 5
|
||||
8 2 3 14 13 10
|
||||
7 1 4 16 18 12
|
||||
9 6 5 15 17 11
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
<threshold map="h8x8a" alias="8x1">
|
||||
<description>Halftone 8x8 (angled)</description>
|
||||
<levels width="8" height="8" divisor="33">
|
||||
13 7 8 14 17 21 22 18
|
||||
6 1 3 9 28 31 29 23
|
||||
5 2 4 10 27 32 30 24
|
||||
16 12 11 15 20 26 25 19
|
||||
17 21 22 18 13 7 8 14
|
||||
28 31 29 23 6 1 3 9
|
||||
27 32 30 24 5 2 4 10
|
||||
20 26 25 19 16 12 11 15
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
Halftones - Orthogonally Aligned, or Un-angled
|
||||
|
||||
Initially added by Anthony Thyssen, IM v6.2.9-5 using techniques from
|
||||
"Dithering & Halftoning" by Gernot Haffmann
|
||||
http://www.fho-emden.de/~hoffmann/hilb010101.pdf
|
||||
|
||||
These patterns initially start as circles, but then form square
|
||||
pattern at the 50% threshold level, before forming negated circles,
|
||||
as it approached the other threshold extereme.
|
||||
-->
|
||||
<threshold map="h4x4o">
|
||||
<description>Halftone 4x4 (orthogonal)</description>
|
||||
<levels width="4" height="4" divisor="17">
|
||||
7 13 11 4
|
||||
12 16 14 8
|
||||
10 15 6 2
|
||||
5 9 3 1
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
<threshold map="h6x6o">
|
||||
<description>Halftone 6x6 (orthogonal)</description>
|
||||
<levels width="6" height="6" divisor="37">
|
||||
7 17 27 14 9 4
|
||||
21 29 33 31 18 11
|
||||
24 32 36 34 25 22
|
||||
19 30 35 28 20 10
|
||||
8 15 26 16 6 2
|
||||
5 13 23 12 3 1
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
<threshold map="h8x8o">
|
||||
<description>Halftone 8x8 (orthogonal)</description>
|
||||
<levels width="8" height="8" divisor="65">
|
||||
7 21 33 43 36 19 9 4
|
||||
16 27 51 55 49 29 14 11
|
||||
31 47 57 61 59 45 35 23
|
||||
41 53 60 64 62 52 40 38
|
||||
37 44 58 63 56 46 30 22
|
||||
15 28 48 54 50 26 17 10
|
||||
8 18 34 42 32 20 6 2
|
||||
5 13 25 39 24 12 3 1
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
<threshold map="h16x16o">
|
||||
<!--
|
||||
Direct extract from "Dithering & Halftoning" by Gernot Haffmann.
|
||||
This may need some fine tuning for symmetry of the halftone dots,
|
||||
as it was a mathematically formulated pattern.
|
||||
-->
|
||||
<description>Halftone 16x16 (orthogonal)</description>
|
||||
<levels width="16" height="16" divisor="257">
|
||||
4 12 24 44 72 100 136 152 150 134 98 70 42 23 11 3
|
||||
7 16 32 52 76 104 144 160 158 142 102 74 50 31 15 6
|
||||
19 27 40 60 92 132 168 180 178 166 130 90 58 39 26 18
|
||||
36 48 56 80 124 176 188 204 203 187 175 122 79 55 47 35
|
||||
64 68 84 116 164 200 212 224 223 211 199 162 114 83 67 63
|
||||
88 96 112 156 192 216 232 240 239 231 214 190 154 111 95 87
|
||||
108 120 148 184 208 228 244 252 251 243 226 206 182 147 119 107
|
||||
128 140 172 196 219 235 247 256 255 246 234 218 194 171 139 127
|
||||
126 138 170 195 220 236 248 253 254 245 233 217 193 169 137 125
|
||||
106 118 146 183 207 227 242 249 250 241 225 205 181 145 117 105
|
||||
86 94 110 155 191 215 229 238 237 230 213 189 153 109 93 85
|
||||
62 66 82 115 163 198 210 221 222 209 197 161 113 81 65 61
|
||||
34 46 54 78 123 174 186 202 201 185 173 121 77 53 45 33
|
||||
20 28 37 59 91 131 167 179 177 165 129 89 57 38 25 17
|
||||
8 13 29 51 75 103 143 159 157 141 101 73 49 30 14 5
|
||||
1 9 21 43 71 99 135 151 149 133 97 69 41 22 10 2
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
Halftones - Orthogonally Expanding Circle Patterns
|
||||
|
||||
Added by Glenn Randers-Pehrson, 4 Nov 2010, ImageMagick 6.6.5-6
|
||||
|
||||
Rather than producing a diamond 50% threshold pattern, these
|
||||
continue to generate larger (overlapping) circles. They are
|
||||
more like a true halftone pattern formed by covering a surface
|
||||
with either pure white or pure black circular dots.
|
||||
|
||||
WARNING: true halftone patterns only use true circles even in
|
||||
areas of highly varying intensity. Threshold dither patterns
|
||||
can generate distorted circles in such areas.
|
||||
-->
|
||||
|
||||
<threshold map="c5x5b" alias="c5x5">
|
||||
<description>Circles 5x5 (black)</description>
|
||||
<levels width="5" height="5" divisor="26">
|
||||
1 21 16 15 4
|
||||
5 17 20 19 14
|
||||
6 21 25 24 12
|
||||
7 18 22 23 11
|
||||
2 8 9 10 3
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
|
||||
<threshold map="c5x5w">
|
||||
<description>Circles 5x5 (white)</description>
|
||||
<levels width="5" height="5" divisor="26">
|
||||
25 21 10 11 22
|
||||
20 9 6 7 12
|
||||
19 5 1 2 13
|
||||
18 8 4 3 14
|
||||
24 17 16 15 23
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
<threshold map="c6x6b" alias="c6x6">
|
||||
<description>Circles 6x6 (black)</description>
|
||||
<levels width="6" height="6" divisor="37">
|
||||
1 5 14 13 12 4
|
||||
6 22 28 27 21 11
|
||||
15 29 35 34 26 20
|
||||
16 30 36 33 25 19
|
||||
7 23 31 32 24 10
|
||||
2 8 17 18 9 3
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
<threshold map="c6x6w">
|
||||
<description>Circles 6x6 (white)</description>
|
||||
<levels width="6" height="6" divisor="37">
|
||||
36 32 23 24 25 33
|
||||
31 15 9 10 16 26
|
||||
22 8 2 3 11 17
|
||||
21 7 1 4 12 18
|
||||
30 14 6 5 13 27
|
||||
35 29 20 19 28 34
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
<threshold map="c7x7b" alias="c7x7">
|
||||
<description>Circles 7x7 (black)</description>
|
||||
<levels width="7" height="7" divisor="50">
|
||||
3 9 18 28 17 8 2
|
||||
10 24 33 39 32 23 7
|
||||
19 34 44 48 43 31 16
|
||||
25 40 45 49 47 38 27
|
||||
20 35 41 46 42 29 15
|
||||
11 21 36 37 28 22 6
|
||||
4 12 13 26 14 5 1
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
|
||||
<threshold map="c7x7w">
|
||||
<description>Circles 7x7 (white)</description>
|
||||
<levels width="7" height="7" divisor="50">
|
||||
47 41 32 22 33 42 48
|
||||
40 26 17 11 18 27 43
|
||||
31 16 6 2 7 19 34
|
||||
25 10 5 1 3 12 23
|
||||
30 15 9 4 8 20 35
|
||||
39 29 14 13 21 28 44
|
||||
46 38 37 24 36 45 49
|
||||
</levels>
|
||||
</threshold>
|
||||
|
||||
|
||||
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
Special Purpose Dithers
|
||||
-->
|
||||
|
||||
</thresholds>
|
54
ImageMagick-6.8.3-1/www/source/type-ghostscript.xml
Normal file
54
ImageMagick-6.8.3-1/www/source/type-ghostscript.xml
Normal file
|
@ -0,0 +1,54 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE typemap [
|
||||
<!ELEMENT typemap (type)+>
|
||||
<!ELEMENT type (#PCDATA)>
|
||||
<!ELEMENT include (#PCDATA)>
|
||||
<!ATTLIST type name CDATA #REQUIRED>
|
||||
<!ATTLIST type fullname CDATA #IMPLIED>
|
||||
<!ATTLIST type family CDATA #IMPLIED>
|
||||
<!ATTLIST type foundry CDATA #IMPLIED>
|
||||
<!ATTLIST type weight CDATA #IMPLIED>
|
||||
<!ATTLIST type style CDATA #IMPLIED>
|
||||
<!ATTLIST type stretch CDATA #IMPLIED>
|
||||
<!ATTLIST type format CDATA #IMPLIED>
|
||||
<!ATTLIST type metrics CDATA #IMPLIED>
|
||||
<!ATTLIST type glyphs CDATA #REQUIRED>
|
||||
<!ATTLIST type version CDATA #IMPLIED>
|
||||
<!ATTLIST include file CDATA #REQUIRED>
|
||||
]>
|
||||
<typemap>
|
||||
<type name="AvantGarde-Book" fullname="AvantGarde Book" family="AvantGarde" foundry="URW" weight="400" style="normal" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/a010013l.afm" glyphs="/usr/share/fonts/default/Type1/a010013l.pfb"/>
|
||||
<type name="AvantGarde-BookOblique" fullname="AvantGarde Book Oblique" family="AvantGarde" foundry="URW" weight="400" style="oblique" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/a010033l.afm" glyphs="/usr/share/fonts/default/Type1/a010033l.pfb"/>
|
||||
<type name="AvantGarde-Demi" fullname="AvantGarde DemiBold" family="AvantGarde" foundry="URW" weight="600" style="normal" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/a010015l.afm" glyphs="/usr/share/fonts/default/Type1/a010015l.pfb"/>
|
||||
<type name="AvantGarde-DemiOblique" fullname="AvantGarde DemiOblique" family="AvantGarde" foundry="URW" weight="600" style="oblique" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/a010035l.afm" glyphs="/usr/share/fonts/default/Type1/a010035l.pfb"/>
|
||||
<type name="Bookman-Demi" fullname="Bookman DemiBold" family="Bookman" foundry="URW" weight="600" style="normal" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/b018015l.afm" glyphs="/usr/share/fonts/default/Type1/b018015l.pfb"/>
|
||||
<type name="Bookman-DemiItalic" fullname="Bookman DemiBold Italic" family="Bookman" foundry="URW" weight="600" style="italic" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/b018035l.afm" glyphs="/usr/share/fonts/default/Type1/b018035l.pfb"/>
|
||||
<type name="Bookman-Light" fullname="Bookman Light" family="Bookman" foundry="URW" weight="300" style="normal" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/b018012l.afm" glyphs="/usr/share/fonts/default/Type1/b018012l.pfb"/>
|
||||
<type name="Bookman-LightItalic" fullname="Bookman Light Italic" family="Bookman" foundry="URW" weight="300" style="italic" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/b018032l.afm" glyphs="/usr/share/fonts/default/Type1/b018032l.pfb"/>
|
||||
<type name="Courier" fullname="Courier Regular" family="Courier" foundry="URW" weight="400" style="normal" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/n022003l.afm" glyphs="/usr/share/fonts/default/Type1/n022003l.pfb"/>
|
||||
<type name="Courier-Bold" fullname="Courier Bold" family="Courier" foundry="URW" weight="700" style="normal" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/n022004l.afm" glyphs="/usr/share/fonts/default/Type1/n022004l.pfb"/>
|
||||
<type name="Courier-Oblique" fullname="Courier Regular Oblique" family="Courier" foundry="URW" weight="400" style="oblique" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/n022023l.afm" glyphs="/usr/share/fonts/default/Type1/n022023l.pfb"/>
|
||||
<type name="Courier-BoldOblique" fullname="Courier Bold Oblique" family="Courier" foundry="URW" weight="700" style="oblique" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/n022024l.afm" glyphs="/usr/share/fonts/default/Type1/n022024l.pfb"/>
|
||||
<type name="fixed" fullname="Helvetica Regular" family="Helvetica" foundry="URW" weight="400" style="normal" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/n019003l.afm" glyphs="/usr/share/fonts/default/Type1/n019003l.pfb"/>
|
||||
<type name="Helvetica" fullname="Helvetica Regular" family="Helvetica" foundry="URW" weight="400" style="normal" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/n019003l.afm" glyphs="/usr/share/fonts/default/Type1/n019003l.pfb"/>
|
||||
<type name="Helvetica-Bold" fullname="Helvetica Bold" family="Helvetica" foundry="URW" weight="700" style="normal" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/n019004l.afm" glyphs="/usr/share/fonts/default/Type1/n019004l.pfb"/>
|
||||
<type name="Helvetica-Oblique" fullname="Helvetica Regular Italic" family="Helvetica" foundry="URW" weight="400" style="italic" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/n019023l.afm" glyphs="/usr/share/fonts/default/Type1/n019023l.pfb"/>
|
||||
<type name="Helvetica-BoldOblique" fullname="Helvetica Bold Italic" family="Helvetica" foundry="URW" weight="700" style="italic" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/n019024l.afm" glyphs="/usr/share/fonts/default/Type1/n019024l.pfb"/>
|
||||
<type name="Helvetica-Narrow" fullname="Helvetica Narrow" family="Helvetica Narrow" foundry="URW" weight="400" style="normal" stretch="condensed" format="type1" metrics="/usr/share/fonts/default/Type1/n019043l.afm" glyphs="/usr/share/fonts/default/Type1/n019043l.pfb"/>
|
||||
<type name="Helvetica-Narrow-Oblique" fullname="Helvetica Narrow Oblique" family="Helvetica Narrow" foundry="URW" weight="400" style="oblique" stretch="condensed" format="type1" metrics="/usr/share/fonts/default/Type1/n019063l.afm" glyphs="/usr/share/fonts/default/Type1/n019063l.pfb"/>
|
||||
<type name="Helvetica-Narrow-Bold" fullname="Helvetica Narrow Bold" family="Helvetica Narrow" foundry="URW" weight="700" style="normal" stretch="condensed" format="type1" metrics="/usr/share/fonts/default/Type1/n019044l.afm" glyphs="/usr/share/fonts/default/Type1/n019044l.pfb"/>
|
||||
<type name="Helvetica-Narrow-BoldOblique" fullname="Helvetica Narrow Bold Oblique" family="Helvetica Narrow" foundry="URW" weight="700" style="oblique" stretch="condensed" format="type1" metrics="/usr/share/fonts/default/Type1/n019064l.afm" glyphs="/usr/share/fonts/default/Type1/n019064l.pfb"/>
|
||||
<type name="NewCenturySchlbk-Roman" fullname="New Century Schoolbook" family="NewCenturySchlbk" foundry="URW" weight="400" style="normal" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/c059013l.afm" glyphs="/usr/share/fonts/default/Type1/c059013l.pfb"/>
|
||||
<type name="NewCenturySchlbk-Italic" fullname="New Century Schoolbook Italic" family="NewCenturySchlbk" foundry="URW" weight="400" style="italic" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/c059033l.afm" glyphs="/usr/share/fonts/default/Type1/c059033l.pfb"/>
|
||||
<type name="NewCenturySchlbk-Bold" fullname="New Century Schoolbook Bold" family="NewCenturySchlbk" foundry="URW" weight="700" style="normal" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/c059016l.afm" glyphs="/usr/share/fonts/default/Type1/c059016l.pfb"/>
|
||||
<type name="NewCenturySchlbk-BoldItalic" fullname="New Century Schoolbook Bold Italic" family="NewCenturySchlbk" foundry="URW" weight="700" style="italic" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/c059036l.afm" glyphs="/usr/share/fonts/default/Type1/c059036l.pfb"/>
|
||||
<type name="Palatino-Roman" fullname="Palatino Regular" family="Palatino" foundry="URW" weight="400" style="normal" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/p052003l.afm" glyphs="/usr/share/fonts/default/Type1/p052003l.pfb"/>
|
||||
<type name="Palatino-Italic" fullname="Palatino Italic" family="Palatino" foundry="URW" weight="400" style="italic" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/p052023l.afm" glyphs="/usr/share/fonts/default/Type1/p052023l.pfb"/>
|
||||
<type name="Palatino-Bold" fullname="Palatino Bold" family="Palatino" foundry="URW" weight="700" style="normal" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/p052004l.afm" glyphs="/usr/share/fonts/default/Type1/p052004l.pfb"/>
|
||||
<type name="Palatino-BoldItalic" fullname="Palatino Bold Italic" family="Palatino" foundry="URW" weight="700" style="italic" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/p052024l.afm" glyphs="/usr/share/fonts/default/Type1/p052024l.pfb"/>
|
||||
<type name="Times-Roman" fullname="Times Regular" family="Times" foundry="URW" weight="400" style="normal" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/n021003l.afm" glyphs="/usr/share/fonts/default/Type1/n021003l.pfb"/>
|
||||
<type name="Times-Bold" fullname="Times Medium" family="Times" foundry="URW" weight="700" style="normal" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/n021004l.afm" glyphs="/usr/share/fonts/default/Type1/n021004l.pfb"/>
|
||||
<type name="Times-Italic" fullname="Times Regular Italic" family="Times" foundry="URW" weight="400" style="italic" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/n021023l.afm" glyphs="/usr/share/fonts/default/Type1/n021023l.pfb"/>
|
||||
<type name="Times-BoldItalic" fullname="Times Medium Italic" family="Times" foundry="URW" weight="700" style="italic" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/n021024l.afm" glyphs="/usr/share/fonts/default/Type1/n021024l.pfb"/>
|
||||
<type name="Symbol" fullname="Symbol" family="Symbol" foundry="URW" weight="400" style="normal" stretch="normal" format="type1" metrics="/usr/share/fonts/default/Type1/s050000l.afm" glyphs="/usr/share/fonts/default/Type1/s050000l.pfb" version="0.1" encoding="AdobeCustom"/>
|
||||
</typemap>
|
102
ImageMagick-6.8.3-1/www/source/type-windows.xml
Normal file
102
ImageMagick-6.8.3-1/www/source/type-windows.xml
Normal file
|
@ -0,0 +1,102 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE typemap [
|
||||
<!ELEMENT typemap (type)+>
|
||||
<!ELEMENT type (#PCDATA)>
|
||||
<!ELEMENT include (#PCDATA)>
|
||||
<!ATTLIST type name CDATA #REQUIRED>
|
||||
<!ATTLIST type fullname CDATA #IMPLIED>
|
||||
<!ATTLIST type family CDATA #IMPLIED>
|
||||
<!ATTLIST type foundry CDATA #IMPLIED>
|
||||
<!ATTLIST type weight CDATA #IMPLIED>
|
||||
<!ATTLIST type style CDATA #IMPLIED>
|
||||
<!ATTLIST type stretch CDATA #IMPLIED>
|
||||
<!ATTLIST type format CDATA #IMPLIED>
|
||||
<!ATTLIST type metrics CDATA #IMPLIED>
|
||||
<!ATTLIST type glyphs CDATA #REQUIRED>
|
||||
<!ATTLIST type version CDATA #IMPLIED>
|
||||
<!ATTLIST include file CDATA #REQUIRED>
|
||||
]>
|
||||
<typemap>
|
||||
<type name="Arial" fullname="Arial" family="Arial" weight="400" style="normal" stretch="normal" glyphs="arial.ttf"/>
|
||||
<type name="Arial-Black" fullname="Arial Black" family="Arial" weight="900" style="normal" stretch="normal" glyphs="ariblk.ttf"/>
|
||||
<type name="Arial-Bold" fullname="Arial Bold" family="Arial" weight="700" style="normal" stretch="normal" glyphs="arialbd.ttf"/>
|
||||
<type name="Arial-Bold-Italic" fullname="Arial Bold Italic" family="Arial" weight="700" style="italic" stretch="normal" glyphs="arialbi.ttf"/>
|
||||
<type name="Arial-Italic" fullname="Arial Italic" family="Arial" weight="400" style="italic" stretch="normal" glyphs="ariali.ttf"/>
|
||||
<type name="Arial-Narrow" fullname="Arial Narrow" family="Arial Narrow" weight="400" style="normal" stretch="condensed" glyphs="arialn.ttf"/>
|
||||
<type name="Arial-Narrow-Bold" fullname="Arial Narrow Bold" family="Arial Narrow" weight="700" style="normal" stretch="condensed" glyphs="arialnb.ttf"/>
|
||||
<type name="Arial-Narrow-Bold-Italic" fullname="Arial Narrow Bold Italic" family="Arial Narrow" weight="700" style="italic" stretch="condensed" glyphs="arialnbi.ttf"/>
|
||||
<type name="Arial-Narrow-Italic" fullname="Arial Narrow Italic" family="Arial Narrow" weight="400" style="italic" stretch="condensed" glyphs="arnari.ttf"/>
|
||||
<type name="Arial-Narrow-Special-G1" fullname="Arial Narrow Special G1" family="Arial Narrow Special G1" weight="400" style="normal" stretch="condensed" glyphs="msgeonr1.ttf"/>
|
||||
<type name="Arial-Narrow-Special-G1-Bold" fullname="Arial Narrow Special G1 Bold" family="Arial Narrow Special G1" weight="700" style="normal" stretch="condensed" glyphs="msgeonb1.ttf"/>
|
||||
<type name="Arial-Narrow-Special-G1-Italic" fullname="Arial Narrow Special G1 Italic" family="Arial Narrow Special G1" weight="400" style="italic" stretch="condensed" glyphs="msgeoni1.ttf"/>
|
||||
<type name="Arial-Narrow-Special-G2" fullname="Arial Narrow Special G2" family="Arial Narrow Special G2" weight="400" style="normal" stretch="condensed" glyphs="msgeonr2.ttf"/>
|
||||
<type name="Arial-Narrow-Special-G2-Bold" fullname="Arial Narrow Special G2 Bold" family="Arial Narrow Special G2" weight="700" style="Narrow" stretch="normal" glyphs="msgeonb2.ttf"/>
|
||||
<type name="Arial-Narrow-Special-G2-Italic" fullname="Arial Narrow Special G2 Italic" family="Arial Narrow Special G2" weight="400" style="italic" stretch="condensed" glyphs="msgeoni2.ttf"/>
|
||||
<type name="Arial-Rounded-MT-Bold" fullname="Arial Rounded MT Bold" family="Arial Rounded MT" weight="700" style="normal" stretch="normal" glyphs="arlrdbd.ttf"/>
|
||||
<type name="Arial-Special-G1" fullname="Arial Special G1" family="Arial Special G1" weight="400" style="normal" stretch="normal" glyphs="msgeor1.ttf"/>
|
||||
<type name="Arial-Special-G1-Bold" fullname="Arial Special G1 Bold" family="Arial Special G1" weight="700" style="normal" stretch="normal" glyphs="msgeoab1.ttf"/>
|
||||
<type name="Arial-Special-G1-Bold-Italic" fullname="Arial Special G1 Bold Italic" family="Arial Special G1" weight="700" style="italic" stretch="normal" glyphs="msgeoax1.ttf"/>
|
||||
<type name="Arial-Special-G1-Italic" fullname="Arial Special G1 Italic" family="Arial Special G1" weight="400" style="italic" stretch="normal" glyphs="msgeoai1.ttf"/>
|
||||
<type name="Arial-Special-G2" fullname="Arial Special G2" family="Arial Special G2" weight="400" style="normal" stretch="normal" glyphs="msgeoar2.ttf"/>
|
||||
<type name="Arial-Special-G2-Bold" fullname="Arial Special G2 Bold" family="Arial Special G2" weight="700" style="normal" stretch="normal" glyphs="msgeoab2.ttf"/>
|
||||
<type name="Arial-Special-G2-Bold-Italic" fullname="Arial Special G2 Bold Italic" family="Arial Special G2" weight="700" style="italic" stretch="normal" glyphs="msgeoax2.ttf"/>
|
||||
<type name="Arial-Special-G2-Italic" fullname="Arial Special G2 Italic" family="Arial Special G2" weight="400" style="italic" stretch="normal" glyphs="msgeoai2.ttf"/>
|
||||
<type name="Bookman-Old-Style" fullname="Bookman Old Style" family="Bookman Old Style" weight="400" style="normal" stretch="normal" glyphs="bkmnos.ttf"/>
|
||||
<type name="Bookman-Old-Style-Bold" fullname="Bookman Old Style Bold" family="Bookman Old Style" weight="700" style="normal" stretch="normal" glyphs="bookosb.ttf"/>
|
||||
<type name="Bookman-Old-Style-Bold-Italic" fullname="Bookman Old Style Bold Italic" family="Bookman Old Style" weight="400" style="italic" stretch="normal" glyphs="bookosbi.ttf"/>
|
||||
<type name="Bookman-Old-Style-Italic" fullname="Bookman Old Style Italic" family="Bookman Old Style" weight="400" style="italic" stretch="normal" glyphs="boookosi.ttf"/>
|
||||
<type name="Century-Schoolbook" fullname="Century Schoolbook" family="Century Schoolbook" weight="400" style="normal" stretch="normal" glyphs="censcbk.ttf"/>
|
||||
<type name="Century-Schoolbook-Bold" fullname="Century Schoolbook Bold" family="Century Schoolbook" weight="700" style="normal" stretch="normal" glyphs="schlbkb.ttf"/>
|
||||
<type name="Century-Schoolbook-Bold-Italic" fullname="Century Schoolbook Bold Italic" family="Century Schoolbook" weight="700" style="italic" stretch="normal" glyphs="schlbkbi.ttf"/>
|
||||
<type name="Century-Schoolbook-Italic" fullname="Century Schoolbook Italic" family="Century Schoolbook" weight="400" style="italic" stretch="normal" glyphs="schlbki.ttf"/>
|
||||
<type name="Comic-Sans-MS" fullname="Comic Sans MS" family="Comic Sans MS" weight="400" style="normal" stretch="normal" glyphs="comic.ttf"/>
|
||||
<type name="Comic-Sans-MS-Bold" fullname="Comic Sans MS Bold" family="Comic Sans MS" weight="700" style="normal" stretch="normal" glyphs="comicbd.ttf"/>
|
||||
<type name="Courier-New" fullname="Courier New" family="Courier New" weight="400" style="normal" stretch="normal" glyphs="cour.ttf"/>
|
||||
<type name="Courier-New-Bold" fullname="Courier New Bold" family="Courier New" weight="700" style="normal" stretch="normal" glyphs="courbd.ttf"/>
|
||||
<type name="Courier-New-Bold-Italic" fullname="Courier New Bold Italic" family="Courier New" weight="700" style="italic" stretch="normal" glyphs="courbi.ttf"/>
|
||||
<type name="Courier-New-Italic" fullname="Courier New Italic" family="Courier New" weight="400" style="italic" stretch="normal" glyphs="couri.ttf"/>
|
||||
<type name="Garamond" fullname="Garamond" family="Garamond" weight="400" style="normal" stretch="normal" glyphs="gara.ttf"/>
|
||||
<type name="Garamond-Bold" fullname="Garamond Bold" family="Garamond" weight="700" style="normal" stretch="normal" glyphs="garabd.ttf"/>
|
||||
<type name="Garamond-Italic" fullname="Garamond Italic" family="Garamond" weight="400" style="italic" stretch="normal" glyphs="Italic"/>
|
||||
<type name="Gill-Sans-MT-Ext-Condensed-Bold" fullname="Gill Sans MT Ext Condensed Bold" family="Gill Sans MT" weight="700" style="normal" stretch="extra-condensed" glyphs="glsnecb.ttf"/>
|
||||
<type name="Impact" fullname="Impact" family="Impact" weight="400" style="normal" stretch="normal" glyphs="impact.ttf"/>
|
||||
<type name="Lucida-Blackletter" fullname="Lucida Blackletter" family="Lucida Blackletter" weight="400" style="normal" stretch="normal" glyphs="lblack.ttf"/>
|
||||
<type name="Lucida-Bright" fullname="Lucida Bright" family="Lucida Bright" weight="400" style="normal" stretch="normal" glyphs="lbrite.ttf"/>
|
||||
<type name="Lucida-Bright-Demibold" fullname="Lucida Bright Demibold" family="Lucida Bright" weight="600" style="normal" stretch="normal" glyphs="lbrited.ttf"/>
|
||||
<type name="Lucida-Bright-Demibold-Italic" fullname="Lucida Bright Demibold Italic" family="Lucida Bright" weight="600" style="italic" stretch="normal" glyphs="lbritedi.ttf"/>
|
||||
<type name="Lucida-Bright-Italic" fullname="Lucida Bright Italic" family="Lucida Bright" weight="400" style="italic" stretch="normal" glyphs="lbritei.ttf"/>
|
||||
<type name="Lucida-Caligraphy-Italic" fullname="Lucida Caligraphy Italic" family="Lucida Caligraphy" weight="400" style="italic" stretch="normal" glyphs="lcalig.ttf"/>
|
||||
<type name="Lucida-Console, Lucida-Console" fullname="Lucida Console, Lucida Console" family="Regular" weight="400" style="lucon.ttf" stretch="normal" glyphs=""/>
|
||||
<type name="Lucida-Fax-Demibold" fullname="Lucida Fax Demibold" family="Lucida Fax" weight="600" style="normal" stretch="normal" glyphs="lfaxd.ttf"/>
|
||||
<type name="Lucida-Fax-Demibold-Italic" fullname="Lucida Fax Demibold Italic" family="Lucida Fax" weight="600" style="italic" stretch="normal" glyphs="lfaxdi.ttf"/>
|
||||
<type name="Lucida-Fax-Italic" fullname="Lucida Fax Italic" family="Lucida Fax" weight="400" style="italic" stretch="normal" glyphs="lfaxi.ttf"/>
|
||||
<type name="Lucida-Fax-Regular" fullname="Lucida Fax Regular" family="Lucida Fax" weight="400" style="normal" stretch="normal" glyphs="lfax.ttf"/>
|
||||
<type name="Lucida-Handwriting-Italic" fullname="Lucida Handwriting Italic" family="Lucida Handwriting" weight="400" style="italic" stretch="normal" glyphs="lhandw.ttf"/>
|
||||
<type name="Lucida-Sans-Demibold-Italic" fullname="Lucida Sans Demibold Italic" family="Lucida Sans" weight="600" style="italic" stretch="normal" glyphs="lsansdi.ttf"/>
|
||||
<type name="Lucida-Sans-Demibold-Roman" fullname="Lucida Sans Demibold Roman" family="Lucida Sans Demibold" weight="400" style="normal" stretch="normal" glyphs="lsansd.ttf"/>
|
||||
<type name="Lucida-Sans-Regular" fullname="Lucida Sans Regular" family="Lucida Sans" weight="400" style="normal" stretch="normal" glyphs="lsans.ttf"/>
|
||||
<type name="Lucida-Sans-Typewriter-Bold" fullname="Lucida Sans Typewriter Bold" family="Lucida Sans Typewriter" weight="700" style="normal" stretch="normal" glyphs="ltypeb.ttf"/>
|
||||
<type name="Lucida-Sans-Typewriter-Bold-Oblique" fullname="Lucida Sans Typewriter Bold Oblique" family="Lucida Sans Typewriter" weight="700" style="normal" stretch="normal" glyphs="ltypebo.ttf"/>
|
||||
<type name="Lucida-Sans-Typewriter-Oblique" fullname="Lucida Sans Typewriter Oblique" family="Lucida Sans Typewriter" weight="700" style="normal" stretch="normal" glyphs="ltypeo.ttf"/>
|
||||
<type name="Lucida-Sans-Typewriter-Regular" fullname="Lucida Sans Typewriter Regular" family="Lucida Sans Typewriter" weight="400" style="normal" stretch="normal" glyphs="ltype.ttf"/>
|
||||
<type name="MS-Sans-Serif" fullname="MS Sans Serif" family="MS Sans Serif" weight="400" style="normal" stretch="normal" glyphs="sseriff.ttf"/>
|
||||
<type name="MS-Serif" fullname="MS Serif" family="MS Serif" weight="400" style="normal" stretch="normal" glyphs="seriff.ttf"/>
|
||||
<type name="Modern" fullname="Modern" family="Modern" weight="400" style="normal" stretch="normal" glyphs="modern.ttf"/>
|
||||
<type name="Monotype-Corsiva" fullname="Monotype Corsiva" family="Monotype Corsiva" weight="400" style="normal" stretch="normal" glyphs="mtcorsva.ttf"/>
|
||||
<type name="Small-Fonts" fullname="Small Fonts" family="Small Fonts" weight="400" style="normal" stretch="normal" glyphs="smallf.ttf"/>
|
||||
<type name="Symbol" fullname="Symbol" family="Symbol" weight="400" style="normal" stretch="normal" glyphs="symbol.ttf" encoding="AppleRoman"/>
|
||||
<type name="Tahoma" fullname="Tahoma" family="Tahoma" weight="400" style="normal" stretch="normal" glyphs="tahoma.ttf"/>
|
||||
<type name="Tahoma-Bold" fullname="Tahoma Bold" family="Tahoma" weight="700" style="normal" stretch="normal" glyphs="tahomabd.ttf"/>
|
||||
<type name="Times-New-Roman" fullname="Times New Roman" family="Times New Roman" weight="400" style="normal" stretch="normal" glyphs="times.ttf"/>
|
||||
<type name="Times-New-Roman-Bold" fullname="Times New Roman Bold" family="Times New Roman" weight="700" style="normal" stretch="normal" glyphs="timesbd.ttf"/>
|
||||
<type name="Times-New-Roman-Bold-Italic" fullname="Times New Roman Bold Italic" family="Times New Roman" weight="700" style="italic" stretch="normal" glyphs="timesbi.ttf"/>
|
||||
<type name="Times-New-Roman-Italic" fullname="Times New Roman Italic" family="Times New Roman" weight="400" style="italic" stretch="normal" glyphs="timesi.ttf"/>
|
||||
<type name="Times-New-Roman-MT-Extra-Bold" fullname="Times New Roman MT Extra Bold" family="Times New Roman MT" weight="800" style="normal" stretch="normal" glyphs="timnreb.ttf"/>
|
||||
<type name="Verdana" fullname="Verdana" family="Verdana" weight="400" style="normal" stretch="normal" glyphs="verdana.ttf"/>
|
||||
<type name="Verdana-Bold" fullname="Verdana Bold" family="Verdana" weight="700" style="normal" stretch="normal" glyphs="verdanab.ttf"/>
|
||||
<type name="Verdana-Bold-Italic" fullname="Verdana Bold Italic" family="Verdana" weight="700" style="italic" stretch="normal" glyphs="verdanaz.ttf"/>
|
||||
<type name="Verdana-Italic" fullname="Verdana Italic" family="Verdana" weight="400" style="italic" stretch="normal" glyphs="verdanai.ttf"/>
|
||||
<type name="Wingdings" fullname="Wingdings" family="Wingdings" weight="400" style="normal" stretch="normal" glyphs="wingding.ttf" encoding="AppleRoman"/>
|
||||
<type name="Wingdings-2" fullname="Wingdings 2" family="Wingdings 2" weight="400" style="normal" stretch="normal" glyphs="wingdng2.ttf" encoding="AppleRoman"/>
|
||||
<type name="Wingdings-3" fullname="Wingdings 3" family="Wingdings 3" weight="400" style="normal" stretch="normal" glyphs="wingdng3.ttf" encoding="AppleRoman"/>
|
||||
</typemap>
|
21
ImageMagick-6.8.3-1/www/source/type.xml
Normal file
21
ImageMagick-6.8.3-1/www/source/type.xml
Normal file
|
@ -0,0 +1,21 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE typemap [
|
||||
<!ELEMENT typemap (type)+>
|
||||
<!ELEMENT type (#PCDATA)>
|
||||
<!ELEMENT include (#PCDATA)>
|
||||
<!ATTLIST type name CDATA #REQUIRED>
|
||||
<!ATTLIST type fullname CDATA #IMPLIED>
|
||||
<!ATTLIST type family CDATA #IMPLIED>
|
||||
<!ATTLIST type foundry CDATA #IMPLIED>
|
||||
<!ATTLIST type weight CDATA #IMPLIED>
|
||||
<!ATTLIST type style CDATA #IMPLIED>
|
||||
<!ATTLIST type stretch CDATA #IMPLIED>
|
||||
<!ATTLIST type format CDATA #IMPLIED>
|
||||
<!ATTLIST type metrics CDATA #IMPLIED>
|
||||
<!ATTLIST type glyphs CDATA #REQUIRED>
|
||||
<!ATTLIST type version CDATA #IMPLIED>
|
||||
<!ATTLIST include file CDATA #REQUIRED>
|
||||
]>
|
||||
<typemap>
|
||||
<include file="type-dejavu.xml" /> <include file="type-ghostscript.xml" />
|
||||
</typemap>
|
55
ImageMagick-6.8.3-1/www/source/wand.c
Normal file
55
ImageMagick-6.8.3-1/www/source/wand.c
Normal file
|
@ -0,0 +1,55 @@
|
|||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <wand/MagickWand.h>
|
||||
|
||||
int main(int argc,char **argv)
|
||||
{
|
||||
#define ThrowWandException(wand) \
|
||||
{ \
|
||||
char \
|
||||
*description; \
|
||||
\
|
||||
ExceptionType \
|
||||
severity; \
|
||||
\
|
||||
description=MagickGetException(wand,&severity); \
|
||||
(void) fprintf(stderr,"%s %s %lu %s\n",GetMagickModule(),description); \
|
||||
description=(char *) MagickRelinquishMemory(description); \
|
||||
exit(-1); \
|
||||
}
|
||||
|
||||
MagickBooleanType
|
||||
status;
|
||||
|
||||
MagickWand
|
||||
*magick_wand;
|
||||
|
||||
if (argc != 3)
|
||||
{
|
||||
(void) fprintf(stdout,"Usage: %s image thumbnail\n",argv[0]);
|
||||
exit(0);
|
||||
}
|
||||
/*
|
||||
Read an image.
|
||||
*/
|
||||
MagickWandGenesis();
|
||||
magick_wand=NewMagickWand();
|
||||
status=MagickReadImage(magick_wand,argv[1]);
|
||||
if (status == MagickFalse)
|
||||
ThrowWandException(magick_wand);
|
||||
/*
|
||||
Turn the images into a thumbnail sequence.
|
||||
*/
|
||||
MagickResetIterator(magick_wand);
|
||||
while (MagickNextImage(magick_wand) != MagickFalse)
|
||||
MagickResizeImage(magick_wand,106,80,LanczosFilter,1.0);
|
||||
/*
|
||||
Write the image then destroy it.
|
||||
*/
|
||||
status=MagickWriteImages(magick_wand,argv[2],MagickTrue);
|
||||
if (status == MagickFalse)
|
||||
ThrowWandException(magick_wand);
|
||||
magick_wand=DestroyMagickWand(magick_wand);
|
||||
MagickWandTerminus();
|
||||
return(0);
|
||||
}
|
106
ImageMagick-6.8.3-1/www/source/wand/sigmoidal-contrast.c
Normal file
106
ImageMagick-6.8.3-1/www/source/wand/sigmoidal-contrast.c
Normal file
|
@ -0,0 +1,106 @@
|
|||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <math.h>
|
||||
#include <wand/MagickWand.h>
|
||||
|
||||
static MagickBooleanType SigmoidalContrast(WandView *contrast_view,
|
||||
const ssize_t y,const int id,void *context)
|
||||
{
|
||||
#define QuantumScale ((MagickRealType) 1.0/(MagickRealType) QuantumRange)
|
||||
#define SigmoidalContrast(x) \
|
||||
(QuantumRange*(1.0/(1+exp(10.0*(0.5-QuantumScale*x)))-0.0066928509)*1.0092503)
|
||||
|
||||
RectangleInfo
|
||||
extent;
|
||||
|
||||
MagickPixelPacket
|
||||
pixel;
|
||||
|
||||
PixelWand
|
||||
**pixels;
|
||||
|
||||
register ssize_t
|
||||
x;
|
||||
|
||||
extent=GetWandViewExtent(contrast_view);
|
||||
pixels=GetWandViewPixels(contrast_view);
|
||||
for (x=0; x < (ssize_t) (extent.width-extent.x); x++)
|
||||
{
|
||||
PixelGetMagickColor(pixels[x],&pixel);
|
||||
pixel.red=SigmoidalContrast(pixel.red);
|
||||
pixel.green=SigmoidalContrast(pixel.green);
|
||||
pixel.blue=SigmoidalContrast(pixel.blue);
|
||||
pixel.index=SigmoidalContrast(pixel.index);
|
||||
PixelSetMagickColor(pixels[x],&pixel);
|
||||
}
|
||||
return(MagickTrue);
|
||||
}
|
||||
|
||||
int main(int argc,char **argv)
|
||||
{
|
||||
#define ThrowViewException(view) \
|
||||
{ \
|
||||
description=GetWandViewException(view,&severity); \
|
||||
(void) fprintf(stderr,"%s %s %lu %s\n",GetMagickModule(),description); \
|
||||
description=(char *) MagickRelinquishMemory(description); \
|
||||
exit(-1); \
|
||||
}
|
||||
#define ThrowWandException(wand) \
|
||||
{ \
|
||||
description=MagickGetException(wand,&severity); \
|
||||
(void) fprintf(stderr,"%s %s %lu %s\n",GetMagickModule(),description); \
|
||||
description=(char *) MagickRelinquishMemory(description); \
|
||||
exit(-1); \
|
||||
}
|
||||
|
||||
char
|
||||
*description;
|
||||
|
||||
ExceptionType
|
||||
severity;
|
||||
|
||||
MagickBooleanType
|
||||
status;
|
||||
|
||||
MagickPixelPacket
|
||||
pixel;
|
||||
|
||||
MagickWand
|
||||
*contrast_wand;
|
||||
|
||||
WandView
|
||||
*contrast_view;
|
||||
|
||||
if (argc != 3)
|
||||
{
|
||||
(void) fprintf(stdout,"Usage: %s image sigmoidal-image\n",argv[0]);
|
||||
exit(0);
|
||||
}
|
||||
/*
|
||||
Read an image.
|
||||
*/
|
||||
MagickWandGenesis();
|
||||
contrast_wand=NewMagickWand();
|
||||
status=MagickReadImage(contrast_wand,argv[1]);
|
||||
if (status == MagickFalse)
|
||||
ThrowWandException(contrast_wand);
|
||||
/*
|
||||
Sigmoidal non-linearity contrast control.
|
||||
*/
|
||||
contrast_view=NewWandView(contrast_wand);
|
||||
if (contrast_view == (WandView *) NULL)
|
||||
ThrowWandException(contrast_wand);
|
||||
status=UpdateWandViewIterator(contrast_view,SigmoidalContrast,(void *) NULL);
|
||||
if (status == MagickFalse)
|
||||
ThrowWandException(contrast_wand);
|
||||
contrast_view=DestroyWandView(contrast_view);
|
||||
/*
|
||||
Write the image then destroy it.
|
||||
*/
|
||||
status=MagickWriteImages(contrast_wand,argv[2],MagickTrue);
|
||||
if (status == MagickFalse)
|
||||
ThrowWandException(contrast_wand);
|
||||
contrast_wand=DestroyMagickWand(contrast_wand);
|
||||
MagickWandTerminus();
|
||||
return(0);
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue