Here's the actual curtain set up and model used in the "Change Your Pants - episode 1" project ready to simulate.
UPDATED: Now includes a text document with these instructions
Click to view attachment
UPDATE: The Curtain Rod model used in the animation. This model is the right size to fit two curtains fully closed that overlap slightly. There are two rods connected on each side. One curtain for each "rod" with some spacing between them. It's got odd "knobs" on the sides that were to connect it to other piping and struts. Includes a material which isn't that exciting.
Click to view attachment
A few notes:
Decals and the two separate curtain models
There are two curtain models. They are IDENTICAL but are still separate models. The reason for this had to do with a decal rendering issue. Originally I had ONE model in the chor twice. The right curtain was scaled -100 on the X axis. I then used a decal sequence to set the decal to a reversed alternate image to create the whole logo across both curtains using just one model. For some reason this didn't render correctly. At the last minute I had to just save out a separate model with a different decal image. The right curtain model in the chor is still scaled -100 on the x axis because it is EXACTLY the same as the left except for the decal. I just replaced the original duplicate with this new "right" curtain model so I could render my project.
If you would like to replace the decal provided (AM logo) you can edit the images provided and replace it or just add another image to the decal and eliminate the one that is there. Keep in mind the "reversed" image must be "reversed" and "offset" the same way so that it runs across both curtains. There is an offset or overlap of the two images so the curtains can "overlap" slightly when opening and closing.
Opening and closing the curtains
To open and close the curtain make sure the pose is turned on. Translate the "root" bone along the x axis. Move it in the direction you want the curtain to go.
Additionally, translation doesn't open it "all the way". If you need to open further use negative X scaling on the root bone. This will squeeze it "tighter" as it opens. Don't go too far or you may get problems with the cloth simulation and intersections.
Do not move any bones but the root bone. The root bone only needs to move along the x axis. I just the use the arrow keys. I can't actually remember if moving it in other axes has an adverse effect.
Pre-roll and the "bouncing" curtain
In the project I didn't do any "pre roll", so the curtain will "bounce" a little. To add a pre roll just select the choreography. Expand the Plugin Properties|simcloth triangle. Turn the "use chor time range" off and set the start to a negative frame and the end to where ever you need it. Now when you simulate it will key the curtain before frame zero which should eliminate some of the "bounce". You may need to tweak this.
ALERT! Dynamics force setting
The dynamics|force setting in the chor has a -425 Y setting. This makes the cloth behave more... clothy with my curtain. It worked for my project. There may be better settings for cloth but this worked well for me so I went with it. Keep in mind this setting will effect anything that uses the dynamics | force property of the choreography.
--------------------------
Update: Wireframe animation and a description of the rig
Click to view attachment
I wrote this as much for myself as for others. This is a detailed description of what the heck is going on. If I ever get hit by a bus and lose my memory I should be able to understand how I made this thing. YOU HAVE NO OBLIGATION TO READ THIS.
This short wireframe animation of a scaled down version of the curtain rig shows a little bit how it works.
The horizontal bones have a translate constraint to the "aim" bone and a horizontal translate limit. The aim bone is not seen in the video. It's position is irrelevant and it never moves. The root bone is not used in any of the constraints either. It's only purpose is to move all of the other bones forcing them to collapse based on the limits and the constraint to the aim bone.
The whole system relies on a precise grid in 10cm units. Each translation constraint is based on that grid and the number of bones or width of the curtain. The curtain grid is based on a with spacing of 10cm. The vertical spacing is irrelevant. I "stretched" it to make up for computer limitations. I was able to make the curtain taller without increasing the complexity of the simulation.
There are 32 units across and 17 horizontal bones. Each horizontal bone controls every other vertical spline. Each bone translates to the stationary "aim" bone with an offset equal to its position in the "grid" of 17 bones. Each bone but has a translation limit based on the 10cm it must travel to "reach" the next bone. The bone closest to 0 on the X axis has a translation limit of 160 because it moves "last". The farthest bone out has a limit of 0 because it moves first. The "width" of the curtain is 320cm. Each curtain section is 20cm, two "sides" and the center spline that moves back as it folds.
What happens when the parent or "root" bone is translated is that each bone stays put or seems to be not moving because it is constrained to the aim bone which is outside of the root bone hierarchy. The horizontal curtain bones can only "not move" when the root bone is HIGHER than the constraint limit. When the root bone is moved below that constraint value the bone follows along in the negative X direction because the MIN value for the limit is -1000. When the last bone is reached and the curtain is fully open, each limit has a -1000 on the x so the whole rig can continue to move past the open position. It can move as far open (to the left) on the X up to -1000, but when closing it "stops" at the point on the grid where it is in the final closed position.
The "moving" of these bones is an illusion. When the bones AREN'T moving they are constrained to the aim bone and actually "move" in the opposite direction but in a way that appears to be stationary. The root bone is higher than the limit and so the limit and constraint to the aim bone is in full effect. (that is why the exact 10cm values is critical). When those bones are moving they really aren't moving, they are being dragged along by the root bone, the parent. Just like any child bone would "move" with a parent bone. The translation limit only stops movement of the bone at the full closed position. (The parent bone translation actually seems to "override" the constraint to the aim bone. But without that constraint the system would not work. That DOES confuse me.)
For example: Bone 21 has a 100cm X translation max value. That is the position when the curtain is closed. It can't go beyond that position to the right. There are 10 bones "in front" of it that have lower values by 10cm (90, 80,70 ect) and will move first. So the root bone slides back, to the left until finally it's position reaches bone 21's 100cm limit on the constraint to the aim bone. That constraint has kept it "stationary". The root bone was HIGHER than that value. Now it is LOWER than 100cm and bone 21 must follow along with the root bone. There is no constraint keeping it in place.
Folding: Those "other" vertical splines and bones
Each of the horizontal bones has one child bone that is oriented along the Z axis. These bones control the "collapsing" of the inner folds and each have an aim at constraint to the PREVIOUS horizontal bone in the chain. The location of this bone is critical to create the pseudo "translation" of the vertical spline back. By adjusting the "pivot" this causes the spline to move "straight back" (close enough) as this bone continues to aim at it's target. Since it is a child of the horizontal bone eventually it "stops" and travels along happily with it's parent bone.
This "seems" complex but only in "execution" (applying the constraints). In reality it's quite a simple set up. It's just a tiny bit tedious. The current "width" of this curtain is the limit I could go with a cloth simulation. Beyond this grid size the cloth simulations were taking a very long time on my computer which is really nice but not a power house. This is a limitation with my computer.
-vern
