File: arcball.h

package info (click to toggle)
gimp 2.8.18-1%2Bdeb9u1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 153,908 kB
  • sloc: ansic: 704,570; makefile: 10,969; lisp: 10,839; sh: 4,430; python: 3,793; perl: 3,411; xml: 1,307; yacc: 588; lex: 342
file content (50 lines) | stat: -rw-r--r-- 908 bytes parent folder | download | duplicates (9)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
#ifndef __ARCBALL_H__
#define __ARCBALL_H__

typedef struct
{
  double x, y, z, w;
} Quat;

enum QuatPart
{
  X,
  Y,
  Z,
  W,
  QuatLen
};

typedef Quat HVect;

typedef double HMatrix[QuatLen][QuatLen];

typedef enum AxisSet
{
  NoAxes,
  CameraAxes,
  BodyAxes,
  OtherAxes,
  NSets
} AxisSet;

typedef double *ConstraintSet;

extern Quat qOne;

void ArcBall_Init      (void);
void ArcBall_Place     (HVect    Center,
                        double   Radius);
void ArcBall_UseSet    (AxisSet  axis_Set);
void ArcBall_Update    (void);
void ArcBall_Value     (HMatrix  m_Now);
void ArcBall_Values    (double  *alpha,
                        double  *beta,
                        double  *gamma);
void ArcBall_BeginDrag (void);
void ArcBall_EndDrag   (void);
void ArcBall_Mouse     (HVect    v_Now);
void ArcBall_CopyMat   (HMatrix  inm,
                        HMatrix  outm);

#endif /* __ARCBALL_H__ */