| 411 | |
| 412 | |
| 413 | TriPerlinCurve::TriPerlinCurve( IRoot* lockobj ) : |
| 414 | mValue( 0.0f ), |
| 415 | mAlpha( 1.1f ), |
| 416 | mBeta( 2.0f ), |
| 417 | mSpeed( 1.0f ), |
| 418 | mScale( 1.0f ), |
| 419 | mOffset( 0.0f ), |
| 420 | mN( 3 ), |
| 421 | mLastUpdated( -1.0 ), |
| 422 | mStart( 0 ) |
| 423 | { |
| 424 | // time is set automatically so that the algorithm doesn't try to calculate the |
| 425 | // curve many years forward (from time 0), resulting in floating point error jitteriness |
| 426 | // Downside is that if a client runs without restart for several years, floating point errors occur. |
| 427 | // I'll take the risk! |
| 428 | |
| 429 | //mStart = BeOS->GetActualTime(); |
| 430 | mStartOffset = TriRandInt( (int)10000000000 ); |
| 431 | } |
| 432 | |
| 433 | TriPerlinCurve::~TriPerlinCurve() |
| 434 | { |
nothing calls this directly
no test coverage detected