glotzerlab / plato

Efficient visualization of particle data supporting several rendering engines.
https://plato-draw.readthedocs.io/
BSD 3-Clause "New" or "Revised" License
12 stars 4 forks source link

Made number of vertices configurable for pythreejs. #25

Closed bdice closed 5 years ago

bdice commented 5 years ago

@klarh I'm not sure if I'm understanding how to use property defaults appropriately, but this seems to work. Resolves #24.

klarh commented 5 years ago

One tricky aspect of this is that the vertex count can't be changed dynamically at the moment (after a primitive has been added to a scene) because pythreejs won't let the size of the array change or so. Just something to keep in mind later, and a problem we can deal with once we run into it in practice.

bdice commented 5 years ago

@klarh Good to know. The attribute could be read-only (no setter) if it becomes a problem for anyone.