| 201 | // dxGeom |
| 202 | |
| 203 | dxGeom::dxGeom (dSpaceID _space, int is_placeable) |
| 204 | { |
| 205 | initColliders(); |
| 206 | |
| 207 | // setup body vars. invalid type of -1 must be changed by the constructor. |
| 208 | type = -1; |
| 209 | gflags = GEOM_DIRTY | GEOM_AABB_BAD | GEOM_ENABLED; |
| 210 | if (is_placeable) gflags |= GEOM_PLACEABLE; |
| 211 | data = 0; |
| 212 | body = 0; |
| 213 | body_next = 0; |
| 214 | if (is_placeable) { |
| 215 | dxPosR *pr = (dxPosR*) dAlloc (sizeof(dxPosR)); |
| 216 | pos = pr->pos; |
| 217 | R = pr->R; |
| 218 | dSetZero (pos,4); |
| 219 | dRSetIdentity (R); |
| 220 | } |
| 221 | else { |
| 222 | pos = 0; |
| 223 | R = 0; |
| 224 | } |
| 225 | |
| 226 | // setup space vars |
| 227 | next = 0; |
| 228 | tome = 0; |
| 229 | parent_space = 0; |
| 230 | dSetZero (aabb,6); |
| 231 | category_bits = ~0; |
| 232 | collide_bits = ~0; |
| 233 | |
| 234 | // put this geom in a space if required |
| 235 | if (_space) dSpaceAdd (_space,this); |
| 236 | } |
| 237 | |
| 238 | |
| 239 | dxGeom::~dxGeom() |
nothing calls this directly
no test coverage detected