< Back to IRCAM Forum

ModaLisp Mesh Functions desired in Mlys LUA

Hello again!

I am greatly supportive of the idea to make mlys.lua as flexible as ModaLisp. Some functions and objects are still missing. So here’s a wishlist that supports treating finite-elements in Lua.

I have also attached a Lisp example that show what some of the missing objects are capable of - in particular the (make-mesh 'quadrilateral …) and the rarely used but really cool noise controller (band-limited impulse generator great for force connections). Have fun! Hans Peter

3D Arches v1.lisp (3.9 KB)

Modalisp Mesh functions desired in Mlys LUA

These mesh creation tools are VERY much desired!

  • (make-mesh ‘beam …) is it the same as (make-mesh ‘edge …) ?
  • (make-mesh ‘quadrilateral …) this one is especially usefull for creating all sorts of curved and even non-symmetric surfaces or objects.

It would also be very good if one could convert easily between nodes and xyz coordinates.
These functions exists in ModaLisp, so they should be fairly easy to implement in Lua?

  • (coordinates->node mesh xyz-vector-or-list)
  • (node->coordinates mesh node-number)

or alternatively they could be implemented as

  • (get-info ‘node mesh xyz-coords)
  • (get-info ‘xyz mesh node-index)

Conversely one would of course also like to be able to modify existing nodes or xyz coordinates

  • (set-info ‘node mesh xyz-coords node-index)
  • (set-info ‘xyz mesh node-index xyz-coords)

This would open a whole bunch of creative ideas for deforming existing meshes!

Only a handfull of get-info keywords works on fem-objects, such as

  • (get-info ‘num-modes fem-object)
  • (get-info ‘mode-frequency fem-object mode-index)
  • (get-info ‘mode-loss fem-object mode-index)
  • (get-info ‘mode-amplitude fem-object mode-index)
    Even if mode-amplitude seem to apply I am not sure if it has any effect.

Getting physical parameters from fem-object does not work, for instance

  • (get-info ‘physical ticked-physical-parameter fem-object)

Obviously the opposite does also not work

  • (set-info ‘physical ticked-physical-parameter value fem-object)

Would be nice of they could be made to work in Lua so fem-objects could be easily retuned.

It would also be nice to be able to store Medit animations as movies.
There is an undocumented function called (make-movie …) but what are the arguments?
Surely a fem-object and a filename plus maybe framerate and … ? Clarification is needed!

  • (make-movie <&args>)

Eventually it would be nice to have a simple shortcut in Medit itself to do the job.

1 Like

Duly noted!
It should not be too hard to add to the LUA layer.
Best,
Robert