MCPcopy Create free account
hub / github.com/OGSR/OGSR-Engine / dWorldCreate

Function dWorldCreate

3rd_party/Src/ode/ode/src/ode.cpp:1203–1233  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1201// world
1202
1203dxWorld * dWorldCreate()
1204{
1205 dxWorld *w = new dxWorld;
1206 w->firstbody = 0;
1207 w->firstjoint = 0;
1208 w->nb = 0;
1209 w->nj = 0;
1210 dSetZero (w->gravity,4);
1211 w->global_erp = REAL(0.2);
1212#if defined(dSINGLE)
1213 w->global_cfm = 1e-5f;
1214#elif defined(dDOUBLE)
1215 w->global_cfm = 1e-10;
1216#else
1217 #error dSINGLE or dDOUBLE must be defined
1218#endif
1219
1220 w->adis.linear_threshold = REAL(0.001)*REAL(0.001); // (magnitude squared)
1221 w->adis.angular_threshold = REAL(0.001)*REAL(0.001); // (magnitude squared)
1222 w->adis.idle_steps = 10;
1223 w->adis.idle_time = 0;
1224 w->adis_flag = 0;
1225
1226 w->qs.num_iterations = 20; // 20 is Default
1227 w->qs.w = REAL(1.1); // 1.3 is Russ Default, 1.05
1228
1229 w->contactp.max_vel = dInfinity;
1230 w->contactp.min_depth = 0.001f; // should be 0
1231
1232 return w;
1233}
1234
1235
1236void dWorldDestroy (dxWorld *w)

Callers 2

dTestDataStructuresFunction · 0.85
dWorldMethod · 0.85

Calls 1

dSetZeroFunction · 0.85

Tested by

no test coverage detected