Movatterモバイル変換


[0]ホーム

URL:


Operator index > By section > Resample[src]

These operations build on each other in a set of layers.

First,vips_affine() applies an affine transform to an image. Thisis any sort of 2D transform which preserves straight lines; so any combinationof stretch, sheer, rotate and translate. You supply an interpolator for it touse to generate pixels, seevips_interpolate_new(). It will not produce goodresults for very large shrinks: you’ll see aliasing.

vips_reduce() is likevips_affine(), but it can only shrinkimages, it can’t enlarge, rotate, or skew. It’s very fast and uses an adaptivekernel for interpolation.

vips_shrink() is a fast block shrinker. It can quickly reduce imagesby large integer factors. It will give poor results for small size reductions:again, you’ll see aliasing.

Next,vips_resize() specialises in the common task of image reduce andenlarge. It strings together combinations ofvips_shrink(),vips_reduce(),vips_affine() and others to implement a general,high-quality image resizer.

Finally,vips_thumbnail() combines load and resize in one operation, andadds colour management and correct handling of alpha transparency. Becauseload and resize happen together, it can exploit tricks likeJPEG andTIFFshrink-on-load, giving a (potentially) huge speedup.vips_thumbnail_image() is only there for emergencies, don’t use itunless you really have to.

As a separate thing,vips_mapim() can apply arbitrary 2D imagetransforms to an image.

Classes

Callbacks

Functions

Constants

Enumerations


[8]ページ先頭

©2009-2025 Movatter.jp