pytecplot 1.5.2__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (97) hide show
  1. pytecplot-1.5.2.dist-info/LICENSE.html +77 -0
  2. pytecplot-1.5.2.dist-info/METADATA +508 -0
  3. pytecplot-1.5.2.dist-info/RECORD +97 -0
  4. pytecplot-1.5.2.dist-info/WHEEL +5 -0
  5. pytecplot-1.5.2.dist-info/top_level.txt +1 -0
  6. tecplot/__init__.py +94 -0
  7. tecplot/annotation/__init__.py +7 -0
  8. tecplot/annotation/annotation.py +223 -0
  9. tecplot/annotation/geometry.py +369 -0
  10. tecplot/annotation/georeference.py +33 -0
  11. tecplot/annotation/image.py +185 -0
  12. tecplot/annotation/iter.py +105 -0
  13. tecplot/annotation/polyline.py +381 -0
  14. tecplot/annotation/text.py +744 -0
  15. tecplot/constant.py +401 -0
  16. tecplot/data/__init__.py +34 -0
  17. tecplot/data/array.py +645 -0
  18. tecplot/data/create.py +1 -0
  19. tecplot/data/dataset.py +1809 -0
  20. tecplot/data/extract.py +544 -0
  21. tecplot/data/face_neighbors.py +494 -0
  22. tecplot/data/facemap.py +814 -0
  23. tecplot/data/load.py +2075 -0
  24. tecplot/data/nodemap.py +577 -0
  25. tecplot/data/operate.py +928 -0
  26. tecplot/data/query.py +334 -0
  27. tecplot/data/save.py +343 -0
  28. tecplot/data/variable.py +280 -0
  29. tecplot/data/zone.py +841 -0
  30. tecplot/exception.py +201 -0
  31. tecplot/export/__init__.py +13 -0
  32. tecplot/export/animation.py +521 -0
  33. tecplot/export/export_setup.py +318 -0
  34. tecplot/export/image.py +577 -0
  35. tecplot/export/print_setup.py +218 -0
  36. tecplot/export/time_animation.py +607 -0
  37. tecplot/extension/__init__.py +14 -0
  38. tecplot/extension/ipython.py +68 -0
  39. tecplot/layout/__init__.py +20 -0
  40. tecplot/layout/frame.py +1285 -0
  41. tecplot/layout/layout.py +488 -0
  42. tecplot/layout/page.py +541 -0
  43. tecplot/legend/__init__.py +4 -0
  44. tecplot/legend/contour_legend.py +516 -0
  45. tecplot/legend/legend.py +141 -0
  46. tecplot/legend/line_legend.py +66 -0
  47. tecplot/legend/rgb_coloring_legend.py +291 -0
  48. tecplot/legend/scatter_legend.py +136 -0
  49. tecplot/macro.py +339 -0
  50. tecplot/plot/__init__.py +62 -0
  51. tecplot/plot/axes.py +881 -0
  52. tecplot/plot/axis.py +1350 -0
  53. tecplot/plot/blanking.py +584 -0
  54. tecplot/plot/contour.py +1302 -0
  55. tecplot/plot/effects.py +162 -0
  56. tecplot/plot/fieldmap.py +2159 -0
  57. tecplot/plot/grid.py +758 -0
  58. tecplot/plot/isosurface.py +1167 -0
  59. tecplot/plot/labels.py +338 -0
  60. tecplot/plot/linemap.py +1905 -0
  61. tecplot/plot/linking.py +489 -0
  62. tecplot/plot/plot.py +1791 -0
  63. tecplot/plot/rgb_coloring.py +281 -0
  64. tecplot/plot/scatter.py +396 -0
  65. tecplot/plot/slice.py +1544 -0
  66. tecplot/plot/streamtrace.py +1949 -0
  67. tecplot/plot/symbol.py +567 -0
  68. tecplot/plot/ticks.py +666 -0
  69. tecplot/plot/title.py +380 -0
  70. tecplot/plot/vector.py +679 -0
  71. tecplot/plot/view.py +868 -0
  72. tecplot/session/__init__.py +112 -0
  73. tecplot/session/aux_data.py +276 -0
  74. tecplot/session/config.py +92 -0
  75. tecplot/session/session.py +425 -0
  76. tecplot/session/state_changed.py +225 -0
  77. tecplot/session/style.py +504 -0
  78. tecplot/tecutil/__init__.py +16 -0
  79. tecplot/tecutil/arglist.py +230 -0
  80. tecplot/tecutil/captured_output.py +177 -0
  81. tecplot/tecutil/constant.py +1312 -0
  82. tecplot/tecutil/index_set.py +118 -0
  83. tecplot/tecutil/lock.py +36 -0
  84. tecplot/tecutil/message_pb2.py +39 -0
  85. tecplot/tecutil/preamble.py +54 -0
  86. tecplot/tecutil/stringlist.py +114 -0
  87. tecplot/tecutil/sv.py +1662 -0
  88. tecplot/tecutil/tecutil.py +12402 -0
  89. tecplot/tecutil/tecutil_client.py +627 -0
  90. tecplot/tecutil/tecutil_connector.py +937 -0
  91. tecplot/tecutil/tecutil_rpc.py +6845 -0
  92. tecplot/tecutil/util.py +332 -0
  93. tecplot/text/__init__.py +3 -0
  94. tecplot/text/font.py +224 -0
  95. tecplot/text/label_format.py +374 -0
  96. tecplot/text/textbox.py +106 -0
  97. tecplot/version.py +41 -0
@@ -0,0 +1,162 @@
1
+ from builtins import super
2
+
3
+ from ..tecutil import sv
4
+ from .. import session
5
+
6
+
7
+ class LightSource(session.Style):
8
+ """Three-dimensional light source style control.
9
+
10
+ The light source is a point of light infinitely far from the drawing area.
11
+
12
+ .. code-block:: python
13
+ :emphasize-lines: 13-16
14
+
15
+ from os import path
16
+ import tecplot as tp
17
+ from tecplot.constant import PlotType, Color
18
+
19
+ examples_dir = tp.session.tecplot_examples_directory()
20
+ infile = path.join(examples_dir, 'SimpleData', 'F18.plt')
21
+ dataset = tp.data.load_tecplot(infile)
22
+
23
+ frame = tp.active_frame()
24
+ plot = frame.plot(PlotType.Cartesian3D)
25
+ plot.activate()
26
+
27
+ plot.light_source.direction = (0., -0.7, 0.9)
28
+ plot.light_source.intensity = 70
29
+ plot.light_source.specular_intensity = 80
30
+ plot.light_source.specular_shininess = 50
31
+
32
+ tp.export.save_png('light_source.png')
33
+
34
+ .. figure:: /_static/images/light_source.png
35
+ :width: 300px
36
+ :figwidth: 300px
37
+ """
38
+ def __init__(self, plot):
39
+ self.plot = plot
40
+ super().__init__(sv.GLOBALTHREED, sv.LIGHTSOURCE,
41
+ uniqueid=self.plot.frame.uid)
42
+
43
+ @property
44
+ def background_light(self):
45
+ """`float`: Percentage intensity of the omni-directional fill light.
46
+
47
+ Example usage::
48
+
49
+ >>> plot.light_source.background_light = 70.0
50
+ """
51
+ return self._get_style(float, sv.BACKGROUNDLIGHT)
52
+
53
+ @background_light.setter
54
+ def background_light(self, value):
55
+ self._set_style(float(value), sv.BACKGROUNDLIGHT)
56
+
57
+ @property
58
+ def intensity(self):
59
+ """`float`: Percentage intensity of the light source.
60
+
61
+ Example usage::
62
+
63
+ >>> plot.light_source.intensity = 50.0
64
+ """
65
+ return self._get_style(float, sv.INTENSITY)
66
+
67
+ @intensity.setter
68
+ def intensity(self, value):
69
+ self._set_style(float(value), sv.INTENSITY)
70
+
71
+ @property
72
+ def specular_intensity(self):
73
+ """`float`: Percentage intensity of specular highlights.
74
+
75
+ Set this to zero to turn off specular effects::
76
+
77
+ >>> plot.light_source.specular_intensity = 0
78
+ """
79
+ if self._get_style(bool, sv.INCLUDESPECULAR):
80
+ return self._get_style(float, sv.SPECULARINTENSITY)
81
+ else:
82
+ return 0
83
+
84
+ @specular_intensity.setter
85
+ def specular_intensity(self, value):
86
+ if not value:
87
+ self._set_style(False, sv.INCLUDESPECULAR)
88
+ else:
89
+ self._set_style(True, sv.INCLUDESPECULAR)
90
+ self._set_style(float(value), sv.SPECULARINTENSITY)
91
+
92
+ @property
93
+ def specular_shininess(self):
94
+ """`float`: Percentage of shininess for specular highlights.
95
+
96
+ Example usage::
97
+
98
+ >>> plot.light_source.specular_shininess = 80.0
99
+ """
100
+ return self._get_style(float, sv.SPECULARSHININESS)
101
+
102
+ @specular_shininess.setter
103
+ def specular_shininess(self, value):
104
+ self._set_style(float(value), sv.SPECULARSHININESS)
105
+
106
+ @property
107
+ def surface_color_contrast(self):
108
+ """`float`: Percentage of contrast for surface colors.
109
+
110
+ Example usage::
111
+
112
+ >>> plot.light_source.surface_color_contrast = 80.0
113
+ """
114
+ return self._get_style(float, sv.SURFACECOLORCONTRAST)
115
+
116
+ @surface_color_contrast.setter
117
+ def surface_color_contrast(self, value):
118
+ self._set_style(float(value), sv.SURFACECOLORCONTRAST)
119
+
120
+ @property
121
+ def direction(self):
122
+ """`tuple`: :math:`(x, y, z)` direction of the light rays.
123
+
124
+ The direction is in the view coordinate system where :math:`z` goes
125
+ into the page and the origin of :math:`(x, y)` is in the lower left
126
+ corner. The default is :math:`(-0.2, -0.2, 0.959)`::
127
+
128
+ >>> plot.light_source.direction = (0, -0.7, 0.9)
129
+ """
130
+ return session.XYZ(self, sv.XYZDIRECTION)
131
+
132
+ @direction.setter
133
+ def direction(self, values):
134
+ session.XYZ(self, sv.XYZDIRECTION)[:] = values
135
+
136
+ @property
137
+ def force_gouraud_for_contour_flood(self):
138
+ """`bool`: Force gouraud effects for shaded continuous flooding.
139
+
140
+ Example usage::
141
+
142
+ >>> plot.light_source.force_gouraud_for_contour_flood = True
143
+ """
144
+ return self._get_style(bool, sv.FORCEGOURAUDFOR3DCONTFLOOD)
145
+
146
+ @force_gouraud_for_contour_flood.setter
147
+ def force_gouraud_for_contour_flood(self, value):
148
+ self._set_style(bool(value), sv.FORCEGOURAUDFOR3DCONTFLOOD)
149
+
150
+ @property
151
+ def force_paneled_for_cell_flood(self):
152
+ """`bool`: Force paneled effects for shaded cell flooding.
153
+
154
+ Example usage::
155
+
156
+ >>> plot.light_source.force_paneled_for_cell_flood = True
157
+ """
158
+ return self._get_style(bool, sv.FORCEPANELEDFOR3DCELLFLOOD)
159
+
160
+ @force_paneled_for_cell_flood.setter
161
+ def force_paneled_for_cell_flood(self, value):
162
+ self._set_style(bool(value), sv.FORCEPANELEDFOR3DCELLFLOOD)