1 |
""" |
2 |
@var __author__: name of author |
3 |
@var __copyright__: copyrights |
4 |
@var __license__: licence agreement |
5 |
@var __url__: url entry point on documentation |
6 |
@var __version__: version |
7 |
@var __date__: date of the version |
8 |
""" |
9 |
|
10 |
__author__="John Ngui, john.ngui@uq.edu.au" |
11 |
__copyright__=""" Copyright (c) 2006 by ACcESS MNRF |
12 |
http://www.access.edu.au |
13 |
Primary Business: Queensland, Australia""" |
14 |
__license__="""Licensed under the Open Software License version 3.0 |
15 |
http://www.opensource.org/licenses/osl-3.0.php""" |
16 |
__url__="http://www.iservo.edu.au/esys" |
17 |
__version__="$Revision$" |
18 |
__date__="$Date$" |
19 |
|
20 |
|
21 |
class Color: |
22 |
""" |
23 |
Constants that define the colors using RGB values. |
24 |
|
25 |
@cvar RED: Constant representing red color |
26 |
@cvar GREEN: Constant representing green color |
27 |
@cvar BLUE: Constant representing blue color |
28 |
@cvar BLACK: Constant representing black color |
29 |
@cvar WHITE: Constant representing white color |
30 |
@cvar YELLOW: Constant representing yellow color |
31 |
@cvar PINK: Constant represnting pink color |
32 |
@cvar ORANGE: Constant representing orange color |
33 |
@cvar PURPLE: Constant representing purple color |
34 |
@cvar GREY: Constant representing grey color |
35 |
@cvar BROWN: Constant representing brown color |
36 |
""" |
37 |
|
38 |
RED = [1, 0, 0] |
39 |
GREEN = [0, 1, 0] |
40 |
BLUE = [0, 0, 1] |
41 |
BLACK = [0, 0, 0] |
42 |
WHITE = [1, 1, 1] |
43 |
YELLOW = [1,1,0] |
44 |
PINK = [1, 0.0784, 0.4588] |
45 |
ORANGE = [1, 0.2706, 0] |
46 |
PURPLE = [0.5412, 0.1680, 0.8828] |
47 |
GREY = [0.6602, 0.6602, 0.6602] |
48 |
BROWN = [0.5430, 0.2700, 0.0742] |
49 |
|
50 |
class Viewport: |
51 |
""" |
52 |
Constants that define the four viewports in a window. |
53 |
|
54 |
@cvar SOUTH_WEST: Constant representing the bottom-left viewport of a |
55 |
window |
56 |
@cvar NORTH_WEST: Constant representing the upper-left viewport of a |
57 |
window |
58 |
@cvar NORTH_EAST: Constatnt representing the upper-right viewport of a |
59 |
window |
60 |
@cvar SOUTH_EAST: Constant representing the bottom-right viewport of a window |
61 |
""" |
62 |
|
63 |
SOUTH_WEST = 0 |
64 |
NORTH_WEST = 1 |
65 |
NORTH_EAST = 2 |
66 |
SOUTH_EAST = 3 |
67 |
|
68 |
class Source: |
69 |
""" |
70 |
Constants that define the data source type. |
71 |
|
72 |
@cvar XML: Constant representing xml as the source type |
73 |
@cvar ESCRIPT: Constant representing escript data objects the source type |
74 |
""" |
75 |
|
76 |
XML = "xml" |
77 |
ESCRIPT = "escript" |
78 |
|
79 |
class Renderer: |
80 |
""" |
81 |
Constants that define the renderer type. |
82 |
|
83 |
@cvar ONLINE: Constant representing the online renderer |
84 |
@cvar ONLINE_JPG: Constant representing the JPG online renderer |
85 |
@cvar ONLINE_BMP: Constant representing the BMP online renderer |
86 |
@cvar ONLINE_PNM: Constant representing the PNM online renderer |
87 |
@cvar ONLINE_PNG: Constant representing the PNG online renderer |
88 |
@cvar ONLINE_TIF: Constant representing the TIF online renderer |
89 |
@cvar ONLINE_PS: Constant representing the PS online renderer |
90 |
@cvar ONLINE_VRML: Constant representing the VRML online renderer |
91 |
@cvar ONLINE_IV: Constant representing the OpenInventor online renderer |
92 |
|
93 |
@cvar OFFLINE_JPG: Constant representing the JPG offline renderer |
94 |
@cvar OFFLINE_BMP: Constant representing the BMP offline renderer |
95 |
@cvar OFFLINE_PNM: Constant representing the PNM offline renderer |
96 |
@cvar OFFLINE_PNG: Constant representing the PNG offline renderer |
97 |
@cvar OFFLINE_TIF: Constant representing the TIF offline renderer |
98 |
@cvar OFFLINE_PS: Constant representing the PS offline renderer |
99 |
@cvar OFFLINE_VRML: Constant representing the VRML offline renderer |
100 |
@cvar OFFLINE_IV: Constant representing the OpenInventor offline renderer |
101 |
|
102 |
@cvar DISPLAY: Constant representing the display renderer |
103 |
@cvar DISPLAY_JPG: Constant representing the JPG display renderer |
104 |
@cvar DISPLAY_BMP: Constant representing the BMP display renderer |
105 |
@cvar DISPLAY_PNM: Constant representing the PNM display renderer |
106 |
@cvar DISPLAY_PNG: Constant representing the PNG display renderer |
107 |
@cvar DISPLAY_TIF: Constant representing the TIF display renderer |
108 |
@cvar DISPLAY_PS: Constant representing the PS display renderer |
109 |
@cvar DISPLAY_VRML: Constant representing the VRML display renderer |
110 |
@cvar DISPLAY_IV: Constant representing the OpenInventor display renderer |
111 |
""" |
112 |
|
113 |
ONLINE = "online" |
114 |
ONLINE_JPG = "online_jpg" |
115 |
ONLINE_BMP = "online_bmp" |
116 |
ONLINE_PNM = "online_pnm" |
117 |
ONLINE_PNG = "online_png" |
118 |
ONLINE_TIF = "online_tif" |
119 |
ONLINE_PS = "online_ps" |
120 |
ONLINE_VRML = "online_vrml" |
121 |
ONLINE_IV = "online_iv" |
122 |
|
123 |
OFFLINE_JPG = "offline_jpg" |
124 |
OFFLINE_BMP = "offline_bmp" |
125 |
OFFLINE_PNM = "offline_pnm" |
126 |
OFFLINE_PNG = "offline_png" |
127 |
OFFLINE_TIF = "offline_tif" |
128 |
OFFLINE_PS = "offline_ps" |
129 |
OFFLINE_VRML = "offline_vrml" |
130 |
OFFLINE_IV = "offline_iv" |
131 |
|
132 |
DISPLAY = "display" |
133 |
DISPLAY_JPG = "display_jpg" |
134 |
DISPLAY_BMP = "display_bmp" |
135 |
DISPLAY_PNM = "display_pnm" |
136 |
DISPLAY_PNG = "display_png" |
137 |
DISPLAY_TIF = "display_tif" |
138 |
DISPLAY_PS = "display_ps" |
139 |
DISPLAY_VRML = "display_vrml" |
140 |
DISPLAY_IV = "display_iv" |
141 |
|
142 |
class Arrow: |
143 |
""" |
144 |
Constants that define the arrow type. |
145 |
|
146 |
@cvar TWO_D: Constant representing the two dimensional arrow type |
147 |
@cvar THREE_D: Constant representing the three dimensional arrow type |
148 |
""" |
149 |
|
150 |
TWO_D = "2d" |
151 |
THREE_D = "3d" |
152 |
|
153 |
class ColorMode: |
154 |
""" |
155 |
Constants that define the color mode used to color the data. |
156 |
|
157 |
@cvar VECTOR: Constant representing the vector color mode |
158 |
@cvar SCALAR: Constant representing the scalar color mode |
159 |
""" |
160 |
|
161 |
VECTOR = "vector" |
162 |
SCALAR = "scalar" |
163 |
|
164 |
class WarpMode: |
165 |
""" |
166 |
Constants that define the warp mode used to deform the scalar data. |
167 |
|
168 |
@cvar VECTOR: Constant representing the vector deformation mode |
169 |
@cvar SCALAR: Constant representing the scalar deformation mode |
170 |
""" |
171 |
|
172 |
VECTOR = "vector" |
173 |
SCALAR = "scalar" |
174 |
|
175 |
class ImageFormat: |
176 |
""" |
177 |
Constants that define the image formats. |
178 |
|
179 |
@cvar JPG: Constant representing the JPG image format (.jpg) |
180 |
@cvar BMP: Constant representing the BMP image format (.bmp) |
181 |
@cvar PNM: Constant representing the PNM image format (.pnm) |
182 |
@cvar PNG: Constant representing the PNG image format (.png) |
183 |
@cvar TIF: Constant representing the TIF image format (.tif) |
184 |
@cvar PS: Constant representing the PS image format (.ps) |
185 |
""" |
186 |
|
187 |
JPG = "jpg" |
188 |
BMP = "bmp" |
189 |
PNM = "pnm" |
190 |
PNG = "png" |
191 |
TIF = "tif" |
192 |
PS = "ps" |
193 |
|
194 |
class Lut: |
195 |
""" |
196 |
Constants that define the type of mapping scheme for the lookup table. |
197 |
|
198 |
@cvar COLOR: Constant representing the color scheme |
199 |
@cvar GREY_SCALE: Constant representing the grey scale scheme |
200 |
""" |
201 |
|
202 |
COLOR = "color" |
203 |
GREY_SCALE = "grey_scale" |
204 |
|
205 |
class LegendType: |
206 |
""" |
207 |
Constants that define the type of legend for the scalar bar. |
208 |
|
209 |
@cvar SCALAR: Constant representing the legend using scalar data |
210 |
@cvar VECTOR: Constant representing the legend using vector data |
211 |
""" |
212 |
|
213 |
SCALAR = "scalar" |
214 |
VECTOR = "vector" |