Cloth Simulation

Cloth Simulation

Cloth Simulation

Cloth Simulation

Organization:

UC San Diego

Organization:

UC San Diego

Organization:

UC San Diego

Duration:

Jan 2023 - Mar 2023

Duration:

Jan 2023 - Mar 2023

Duration:

Jan 2023 - Mar 2023

Mass-Spring System
Physics Engine
Rendering Engine
Texture
Interactive Control
C++
OpenGL
ImGui
Cloth Simulation

Video Demo

Overview

  • Simulated a piece of cloth made from particles, spring-dampers (structural, shearing, bending), and triangular surfaces; rendered the scene with adjustable lights and customized textures

  • Realized effects of gravity, spring forces, aerodynamic force on surfaces, and collisions with ground and sphere

  • Developed a GUI allowing parameter adjustment, camera movement, cloth movement, changing cloth hang mode

Feature Status

The cloth simulation module uses a Mass-Spring System to simulate a piece of cloth. It currently supports the following features:

  1. General 4. pause simulation

  2. Cloth control & physics attributes

    1. move cloth

      1. translate +x (right): D

      2. translate -x (left): A

      3. translate +y (up): W

      4. translate -y (down): S

      5. translate -z (inward): Q

      6. translate +z (outward): E

      7. rotate clockwise: C

      8. rotate counterclockwise: Z

    2. stiffness: structural, shear, bending

    3. damping: structural, shear, bending

    4. change pin mode & drop cloth:

      1. Pin Upper Corner

      2. Pin Upper Edge

      3. Drop Cloth

    5. Friction/elasticity with ground & sphere

  3. Wind control

    1. wind’s howling/calm

    2. move wind spawn

      1. Up: W

      2. Down: S

      3. Left: A

      4. Right: D

      5. Inward: Q

      6. Outward: E

    3. wind velocity (value)

  4. Light control

    1. move light:

      1. Up: W

      2. Down: S

      3. Left: A

      4. Right: D

      5. Inward: Q

      6. Outward: E

    2. change light color with hue wheel

  5. Move camera

    1. Up: W

    2. Down: S

    3. Left: A

    4. Right: D

    5. Inward: Q

    6. Outward: E

  6. User grab

    1. hold mouse left button to drag the cloth

    2. quit grab mode either by right click mouse button or unclick the checkbox

Milestones to be achieved in the coming months:

  • try optimization methods for both realistic considerations and performance

Architecture Design


Key Algorithms

Mass-Spring System


Blinn-Phong Illumination Model


Tech Stack

Resources

Mass-Spring System
Physics Engine
Rendering Engine
Texture
Interactive Control
C++
OpenGL
ImGui
Cloth Simulation

Video Demo

Overview

  • Simulated a piece of cloth made from particles, spring-dampers (structural, shearing, bending), and triangular surfaces; rendered the scene with adjustable lights and customized textures

  • Realized effects of gravity, spring forces, aerodynamic force on surfaces, and collisions with ground and sphere

  • Developed a GUI allowing parameter adjustment, camera movement, cloth movement, changing cloth hang mode

Feature Status

The cloth simulation module uses a Mass-Spring System to simulate a piece of cloth. It currently supports the following features:

  1. General 4. pause simulation

  2. Cloth control & physics attributes

    1. move cloth

      1. translate +x (right): D

      2. translate -x (left): A

      3. translate +y (up): W

      4. translate -y (down): S

      5. translate -z (inward): Q

      6. translate +z (outward): E

      7. rotate clockwise: C

      8. rotate counterclockwise: Z

    2. stiffness: structural, shear, bending

    3. damping: structural, shear, bending

    4. change pin mode & drop cloth:

      1. Pin Upper Corner

      2. Pin Upper Edge

      3. Drop Cloth

    5. Friction/elasticity with ground & sphere

  3. Wind control

    1. wind’s howling/calm

    2. move wind spawn

      1. Up: W

      2. Down: S

      3. Left: A

      4. Right: D

      5. Inward: Q

      6. Outward: E

    3. wind velocity (value)

  4. Light control

    1. move light:

      1. Up: W

      2. Down: S

      3. Left: A

      4. Right: D

      5. Inward: Q

      6. Outward: E

    2. change light color with hue wheel

  5. Move camera

    1. Up: W

    2. Down: S

    3. Left: A

    4. Right: D

    5. Inward: Q

    6. Outward: E

  6. User grab

    1. hold mouse left button to drag the cloth

    2. quit grab mode either by right click mouse button or unclick the checkbox

Milestones to be achieved in the coming months:

  • try optimization methods for both realistic considerations and performance

Architecture Design


Key Algorithms

Mass-Spring System


Blinn-Phong Illumination Model


Tech Stack

Resources

Mass-Spring System
Physics Engine
Rendering Engine
Texture
Interactive Control
C++
OpenGL
ImGui
Cloth Simulation

Video Demo

Overview

  • Simulated a piece of cloth made from particles, spring-dampers (structural, shearing, bending), and triangular surfaces; rendered the scene with adjustable lights and customized textures

  • Realized effects of gravity, spring forces, aerodynamic force on surfaces, and collisions with ground and sphere

  • Developed a GUI allowing parameter adjustment, camera movement, cloth movement, changing cloth hang mode

Feature Status

The cloth simulation module uses a Mass-Spring System to simulate a piece of cloth. It currently supports the following features:

  1. General 4. pause simulation

  2. Cloth control & physics attributes

    1. move cloth

      1. translate +x (right): D

      2. translate -x (left): A

      3. translate +y (up): W

      4. translate -y (down): S

      5. translate -z (inward): Q

      6. translate +z (outward): E

      7. rotate clockwise: C

      8. rotate counterclockwise: Z

    2. stiffness: structural, shear, bending

    3. damping: structural, shear, bending

    4. change pin mode & drop cloth:

      1. Pin Upper Corner

      2. Pin Upper Edge

      3. Drop Cloth

    5. Friction/elasticity with ground & sphere

  3. Wind control

    1. wind’s howling/calm

    2. move wind spawn

      1. Up: W

      2. Down: S

      3. Left: A

      4. Right: D

      5. Inward: Q

      6. Outward: E

    3. wind velocity (value)

  4. Light control

    1. move light:

      1. Up: W

      2. Down: S

      3. Left: A

      4. Right: D

      5. Inward: Q

      6. Outward: E

    2. change light color with hue wheel

  5. Move camera

    1. Up: W

    2. Down: S

    3. Left: A

    4. Right: D

    5. Inward: Q

    6. Outward: E

  6. User grab

    1. hold mouse left button to drag the cloth

    2. quit grab mode either by right click mouse button or unclick the checkbox

Milestones to be achieved in the coming months:

  • try optimization methods for both realistic considerations and performance

Architecture Design


Key Algorithms

Mass-Spring System


Blinn-Phong Illumination Model


Tech Stack

Resources

Mass-Spring System
Physics Engine
Rendering Engine
Texture
Interactive Control
C++
OpenGL
ImGui
Cloth Simulation

Video Demo

Overview

  • Simulated a piece of cloth made from particles, spring-dampers (structural, shearing, bending), and triangular surfaces; rendered the scene with adjustable lights and customized textures

  • Realized effects of gravity, spring forces, aerodynamic force on surfaces, and collisions with ground and sphere

  • Developed a GUI allowing parameter adjustment, camera movement, cloth movement, changing cloth hang mode

Feature Status

The cloth simulation module uses a Mass-Spring System to simulate a piece of cloth. It currently supports the following features:

  1. General 4. pause simulation

  2. Cloth control & physics attributes

    1. move cloth

      1. translate +x (right): D

      2. translate -x (left): A

      3. translate +y (up): W

      4. translate -y (down): S

      5. translate -z (inward): Q

      6. translate +z (outward): E

      7. rotate clockwise: C

      8. rotate counterclockwise: Z

    2. stiffness: structural, shear, bending

    3. damping: structural, shear, bending

    4. change pin mode & drop cloth:

      1. Pin Upper Corner

      2. Pin Upper Edge

      3. Drop Cloth

    5. Friction/elasticity with ground & sphere

  3. Wind control

    1. wind’s howling/calm

    2. move wind spawn

      1. Up: W

      2. Down: S

      3. Left: A

      4. Right: D

      5. Inward: Q

      6. Outward: E

    3. wind velocity (value)

  4. Light control

    1. move light:

      1. Up: W

      2. Down: S

      3. Left: A

      4. Right: D

      5. Inward: Q

      6. Outward: E

    2. change light color with hue wheel

  5. Move camera

    1. Up: W

    2. Down: S

    3. Left: A

    4. Right: D

    5. Inward: Q

    6. Outward: E

  6. User grab

    1. hold mouse left button to drag the cloth

    2. quit grab mode either by right click mouse button or unclick the checkbox

Milestones to be achieved in the coming months:

  • try optimization methods for both realistic considerations and performance

Architecture Design


Key Algorithms

Mass-Spring System


Blinn-Phong Illumination Model


Tech Stack

Resources

Let's Talk

Let's Talk

Let's Talk

Let's Talk