File: xform.h

package info (click to toggle)
gsumi 0.8-2
  • links: PTS
  • area: main
  • in suites: hamm
  • size: 344 kB
  • ctags: 421
  • sloc: ansic: 5,088; makefile: 58; sh: 17
file content (23 lines) | stat: -rw-r--r-- 652 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
/* Primitives for scale/offset transforms. */

#ifndef XFORM_H
#define XFORM_H

#include "rect.h"

typedef struct xform {
  double scale;
  double off_x, off_y;
} xform;

void xform_point (point *dst, const xform *x, const point *src);
void xform_rect (rect *dst, const xform *x, const rect *src);
void xform_inv (xform *dst, const xform *src);
/* This is also where xform_compose would go. */

/* Would transformations of regions go here or in region? Probably in
   region, just because there's a lot more region stuff than xform
   stuff going on in those routines. That just goes to show you the
   perils of breaking code into modules. */

#endif