resample.h 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107
  1. /* resample.h
  2. *
  3. * 20/9/09
  4. * - from proto.h
  5. */
  6. /*
  7. This file is part of VIPS.
  8. VIPS is free software; you can redistribute it and/or modify
  9. it under the terms of the GNU Lesser General Public License as published by
  10. the Free Software Foundation; either version 2 of the License, or
  11. (at your option) any later version.
  12. This program is distributed in the hope that it will be useful,
  13. but WITHOUT ANY WARRANTY; without even the implied warranty of
  14. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  15. GNU Lesser General Public License for more details.
  16. You should have received a copy of the GNU Lesser General Public License
  17. along with this program; if not, write to the Free Software
  18. Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
  19. 02110-1301 USA
  20. */
  21. /*
  22. These files are distributed with VIPS - http://www.vips.ecs.soton.ac.uk
  23. */
  24. #ifndef VIPS_RESAMPLE_H
  25. #define VIPS_RESAMPLE_H
  26. #ifdef __cplusplus
  27. extern "C" {
  28. #endif /*__cplusplus*/
  29. typedef enum {
  30. VIPS_KERNEL_NEAREST,
  31. VIPS_KERNEL_LINEAR,
  32. VIPS_KERNEL_CUBIC,
  33. VIPS_KERNEL_MITCHELL,
  34. VIPS_KERNEL_LANCZOS2,
  35. VIPS_KERNEL_LANCZOS3,
  36. VIPS_KERNEL_LAST
  37. } VipsKernel;
  38. typedef enum {
  39. VIPS_SIZE_BOTH,
  40. VIPS_SIZE_UP,
  41. VIPS_SIZE_DOWN,
  42. VIPS_SIZE_FORCE,
  43. VIPS_SIZE_LAST
  44. } VipsSize;
  45. int vips_shrink( VipsImage *in, VipsImage **out,
  46. double hshrink, double vshrink, ... )
  47. __attribute__((sentinel));
  48. int vips_shrinkh( VipsImage *in, VipsImage **out, int hshrink, ... )
  49. __attribute__((sentinel));
  50. int vips_shrinkv( VipsImage *in, VipsImage **out, int vshrink, ... )
  51. __attribute__((sentinel));
  52. int vips_reduce( VipsImage *in, VipsImage **out,
  53. double hshrink, double vshrink, ... )
  54. __attribute__((sentinel));
  55. int vips_reduceh( VipsImage *in, VipsImage **out, double hshrink, ... )
  56. __attribute__((sentinel));
  57. int vips_reducev( VipsImage *in, VipsImage **out, double vshrink, ... )
  58. __attribute__((sentinel));
  59. int vips_thumbnail( const char *filename, VipsImage **out, int width, ... )
  60. __attribute__((sentinel));
  61. int vips_thumbnail_buffer( void *buf, size_t len, VipsImage **out,
  62. int width, ... )
  63. __attribute__((sentinel));
  64. int vips_thumbnail_image( VipsImage *in, VipsImage **out, int width, ... )
  65. __attribute__((sentinel));
  66. int vips_thumbnail_source( VipsSource *source, VipsImage **out,
  67. int width, ... )
  68. __attribute__((sentinel));
  69. int vips_similarity( VipsImage *in, VipsImage **out, ... )
  70. __attribute__((sentinel));
  71. int vips_rotate( VipsImage *in, VipsImage **out, double angle, ... )
  72. __attribute__((sentinel));
  73. int vips_affine( VipsImage *in, VipsImage **out,
  74. double a, double b, double c, double d, ... )
  75. __attribute__((sentinel));
  76. int vips_resize( VipsImage *in, VipsImage **out, double scale, ... )
  77. __attribute__((sentinel));
  78. int vips_mapim( VipsImage *in, VipsImage **out, VipsImage *index, ... )
  79. __attribute__((sentinel));
  80. int vips_quadratic( VipsImage *in, VipsImage **out, VipsImage *coeff, ... )
  81. __attribute__((sentinel));
  82. #ifdef __cplusplus
  83. }
  84. #endif /*__cplusplus*/
  85. #endif /*VIPS_RESAMPLE_H*/