2 Copyright 1999-2011 ImageMagick Studio LLC, a non-profit organization
3 dedicated to making software imaging solutions freely available.
5 You may not use this file except in compliance with the License.
6 obtain a copy of the License at
8 http://www.imagemagick.org/script/license.php
10 Unless required by applicable law or agreed to in writing, software
11 distributed under the License is distributed on an "AS IS" BASIS,
12 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 See the License for the specific language governing permissions and
14 limitations under the License.
16 MagickCore graphic resample methods.
18 #ifndef _MAGICKCORE_RESAMPLE_H
19 #define _MAGICKCORE_RESAMPLE_H
21 #if defined(__cplusplus) || defined(c_plusplus)
25 #include <magick/cache-view.h>
28 WARNING: The order of this table must also match the order
29 of a table located in AcquireResizeFilter() or "resize.c"
30 Otherwise the users filter will not match the actual filter
62 SentinelFilter /* a count of all the filters, not a real filter */
65 /* Backward compatibility for the more correctly named Jinc Filter
66 Original sorce of this filter is from "zoom" but it refers to
67 a reference by Pratt, who does not actualy name the filter.
69 #define BesselFilter JincFilter
74 UndefinedInterpolatePixel,
75 AverageInterpolatePixel,
76 BicubicInterpolatePixel,
77 BilinearInterpolatePixel,
78 FilterInterpolatePixel,
79 IntegerInterpolatePixel,
81 NearestNeighborInterpolatePixel,
82 SplineInterpolatePixel
83 } InterpolatePixelMethod;
85 typedef struct _ResampleFilter
88 extern MagickExport MagickBooleanType
89 ResamplePixelColor(ResampleFilter *,const double,const double,
91 SetResampleFilterInterpolateMethod(ResampleFilter *,
92 const InterpolatePixelMethod),
93 SetResampleFilterVirtualPixelMethod(ResampleFilter *,
94 const VirtualPixelMethod);
96 extern MagickExport ResampleFilter
97 *AcquireResampleFilter(const Image *,ExceptionInfo *),
98 *DestroyResampleFilter(ResampleFilter *);
100 extern MagickExport void
101 ScaleResampleFilter(ResampleFilter *,const double,const double,const double,
103 SetResampleFilter(ResampleFilter *,const FilterTypes,const double);
105 #if defined(__cplusplus) || defined(c_plusplus)