1
$\begingroup$

I'm interested in creating an animation in Blender that involves an intricate and roughly-scientifically-accurate animation, that appears to be beyond the ability of Blender to perform easily and accurately. This animation will be mixed with other animations in the same scene that will be done using standard keyframing/rigging.

As a result, I'd like to write a program that generates mesh data for each frame and outputs it in some format (likely X,Y,Z, and a few texture parameters for cycles, perhaps U/V for a UV map). Is there a way to easily import this bulk mesh data into Blender so that I can obtain an animated object, without importing a separate mesh per frame?

$\endgroup$
1
  • $\begingroup$ This sounds very much like having a shapekey for each frame. This somewhat related answer mentions the point cache. And this one .. one could argue the softbody solver "involves an intricate and roughly-scientifically-accurate animation" $\endgroup$
    – batFINGER
    Dec 16, 2017 at 6:27

2 Answers 2

2
$\begingroup$

I would suggest writing to an Alembic file. Blender has nice support for it, and it's a quite compact file format that's fast to read. It also supports things like changes in mesh topology, vertex colours, and point clouds.

$\endgroup$
0
$\begingroup$

It would make more sense to write a file that allows morph controllers for your model.

COLLADA allows this, and is an open format, so you're free to use it.
https://en.wikipedia.org/wiki/COLLADA

I would suggest using the Python version http://pycollada.github.io/
As that's in keeping with the way Blender scripts are written, to keep things simple.

$\endgroup$
2
  • $\begingroup$ Does this assume any sort of morph behavior? (i.e. can I set up a morph that simply takes identity transformation of my input data and applies it to the mesh, frame by frame, or am I forced to deform an existing mesh in an indirect manner?) Alternatively, can a COLLADA file simply contain an entity that has a different (independent) mesh each frame? $\endgroup$
    – nanofarad
    Dec 16, 2017 at 2:35
  • $\begingroup$ You'd generate object data, then use morph targets to move it. On the other hand, if you want to use a separate object-per-frame, you can. Nobody's stopping ya, it'd just take a ton of memory. Might have to write a script that shows the object at its desired frame, and hides all the others. $\endgroup$ Dec 16, 2017 at 3:17

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .