| 348 | } |
| 349 | |
| 350 | void PathCamera::pushBack(CameraSpline::Knot *knot) |
| 351 | { |
| 352 | // Make room at the end |
| 353 | if (mNodeCount == NodeWindow) { |
| 354 | delete mSpline.remove(mSpline.getKnot(0)); |
| 355 | mNodeBase++; |
| 356 | } |
| 357 | else |
| 358 | mNodeCount++; |
| 359 | |
| 360 | // Fill in the new node |
| 361 | mSpline.push_back(knot); |
| 362 | setMaskBits(WindowMask); |
| 363 | |
| 364 | // Make sure the position doesn't fall off |
| 365 | if (mPosition < mNodeBase) { |
| 366 | mPosition = (F32)mNodeBase; |
| 367 | setMaskBits(PositionMask); |
| 368 | } |
| 369 | } |
| 370 | |
| 371 | void PathCamera::pushFront(CameraSpline::Knot *knot) |
| 372 | { |
no test coverage detected