refactor cloth

This commit is contained in:
Irlan
2018-05-24 05:35:16 -03:00
parent 47a2c12160
commit 4ae3b7cc79
17 changed files with 1993 additions and 2635 deletions

View File

@ -19,7 +19,7 @@
#ifndef TABLE_CLOTH_H
#define TABLE_CLOTH_H
class TableCloth : public SpringClothTest
class TableCloth : public ClothTest
{
public:
TableCloth()
@ -48,14 +48,12 @@ public:
m_gridClothMesh.sewingLineCount = 0;
m_gridClothMesh.sewingLines = nullptr;
b3SpringClothDef def;
def.allocator = &m_clothAllocator;
b3ClothDef def;
def.mesh = &m_gridClothMesh;
def.density = 0.2f;
def.ks = 10000.0f;
def.kd = 0.0f;
def.r = 0.05f;
def.gravity.Set(0.0f, -10.0f, 0.0f);
m_cloth.Initialize(def);