/[escript]/trunk/pyvisi/py_src/constant.py
ViewVC logotype

Contents of /trunk/pyvisi/py_src/constant.py

Parent Directory Parent Directory | Revision Log Revision Log


Revision 947 - (show annotations)
Wed Jan 31 07:17:43 2007 UTC (12 years, 7 months ago) by jongui
File MIME type: text/x-python
File size: 3615 byte(s)
added some epydocs.
1 class Color:
2 """
3 Constants that define colors using RGB values.
4
5 @cvar RED: Constant representing red color
6 @cvar GREEN: Constant representing green color
7 @cvar BLUE: Constant representing blue color
8 @cvar BLACK: Constant representing black color
9 @cvar WHITE: Constant representing white color
10 @cvar YELLOW: Constant representing yellow color
11 @cvar PINK: Constant represnting pink color
12 @cvar ORANGE: Constant representing orange color
13 @cvar PURPLE: Constant representing purple color
14 @cvar GREY: Constant representing grey color
15 @cvar BROWN: Constant representing brown color
16 """
17
18 RED = [1, 0, 0]
19 GREEN = [0, 1, 0]
20 BLUE = [0, 0, 1]
21 BLACK = [0, 0, 0]
22 WHITE = [1, 1, 1]
23 YELLOW = [1,1,0]
24 PINK = [1, 0.0784, 0.4588]
25 ORANGE = [1, 0.2706, 0]
26 PURPLE = [0.5412, 0.1680, 0.8828]
27 GREY = [0.6602, 0.6602, 0.6602]
28 BROWN = [0.5430, 0.2700, 0.0742]
29
30 class Viewport:
31 """
32 Constants that define the four viewports in a window.
33
34 @cvar SOUTH_WEST: Constant representing the bottom left viewport of a
35 window
36 @cvar NORTH_WEST: Constant representing the upper left viewport of a
37 window
38 @cvar NORTH_EAST: Constatnt representing the upper right viewport of a
39 window
40 @cvar SOUTH_EAST: Constant representing the bottom right viewport of a window
41 """
42
43 SOUTH_WEST = 0
44 NORTH_WEST = 1
45 NORTH_EAST = 2
46 SOUTH_EAST = 3
47
48 class Source:
49 """
50 Constant that define the source data type.
51
52 @cvar XML: Constant representing the xml source data type
53 """
54
55 XML = "xml"
56
57 class Renderer:
58 """
59 Constants that define the renderer type.
60
61 @cvar ONLINE: Constant representing the online renderer
62 @cvar OFFLINE_JPG: Constant representing the JPG offline renderer
63 @cvar OFFLINE_BMP: Constant representing the BMP offline renderer
64 @cvar OFFLINE_PNM: Constant representing the PNM offline renderer
65 @cvar OFFLINE_PNG: Constant representing the PNG offline renderer
66 @cvar OFFLINE_TIF: Constant representing the TIF offline renderer
67 @cvar OFFLINE_PS: Constant representing the PS offline renderer
68 """
69
70 ONLINE = "online"
71 OFFLINE_JPG = "offline_jpeg"
72 OFFLINE_BMP = "offline_bmp"
73 OFFLINE_PNM = "offline_pnm"
74 OFFLINE_PNG = "offline_png"
75 OFFLINE_TIF = "offline_tiff"
76 OFFLINE_PS = "offline_ps"
77
78 class Arrow:
79 """
80 Constants that define the arrow type.
81
82 @cvar TWO_D: Constant representing the two dimensional arrow
83 @cvar THREE_D: Constant representing the three dimensional arrow
84 """
85
86 TWO_D = "2d"
87 THREE_D = "3d"
88
89 class ColorMode:
90 """
91 Constants that define the color mode used to color the data.
92
93 @cvar VECTOR: Constant representing the vector color mode
94 @cvar SCALAR: Constant representing the scalar color mode
95 """
96
97 VECTOR = "vector"
98 SCALAR = "scalar"
99
100 class WarpMode:
101 """
102 Constants that define the warp mode used to deform the scalar data.
103
104 @cvar VECTOR: Constant representing the vector deform mode
105 @cvar SCALAR: Constant representing the scalar deform mode
106 """
107
108 VECTOR = "vector"
109 SCALAR = "scalar"
110
111 class ImageFormat:
112 """
113 Constants that define the image formats.
114
115 @cvar JPG: Constant representing the JPG image format
116 @cvar BMP: Constant representing the BMP image format
117 @cvar PNM: Constant representing the PNM image format
118 @cvar PNG: Constant representing the PNG image format
119 @cvar TIF: Constant representing the TIF iamge format
120 """
121
122 JPG = "jpg"
123 BMP = "bmp"
124 PNM = "pnm"
125 PNG = "png"
126 TIF = "tif"
127
128 class Lut:
129 """
130 Constants that define the type of color mapping scheme for the lookup
131 table.
132
133 @cvar COLOR: Constant representing the color scheme
134 @cvar GREY_SCALE: Constant representing the grey scale scheme
135 """
136
137 COLOR = "color"
138 GREY_SCALE = "grey_scale"

  ViewVC Help
Powered by ViewVC 1.1.26