Home Technical Talk

Cloth Simulation...

polycounter lvl 9
Offline / Send Message
Ladytron polycounter lvl 9
Hi,

I'm having trouble picking the correct settings for cloth simulation. I use Blender 3D.

I know the basics of making cloth simulations, but I'm having a hard time getting the cloth to lay right, and also for some reason it sometimes falls off the collision object.


I'm making a tablecloth, I want it to lay evenly on all sides, but sometimes, it's longer on one side.

I made sure the mesh was centered on the collision object, so it would fall evenly.


Here's how I want it to lay:

simple_img_1.jpg


Crochet-Vinyl-Tablecloth-00584569613.jpg


When I play the animation, the cloth moves way to much, and can't get an frame where the cloth looks even on all sides. I just want it to hang straight, but by time the animation is finish playing, the cloth still isn't settled. (If that makes sense)

Is there a setting that I can use to get the look I want? If so, please give me a step by step.


Thank you.

Replies

  • Olli.
    Options
    Offline / Send Message
    Olli. polycounter lvl 8
    you just need to tweak the physics settings. There should be a damping value or something similar that you can use to slow down the motion and make it settle faster.
  • Mark Dygert
    Options
    Offline / Send Message
    If you where using max I could tell you exactly what settings to flip to fix those problems but I've never used blender to sim cloth before so... I can't offer much help.

    Max has cloth properties that you can tweak making it stiffer or more elastic, you can also adjust the properties of the surfaces so its more slippery like silk or heavy stiff and abrasive like canvas.

    In max you can also freeze the sim at any point and use live drag mode, where you can grab the cloth at any face and drag it around and it will sim as you move it and as soon as you let go it freezes. It's perfect for fixing and fine tuning.

    Hopefully blender has some tools like that...

    Another thing that you can do in max that you might be able to do in blender, is to use two splines:
    - One irregular spline shape for the bottom of the cloth (spline painting is great for this),
    - One round spline shape for the top of the table (derived from a cylinder edge "Create Shape" instead of using a spline circle).
    - Convert them to poly, in boarder mode use the bridge tool to fill in the gap, give it some segments, twist it and taper it a bit and give it some form.

    TableCloth.gif
    The beauty of this is that you can go back down the stack tweak the irregular spline to tweak the entire mesh, provided you set the number of interpolations in the spline to 0, otherwise it could add or remove verts causing the geometry in edit poly to change, but that doesn't happen if you set it to 0.

    Then you can apply cloth, soft select preserve the verts on the top so the cloth sim only runs on the bottom (and not the round table top) to give it a hint of reality and gravity. Then use live drag to tweak it how you like.
  • Ladytron
    Options
    Offline / Send Message
    Ladytron polycounter lvl 9
    Thank you!!


    I was looking at Blender Physics > Cloth, I don't see the settings you mentioned.


    Here's photo of the interface:

    Physics.png



    Cloth.png
  • Ladytron
    Options
    Offline / Send Message
    Ladytron polycounter lvl 9
    Olli. wrote: »
    you just need to tweak the physics settings. There should be a damping value or something similar that you can use to slow down the motion and make it settle faster.

    I see the Damping, but not sure what I'm suppose to do there... :(
  • Ladytron
    Options
    Offline / Send Message
    Ladytron polycounter lvl 9
    I figured it out! Thank you guys!


    Here's how it turned out:

    tableclothtest.png

    tableclothtest2.png

    The only thing I don't like is the corners are bulky. I thought if I subdivide it more,the bulky corners would go away, but no. So now I have to figure out how to make the corners lay smoother.

    Anyone know a way?
  • uncle
    Options
    Offline / Send Message
    Subdivide it. It simply won't deform well without more polygons.
  • Snader
    Options
    Offline / Send Message
    Snader polycounter lvl 15
    Have you paid attention to real-world scale? Right now it looks like regular cloth laying on a dollhouse table

    If your proportions are accurate, you probably need to change cloth thickness and/or stiffness.




    Uncle:
    uncle wrote: »
    Subdivide it. It simply won't deform well without more polygons.
    Ladytron wrote: »
    I thought if I subdivide it more,the bulky corners would go away, but no.
  • metalliandy
    Options
    Offline / Send Message
    metalliandy interpolator
    uncle is correct, you need to subdivde the cloth object by much more. For a reasonable cloth sim on a plane you want 8-10k quads minimum and from the shading artefacts on your cloth it looks like you have much less.
    If you are finding that it is taking too long to calculate, then you can get away with adding a subsurf modifier after the cloth modifier but you still need a decent amount of quads in the base mesh otherwise you won't get a good result, simply because there isn't enough geometry to support the deformation of the cloth and the calculation is done before any subsurf modifier is added.

    In the picture below is a plane that has 7744k quads and a subsurf modifier at lvl 3 added after the cloth modifier.
    I used the default setting for the Silk preset and Collision quality at 2 and self collision at level 1 .

    Cloth_sim_results.jpg

    Cloth_sim_settings.jpg

    Cloth_sim_modifier_settings.jpg
  • Ladytron
    Options
    Offline / Send Message
    Ladytron polycounter lvl 9
    *hugs for all of you* Thank you all soo much!!

    *hugs for metalliandy* Thank you! I understand much better now! :thumbup:

    I see what you mean. I forgot to mention one important part though... I'm creating this for a game called Sims 3. I can't have the poly-count too high.

    With that being said, I do love how your cloth looks, and that's how I want mines to look, but it's way too high for the game!


    I guess I should leave it as is. However, I'm going to create a tablecloth and use your settings, so I can add it to my (beginner) art gallery! (lol)

    I still have a lot more to learn about meshing/3d modeling!

    I'll probably have more question about this project, so I will be coming back. :poly121:
  • metalliandy
    Options
    Offline / Send Message
    metalliandy interpolator
    No problem, man :)

    You would get a better results by running the cloth simulation with a high polygon count and then applying the cloth modifier and decimate/reduce the polygon count to something more reasonable, rather than running it on a low polygon count.
  • Ladytron
    Options
    Offline / Send Message
    Ladytron polycounter lvl 9
    No problem, man :)

    You would get a better results by running the cloth simulation with a high polygon count and then applying the cloth modifier and decimate/reduce the polygon count to something more reasonable, rather than running it on a low polygon count.

    (lol I hate when guys call females "man" :poly117: lol )

    Okay! I will do that!


    Quick question: How do I apply the cloth modifier? Where is that located?

    And, how do I reduce the poly-count? I know there's a way, but forgot where to go to do it. Also, doesn't this help get rid of any extra vertices/faces?
  • Ladytron
    Options
    Offline / Send Message
    Ladytron polycounter lvl 9
    I can't find the cloth modifier! :(


    So the cloth modifier is the reducer?
  • metalliandy
    Options
    Offline / Send Message
    metalliandy interpolator
    Ladytron wrote: »
    (lol I hate when guys call females "man" :poly117: lol )
    Oops sorry, force of habit.

    The cloth modifier is in the modifier panel on the cloth object. Just apply that once your simulation is completed and then either reduce the poly count manually or use the decimate modifier. :)
  • Ladytron
    Options
    Offline / Send Message
    Ladytron polycounter lvl 9
    I had an idea, but then I was wondering, will the cloth modifier do this?

    After I've create the sim, and have a solid mesh, I can delete the flat verts/faces on top of the surface , and replace it. Because I don't need that many polygons on the surface, since it's just flat across. I'll just keep the edges.


    Is that what the cloth modifier will do? Or would I have to do it manually?
  • Ladytron
    Options
    Offline / Send Message
    Ladytron polycounter lvl 9
    I had walked away for a few minutes, and forgot to post my reply, so I didn't see your post until now, metalliandy.


    Okay I still don't quite understand where it's located...
  • metalliandy
    Options
    Offline / Send Message
    metalliandy interpolator
    Once you add a cloth simulation, a modifier will appear at the top of the modifier stack. Once the cloth simulation is finished, just hit apply in object mode and it will convert your simulation into a mesh which is editable.

    The cloth modifier is linked to the cloth simulation and it's only purpose is to convert the simulation into a mesh.
    The top modifier in the picture below is he cloth modifier. Just hit the apply button :)

    Cloth_sim_modifier_settings.jpg

    To reduce the polygon count, you must do it manually or use the decimate modifier.
  • Ladytron
    Options
    Offline / Send Message
    Ladytron polycounter lvl 9
    I need to know how many times you subdivide? How many clicks? (4, 5?)
  • Ladytron
    Options
    Offline / Send Message
    Ladytron polycounter lvl 9
    Okay, I see! I'm working on it now, actually! I'm using your settings, just need to know how many times you subdivide?
  • Ladytron
    Options
    Offline / Send Message
    Ladytron polycounter lvl 9
    I use your settings metal, and the cloth fell off the table. LOL


    I didn't tick self-collision though, Do I have to click that? I didn't, because I thought that meant I didn't need a collision object...
  • Lord McMutton
    Options
    Offline / Send Message
    Lord McMutton polycounter lvl 17
    If you're having issues with the cloth moving, use the Pinning option on the cloth settings, below Presets and Damping.

    Go into Edit mode on the object and select, like, a single vertex in the center. Then go into the Object Data tab (The one with the triangle symbol) and in Vertex Groups, create a new one and name it whatever, and then crank up the Weight to 1 and press Assign. Then you select whatever that vertex group was called in the Pinning part of the cloth settings.
  • Ladytron
    Options
    Offline / Send Message
    Ladytron polycounter lvl 9
    If you're having issues with the cloth moving, use the Pinning option on the cloth settings, below Presets and Damping.

    Go into Edit mode on the object and select, like, a single vertex in the center. Then go into the Object Data tab (The one with the triangle symbol) and in Vertex Groups, create a new one and name it whatever, and then crank up the Weight to 1 and press Assign. Then you select whatever that vertex group was called in the Pinning part of the cloth settings.


    Thank you very much Marshal! :)

    I've did everything you said, and I'm now waiting for the bake to finish. We'll see how everything turns out!
  • Ladytron
    Options
    Offline / Send Message
    Ladytron polycounter lvl 9
    I did the pin, but when I played the animation, the part that was pinned stayed up in the air, while the rest of the cloth fell to the table. It looked like a tent.
  • Lord McMutton
    Options
    Offline / Send Message
    Lord McMutton polycounter lvl 17
    If it's just on that flat surface, you should be able to put it right on top before running the sim.
  • Ladytron
    Options
    Offline / Send Message
    Ladytron polycounter lvl 9
    If it's just on that flat surface, you should be able to put it right on top before running the sim.

    Thank you Marshal! That's exactly what I did, and it turned out just fine!:thumbup:
Sign In or Register to comment.