lavavu 1.9.7__cp313-cp313-win_amd64.whl → 1.9.9__cp313-cp313-win_amd64.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.
Binary file
lavavu/dict.json CHANGED
@@ -2147,6 +2147,17 @@
2147
2147
  false
2148
2148
  ]
2149
2149
  },
2150
+ "upscalelines": {
2151
+ "default": false,
2152
+ "target": "global",
2153
+ "type": "real",
2154
+ "desc": "Enable to scale lines with the viewport size.",
2155
+ "strict": true,
2156
+ "redraw": 0,
2157
+ "control": [
2158
+ true
2159
+ ]
2160
+ },
2150
2161
  "fps": {
2151
2162
  "default": false,
2152
2163
  "target": "global",
lavavu/html/webview.html CHANGED
@@ -27,7 +27,7 @@
27
27
 
28
28
  <input id="fileinput" type="file" style="visibility:hidden" onchange="useFileInput(this)" />
29
29
 
30
- <script async src="https://cdn.jsdelivr.net/gh/lavavu/lavavu.github.io@1.9.7/LavaVu-amalgamated.min.js"></script>
30
+ <script async src="https://cdn.jsdelivr.net/gh/lavavu/lavavu.github.io@1.9.9/LavaVu-amalgamated.min.js"></script>
31
31
  <!--script src="dat.gui.min.js"></script>
32
32
  <script src="OK-min.js"></script>
33
33
 
@@ -8,7 +8,6 @@ uniform mat4 uMVMatrix;
8
8
  uniform mat4 uPMatrix;
9
9
  uniform mat4 uNMatrix;
10
10
 
11
- uniform vec4 uColour;
12
11
  uniform vec4 uLightPos;
13
12
 
14
13
  out vec4 vColour;
@@ -26,11 +25,10 @@ void main(void)
26
25
 
27
26
  vNormal = normalize(mat3(uNMatrix) * aVertexNormal);
28
27
 
29
- if (uColour.a > 0.0)
30
- vColour = uColour;
31
- else
32
- vColour = aVertexColour;
33
-
28
+ //This shader only applies attribute colour
29
+ //uColour is set for other/custom shaders
30
+ //Note uOpacity is "alpha" prop, "oapcity" is passed via attrib
31
+ vColour = aVertexColour;
34
32
  vTexCoord = aVertexTexCoord;
35
33
  vFlatColour = vColour;
36
34
  vVertex = aVertexPosition;
lavavu/tracers.py CHANGED
@@ -24,7 +24,7 @@ def random_particles(count, lowerbound=[0,0,0], upperbound=[1,1,1], dims=3):
24
24
  return numpy.stack(p).T
25
25
 
26
26
  class Tracers():
27
- def __init__(self, grid, count=1000, lowerbound=None, upperbound=None, limit=None, age=4, respawn_chance=0.2, speed_multiply=1.0, height=0.0, viewer=None):
27
+ def __init__(self, grid, count=1000, lowerbound=None, upperbound=None, limit=None, age=4, respawn_chance=0.2, speed_multiply=1.0, height=0.0, label='', viewer=None):
28
28
  """
29
29
  Seed random particles into a vector field and trace their positions
30
30
 
@@ -52,6 +52,8 @@ class Tracers():
52
52
  Speed multiplier, scaling factor for the velocity taken from the vector values
53
53
  height : float
54
54
  A fixed height value, all positions will be given this height as their Z component
55
+ label : str
56
+ Name label prefix for the visualisation objects when plotting
55
57
  viewer : lavavu.Viewer
56
58
  Viewer object for plotting functions
57
59
  """
@@ -100,6 +102,7 @@ class Tracers():
100
102
  self.speed_multiply = speed_multiply
101
103
  self.height = height
102
104
 
105
+ self.label = label
103
106
  self.lv = viewer
104
107
  self.points = None
105
108
  self.arrows = None
@@ -157,8 +160,8 @@ class Tracers():
157
160
  self.speed[r] = 0.0
158
161
 
159
162
  if self.lv:
160
- positions = self.positions
161
- if self.dims == 2 and self.height != 0:
163
+ positions = self.get_positions()
164
+ if positions.shape[1] == 2 and self.height != 0:
162
165
  #Convert to 3d and set z coord to height
163
166
  shape = list(positions.shape)
164
167
  shape[-1] = 3
@@ -180,15 +183,25 @@ class Tracers():
180
183
  if len(self.tracers["colourmap"]):
181
184
  self.tracers.values(self.speed)
182
185
 
186
+ def get_positions(self):
187
+ """
188
+ This funcion can be overridden if positions need to be transformed
189
+ in any way before plotting, eg: plotting on spherical earth model
190
+ """
191
+ return self.positions
192
+
193
+ def prefix(self):
194
+ return self.label + '_' if len(self.label) else ''
195
+
183
196
  def plot_points(self, **kwargs):
184
197
  if self.lv is not None and self.points is None:
185
- self.points = self.lv.points('tracer_points', **kwargs)
198
+ self.points = self.lv.points(self.prefix() + 'tracer_points', **kwargs)
186
199
 
187
200
  def plot_arrows(self, **kwargs):
188
201
  if self.lv is not None and self.arrows is None:
189
- self.arrows = self.lv.vectors('tracer_arrows', **kwargs)
202
+ self.arrows = self.lv.vectors(self.prefix() + 'tracer_arrows', **kwargs)
190
203
 
191
204
  def plot_tracers(self, **kwargs):
192
205
  if self.lv is not None and self.tracers is None:
193
- self.tracers = self.lv.tracers('tracers', dims=self.count, limit=self.limit, **kwargs)
206
+ self.tracers = self.lv.tracers(self.prefix() + 'tracers', dims=self.count, limit=self.limit, **kwargs)
194
207
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: lavavu
3
- Version: 1.9.7
3
+ Version: 1.9.9
4
4
  Summary: Python interface to LavaVu OpenGL 3D scientific visualisation utilities
5
5
  Author-email: Owen Kaluza <owen@kaluza.id.au>
6
6
  License: ### Licensing
@@ -224,7 +224,7 @@ Dynamic: license-file
224
224
  [![Build Status](https://github.com/lavavu/LavaVu/workflows/Test/badge.svg)](https://github.com/lavavu/LavaVu/actions?query=workflow:Test)
225
225
  [![Deploy Status](https://github.com/lavavu/LavaVu/workflows/Deploy/badge.svg?branch=1.7.3)](https://github.com/lavavu/LavaVu/actions?query=workflow:Deploy)
226
226
  [![DOI](https://zenodo.org/badge/45163055.svg)](https://zenodo.org/badge/latestdoi/45163055)
227
- [![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/lavavu/LavaVu/1.9.7)
227
+ [![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/lavavu/LavaVu/1.9.9)
228
228
 
229
229
  A scientific visualisation tool with a python interface for fast and flexible visual analysis.
230
230
 
@@ -1,5 +1,5 @@
1
1
  lavavu/LavaVuPython.py,sha256=uTyBhkTp-Gcg468mS7EXZWxUU4TVtQ0R6D169CnMUZ0,33768
2
- lavavu/_LavaVuPython.cp313-win_amd64.pyd,sha256=qyUVL96G7sB3EFO9_g9lnEQgOKkch6Qw-Twz_VMntHo,3136000
2
+ lavavu/_LavaVuPython.cp313-win_amd64.pyd,sha256=Z_e9A31vQ1ekKOj2BVjGZvSyT-uyERPFNqgEIQliK-c,3136512
3
3
  lavavu/__init__.py,sha256=ZOkoA9N5M5swxkeLDlrc9NGFQ1PggLWW4GheseTtq8I,206
4
4
  lavavu/__main__.py,sha256=9L7Rfhb_U9Oqkop7MVJ4fi9XUnx4t2vpajOMKNNVunc,247
5
5
  lavavu/amalgamate.py,sha256=goS8OLot2q400zRMMRoksYkaNyBgRJlrpU1UxSKwLmA,601
@@ -11,7 +11,7 @@ lavavu/avformat-58.dll,sha256=PB5bD4mq62vBBY8tdagrGaYD2AQjaz3Lgc6wpp0UIr0,110940
11
11
  lavavu/avutil-56.dll,sha256=VsAhkveudbox9BBMuLEjnJ6yzoyJDoy2SzgPnMgMug0,866304
12
12
  lavavu/control.py,sha256=tucSLYj9KAD2IJoNbiOrGRSytO0xnlulB-jOnqlpOlk,68486
13
13
  lavavu/convert.py,sha256=3F79LHdsi74pvewvDuvnlYR_Zsh5mCc1QI7XZnQSMN8,36404
14
- lavavu/dict.json,sha256=1q3o7wF_siDIwmA2Sw1nh8Y1knlfmWJ64EHki21iWRU,55246
14
+ lavavu/dict.json,sha256=GoN4DlKy2x2_d9br2X4tC4B17388eqqw9FYyqqlVBLM,55480
15
15
  lavavu/font.bin,sha256=fvi5zkvmq6gh9v3jXedBVuxNJWKmHtbjECzv6eT9wb4,225360
16
16
  lavavu/glfw3.dll,sha256=zI-Qy4RDHQo4mYYgW4QLREz-WZ5l5HCXJzyksyTy0bY,83456
17
17
  lavavu/lavavu.py,sha256=2zrwiMeC8ncs84q6PHD67EFRxoCAOiQU23rHh6Tmsjs,227423
@@ -23,7 +23,7 @@ lavavu/server.py,sha256=oYVKr51a5wSedl6n25kvAE8lHEb-EX2tUUk8zDuagaM,12811
23
23
  lavavu/swresample-3.dll,sha256=hlz9EYJ8_DjhqGYcevhIDwM_9qSuZFAxK4MgeAetqE4,433664
24
24
  lavavu/swscale-5.dll,sha256=s1IjI1-IaDVYiY3P9TouwS0OQRCG620yF-kLkKMiz70,552960
25
25
  lavavu/tiff.dll,sha256=fz7vpqGN9PbzO-zgiDnOlSicYj8eJBf3lhp-sY_j6uk,646656
26
- lavavu/tracers.py,sha256=I58vJP4jNGJEE-nujz3FOTfJCZrMwEmtpczuUVVinwU,8682
26
+ lavavu/tracers.py,sha256=5pq6M_oHC0YUBYSp3pcin7JQVxSBvjsGWPA8GMlqfUo,9204
27
27
  lavavu/vutils.py,sha256=69Aygnjdz7l8-6PVYHKtOmSNFz9bGSKCv79ZI3MHY6M,5648
28
28
  lavavu/zlib.dll,sha256=4tlDhqlDl2vb-ztXfk8WIhbyfNrMRvtmygwk4s9fRQM,84992
29
29
  lavavu/zstd.dll,sha256=NJIIlGtaKrXDSlaIzizhDVEMxjuccfkSqhgy-DSUN80,491008
@@ -46,7 +46,7 @@ lavavu/html/server.js,sha256=WXuAnY6aE4h8vYs4U2sl4Xq5RjrkuDi-mIgM-x3Nkj0,7325
46
46
  lavavu/html/stats.min.js,sha256=q9kZjkwmWu8F8HV-4m2EfZRJXQBzyibceJoz-tDgB94,1970
47
47
  lavavu/html/styles.css,sha256=8JE8l7zcc0PV8CfOQpfDyhM226-Sq9eDLXvTCe-wSgw,3041
48
48
  lavavu/html/webview-template.html,sha256=E5w7pd91z0WL3244PQxDKMNZorWzoRT5G7wuBHXJc6Y,1573
49
- lavavu/html/webview.html,sha256=Ybfa1fgaEzagS2tmUfkKTaEIFIEaWmS-qtljHjeLQu4,1564
49
+ lavavu/html/webview.html,sha256=EGhXDClKoKbo6R80I_kYx_alLQKrTiyB6Xm022gPIlI,1564
50
50
  lavavu/osmesa/LavaVuPython.py,sha256=uTyBhkTp-Gcg468mS7EXZWxUU4TVtQ0R6D169CnMUZ0,33768
51
51
  lavavu/osmesa/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
52
52
  lavavu/shaders/default.frag,sha256=SHdqowe24zRNKnffZX7XilwD_I0NhVx9_rR04YJlLTE,194
@@ -58,12 +58,12 @@ lavavu/shaders/lineShader.vert,sha256=KpeKdUKStdL3_6WG9H4rCYU3oQ6qY1vWbhTaZnCb_F
58
58
  lavavu/shaders/pointShader.frag,sha256=ua2SDQMU6b9and4aM17TGqLtyEW4FhoqbQNPo41v3AY,3418
59
59
  lavavu/shaders/pointShader.vert,sha256=Mbit_gPM2jKiePIgpl2eRLiaY4brSIQ2WTDiJDMabZw,1213
60
60
  lavavu/shaders/triShader.frag,sha256=6VhNYBN5encmiE6jM-Y_titqCteTnL4AcefGprVDqxM,4754
61
- lavavu/shaders/triShader.vert,sha256=haljW2eQwyB24QWR1SURspU1z6ndskdZG7mrILfgXzo,1129
61
+ lavavu/shaders/triShader.vert,sha256=El7AdLI_XOTRRGYtQ2Wx56zNykZkz42PzpUH2n7KouM,1205
62
62
  lavavu/shaders/volumeShader.frag,sha256=6NeP_bgEl0SNOAjMxOWORhU62-TA9KyveDZ93mVtkKE,14594
63
63
  lavavu/shaders/volumeShader.vert,sha256=CroiEfEIe7pP66w14KwmKxfbTuKN6EuXYbZJvt_bfHk,83
64
- lavavu-1.9.7.dist-info/licenses/LICENSE.md,sha256=zHOh_qOPkfR76vdrTRP7J-BqPieAIWVDTl2ZP0SN6lQ,8782
65
- lavavu-1.9.7.dist-info/METADATA,sha256=VvI0E7yqS0okq8G7V7KcDDaKo4e7KEs1zg1LTrwwpRQ,18200
66
- lavavu-1.9.7.dist-info/WHEEL,sha256=nALZTncxQMc3_oaYY-7kNs-mWNehAcsCzIzH28FCq14,101
67
- lavavu-1.9.7.dist-info/entry_points.txt,sha256=LC2qXR6EMe45Cb7zGAF99R9HFrAECP6Qkp_YuG6HZB0,44
68
- lavavu-1.9.7.dist-info/top_level.txt,sha256=JptS0k1nlBumjLs_0hITr3_XUJhxqvKBXD2jGho3E3A,7
69
- lavavu-1.9.7.dist-info/RECORD,,
64
+ lavavu-1.9.9.dist-info/licenses/LICENSE.md,sha256=zHOh_qOPkfR76vdrTRP7J-BqPieAIWVDTl2ZP0SN6lQ,8782
65
+ lavavu-1.9.9.dist-info/METADATA,sha256=wzNZFFuT710oZEekVhI-F-fDnlUR41AMGdY6cr9GbXg,18200
66
+ lavavu-1.9.9.dist-info/WHEEL,sha256=qV0EIPljj1XC_vuSatRWjn02nZIz3N1t8jsZz7HBr2U,101
67
+ lavavu-1.9.9.dist-info/entry_points.txt,sha256=LC2qXR6EMe45Cb7zGAF99R9HFrAECP6Qkp_YuG6HZB0,44
68
+ lavavu-1.9.9.dist-info/top_level.txt,sha256=JptS0k1nlBumjLs_0hITr3_XUJhxqvKBXD2jGho3E3A,7
69
+ lavavu-1.9.9.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (80.4.0)
2
+ Generator: setuptools (80.9.0)
3
3
  Root-Is-Purelib: false
4
4
  Tag: cp313-cp313-win_amd64
5
5