| 175 | float CPHShell::getDensity() { return getMass() / getVolume(); } |
| 176 | |
| 177 | void CPHShell::PhDataUpdate(dReal step) |
| 178 | { |
| 179 | ELEMENT_I i = elements.begin(), e = elements.end(); |
| 180 | bool disable = true; |
| 181 | for (; e != i; ++i) |
| 182 | { |
| 183 | (*i)->PhDataUpdate(step); |
| 184 | dBodyID body = (*i)->get_body(); |
| 185 | if (body && disable && dBodyIsEnabled(body)) |
| 186 | disable = false; |
| 187 | } |
| 188 | if (disable) |
| 189 | { |
| 190 | DisableObject(); |
| 191 | CPHObject::put_in_recently_deactivated(); |
| 192 | } |
| 193 | else |
| 194 | ReanableObject(); |
| 195 | |
| 196 | if (PhOutOfBoundaries(cast_fv(dBodyGetPosition((*elements.begin())->get_body())))) |
| 197 | Disable(); |
| 198 | } |
| 199 | |
| 200 | void CPHShell::PhTune(dReal step) |
| 201 | { |
nothing calls this directly
no test coverage detected