File: thwarppdef.h

package info (click to toggle)
therion 5.3.3-1
  • links: PTS
  • area: main
  • in suites: squeeze
  • size: 16,888 kB
  • ctags: 14,686
  • sloc: ansic: 125,669; cpp: 89,022; tcl: 23,212; perl: 2,051; makefile: 920; asm: 174; python: 54; sh: 4
file content (101 lines) | stat: -rw-r--r-- 2,568 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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
/** @file thwarppdef.h
 * 
 * @author marco corvi
 * @date   mar 2007
 * 
 * @brief warping transformation definitions
 */
/* Copyright (C) 2007 marco corvi
 * 
 * $Date: $
 * $RCSfile: $
 * $Revision: $
 *
 * -------------------------------------------------------------------- 
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 2 of the License, or
 * any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 * 
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 * --------------------------------------------------------------------
 */
#ifndef thwarppdef_h
#define thwarppdef_h
#define THERION

// #define BOUND_SEGMENT 1.5
#define BOUND_TRIANGLE 1.5
#define BOUND_PLAQUETTE 2.0


#define MORPH_USE_BD
#define MORPH_BD 0.5

/** whether or not to use rotation
 */
#define MORPH_ROTATE 1

/** a multiplicative factor for the angle differences
 */
#define MORPH_ANGLE_FACTOR 0.5

namespace therion
{
  namespace warp
  {
    
    /** type of the warping control objects
     * overused for point-pairs and lines
     */
    enum morph_type 
    {
      THMORPH_STATION,   /* station point | centerline shot */
      THMORPH_LEFT,      /* left point    | left shot */
      THMORPH_RIGHT,     /* right point   | right shot */
      THMORPH_SEGMENT,   /* -             | straight end segment */
      THMORPH_EXTRA,
    };
    
    /** warping projection type
     */
    enum warp_proj 
    {
      THWARP_PLAN,       /* plan */
      THWARP_EXTENDED,   /* extended elevation */
    };
    
    /** warping pair types
     */
    enum warp_type
    {
      THWARP_NONE = 0,
      THWARP_POINT = 1,
      THWARP_SEGMENT = 2,
      THWARP_TRIANGLE = 3,
      THWARP_PLAQUETTE = 4
    };
  } // namespace warp
} // namespace therion

// *****************************************************************
// backward compatibility
//
#ifdef THERION
  typedef therion::warp::morph_type thmorph_type;
  typedef therion::warp::warp_proj  thwarp_proj;

  using therion::warp::THMORPH_STATION;
  using therion::warp::THMORPH_EXTRA;

#endif

#endif // thwarppdef_h