3
* $Id: bullet.c 17028 2008-10-11 20:52:43Z erwin $
5
* ***** BEGIN GPL LICENSE BLOCK *****
7
* This program is free software; you can redistribute it and/or
8
* modify it under the terms of the GNU General Public License
9
* as published by the Free Software Foundation; either version 2
10
* of the License, or (at your option) any later version.
12
* This program is distributed in the hope that it will be useful,
13
* but WITHOUT ANY WARRANTY; without even the implied warranty of
14
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
* GNU General Public License for more details.
17
* You should have received a copy of the GNU General Public License
18
* along with this program; if not, write to the Free Software Foundation,
19
* Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
21
* The Original Code is Copyright (C) Blender Foundation
22
* All rights reserved.
24
* The Original Code is: all of this file.
26
* Contributor(s): none yet.
28
* ***** END GPL LICENSE BLOCK *****
31
#include "MEM_guardedalloc.h"
34
#include "DNA_object_force.h" /* here is the softbody struct */
36
#include "BKE_bullet.h"
39
/* ************ Object level, exported functions *************** */
41
/* allocates and initializes general main data */
42
BulletSoftBody *bsbNew(void)
46
bsb= MEM_callocN(sizeof(BulletSoftBody), "bulletsoftbody");
48
bsb->flag = OB_BSB_BENDING_CONSTRAINTS | OB_BSB_SHAPE_MATCHING | OB_BSB_AERO_VPOINT;
62
bsb->kSR_SPLT_CL = 0.5f;
64
bsb->kSK_SPLT_CL = 0.5f;
65
bsb->kSS_SPLT_CL = 0.5f;
82
bsb->collisionflags = 0;
83
//bsb->collisionflags = OB_BSB_COL_CL_RS + OB_BSB_COL_CL_SS;
84
bsb->numclusteriterations = 64;
90
void bsbFree(BulletSoftBody *bsb)
92
/* no internal data yet */