The 100 frame limite is in absolute, not releative, vertex keys. The current version of the topix stuff I have switched to RVKs for this reason and then instructs the user how to convert to absolute vks and then edit the IPO properly. This is because there is no access right now to some stuff I’d need to do that for the user from python.
There’s some very good aspects of doing it this way, but I fear memory consumption and file sizes, memory consumption more. Also, its unclear how blender is engineered, as I haven’t looked at it, towards dealing with very large numbers of AVKs on lots of objects.
I would have thought it was better to store the mesh vertex co-ordinates for each object in a file by first running a simulation. Then, when you change frame, have the script update any mesh which has an associated “cloth animation file”. Maybe the file can just be text files inside of blender, although I don’t know how efficient this is (I guess the files are going to get huge very quickly!)
I’m thinking about using specially named Text files stored in blender to hold the parameters for the simulation. If I can force the reference count on these (press the FKEY), that should work well. Start the UI up and it looks for a file in blender, say SCENENAME.CLOTH or something and loads the parameters.
Also, my current work is splitting the simulation parameters up quite a bit. I won’t describe it now, because its at such an early stage, but if it works out, there’s going to be more parameters to play with and reloading them for the user is going to be more important then.
I don’t think its a good idea to store the results as text files in blender though. Converting from binary to ASCII will increase the data size dramatically. Vertex keys are probably lighter weight than this and directly useable.
I do think that its likely there will be an option of storing the simulation results to a file. At this time, I’m thinking 3 forms of storage, AVKs, file and on demand (no storage). How viable the on demand version is really depends on how fast the simulation is and how fast it can manage its data.
If you run the simulation itself on frame change, I can see a few problems ahead - for example, if you wanted to go from frame 95 to frame 12 for example, the script would have to do the simulation from the start again. But if you have the option, I guess it doesn’t hurt!
Yep. There are some horrible inefficiencies in the way this is implemented. Lots of data traveling from blender to python, into the C code in my module, back to python and then back to blender. And we haven’t even done any simulation work yet. Yuck!
The problem is that the only way to really fix this is to get tighter integration with blender … somehow. I’m not 100% sure what this means. Would this be an effect ? A new type of mesh ? A new constraint ? I’m not sure if it really fits in a category existing in blender now. This is very far into the future stuff though, but nice to think of how it might fit. Also, there might be better ways I can work with the data so it doesn’ t cross those boundaries as much.
I think what Youngbatcat is talking about is using the cloth mechanics as a modelling tool, in a similar way to the proportional
(deleted)
youngbatcats suggestion, it would move the other vertices according to the cloth dynamics - imagine picking up the corner of a cloth.
Yeah, I did sort of think about that application. I’m probably just blinded by details a bit though right now and also with knowing how the current stuff works. You could sort of do this already with the topix version. Just put all the vertices you don’t want to move into the ClothSim.TAGGED vertex group and run the sim on the object … as long as its a Grid mesh, :).
Actually, I think something like this could work. In pincipal its simply another form of storage, in that you’re only going to store one frame. As long as the user can specify which vertices don’t move and which ones do, it might actually work the way he was thinking.
BTW, is the resistance you mentioned below meaning friction? Friction would be great, especially if you can assign different friction co-efficients to non-cloth objects, to control how easily the cloth slips off…
Normally, resistance to me is friction. That’s why I used in my reply to youngbatcat Resistance/Stiffness. He was asking for restistance in the cloth deforming (which makes perfect sense). Because the simulation is implemented with springs, the spring stiffness is what provides that resistance to deformation.
As far as supporting friction, that’s a possibility. Not sure when, but its covered in several of the research papers I’ve been reading. I don’t believe it will make the first round of releases though, but I had some neat ideas for it when I started reading about it, :).
The big problem I see at this point with friction is the performance. The main model I’ve been studying that provides for this took one to six hours to solve this for a garment. There were solving self collision and collision with the model as well as taking into account friction. I think there were 9,000 cloth polygons and 26,000 polygons in the model.
Those are some decently high polygon counts, but not really high, and the paper is from the late 90s, but even with faster computers and fewer polygons involved, I think the solution would have to be a lot faster to be practical. So, I’m not rushing into implementing that one right now.
There are other ways to include friction though, its just a question of prioritizing features and finding good solutions.