ABRG-Models / morphologica

A library of supporting code for numerical modelling (JSON config, HDF5 data, Modern OpenGL visualization)
https://abrg-models.github.io/morphologica/
Apache License 2.0
255 stars 29 forks source link

Ctrl-z doesn't output correct Scenetrans setup code #203

Closed sebjameswml closed 2 months ago

sebjameswml commented 4 months ago

Especially 0 values come out as 0f rather than 0.0f.

Solution might be to output float{val}

sebjameswml commented 4 months ago

Example:

Scenetrans setup code:
    v.setSceneTrans (morph::vec<float,3>({0f, 0f, -3.5f}));
scene rotation is Quaternion[wxyz]=(1,0,0,0)
Writing scene trans/rotation into /tmp/Visual.json... Success.
sebjameswml commented 2 months ago

Fixed with 64b7cc8