## transform

transform

## Synopsis

                        Transformation;
    void                im__transform_init                  (Transformation *trn);
    int                 im__transform_calc_inverse          (Transformation *trn);
    int                 im__transform_isidentity            (const Transformation *trn);
    int                 im__transform_add                   (const Transformation *in1,
                                                             const Transformation *in2,
                                                             Transformation *out);
    void                im__transform_print                 (const Transformation *trn);
    void                im__transform_forward_point         (const Transformation *trn,
                                                             const double x,
                                                             const double y,
                                                             double *ox,
                                                             double *oy);
    void                im__transform_invert_point          (const Transformation *trn,
                                                             const double x,
                                                             const double y,
                                                             double *ox,
                                                             double *oy);
    void                im__transform_forward_rect          (const Transformation *trn,
                                                             const VipsRect *in,
                                                             VipsRect *out);
    void                im__transform_invert_rect           (const Transformation *trn,
                                                             const VipsRect *in,
                                                             VipsRect *out);
    void                im__transform_set_area              (Transformation *Param1);
    int                 im__affine                          (VipsImage *in,
                                                             VipsImage *out,
                                                             Transformation *trn);

## Description

## Details

### Transformation

    typedef struct {
    	/* Area of input we can use. This can be smaller than the real input
    	 * image: we expand the input to add extra pixels for interpolation.
    	 */
    	VipsRect iarea;

    	/* The area of the output we've been asked to generate. left/top can
    	 * be negative.
    	 */
    	VipsRect oarea;

    	/* The transform.
    	 */
    	double a, b, c, d;
    	double dx, dy;

    	double ia, ib, ic, id;		/* Inverse of matrix abcd */
    } Transformation;

### im__transform_init ()

    void                im__transform_init                  (Transformation *trn);

### im__transform_calc_inverse ()

    int                 im__transform_calc_inverse          (Transformation *trn);

### im__transform_isidentity ()

    int                 im__transform_isidentity            (const Transformation *trn);

### im__transform_add ()

    int                 im__transform_add                   (const Transformation *in1,
                                                             const Transformation *in2,
                                                             Transformation *out);

### im__transform_print ()

    void                im__transform_print                 (const Transformation *trn);

### im__transform_forward_point ()

    void                im__transform_forward_point         (const Transformation *trn,
                                                             const double x,
                                                             const double y,
                                                             double *ox,
                                                             double *oy);

### im__transform_invert_point ()

    void                im__transform_invert_point          (const Transformation *trn,
                                                             const double x,
                                                             const double y,
                                                             double *ox,
                                                             double *oy);

### im__transform_forward_rect ()

    void                im__transform_forward_rect          (const Transformation *trn,
                                                             const VipsRect *in,
                                                             VipsRect *out);

### im__transform_invert_rect ()

    void                im__transform_invert_rect           (const Transformation *trn,
                                                             const VipsRect *in,
                                                             VipsRect *out);

### im__transform_set_area ()

    void                im__transform_set_area              (Transformation *Param1);

### im__affine ()

    int                 im__affine                          (VipsImage *in,
                                                             VipsImage *out,
                                                             Transformation *trn);