Changeset 6502 for code/trunk/src/libraries
- Timestamp:
- Mar 11, 2010, 11:34:20 AM (15 years ago)
- Location:
- code/trunk/src/libraries
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk/src/libraries/core/GUIManager.cc
r6417 r6502 145 145 146 146 // Align CEGUI mouse with OIS mouse 147 guiSystem_->injectMousePosition( mousePosition.first,mousePosition.second);147 guiSystem_->injectMousePosition((float)mousePosition.first, (float)mousePosition.second); 148 148 149 149 // Hide the mouse cursor unless playing in full screen mode -
code/trunk/src/libraries/core/Game.cc
r6422 r6502 284 284 uint64_t currentTime = gameClock_->getMicroseconds(); 285 285 uint64_t currentRealTime = gameClock_->getRealMicroseconds(); 286 this->statisticsTickTimes_.back().tickLength += currentRealTime - currentTime;287 this->periodTickTime_ += currentRealTime - currentTime;286 this->statisticsTickTimes_.back().tickLength += (uint32_t)(currentRealTime - currentTime); 287 this->periodTickTime_ += (uint32_t)(currentRealTime - currentTime); 288 288 if (this->periodTime_ > this->statisticsRefreshCycle_) 289 289 { … … 318 318 while (currentRealTime < nextTime - minimumSleepTime_) 319 319 { 320 usleep( nextTime - currentRealTime);320 usleep((unsigned long)(nextTime - currentRealTime)); 321 321 currentRealTime = gameClock_->getRealMicroseconds(); 322 322 } 323 323 // Integrate excess to avoid steady state error 324 excessSleepTime_ = currentRealTime - nextTime;324 excessSleepTime_ = (int)(currentRealTime - nextTime); 325 325 // Anti windup 326 326 if (excessSleepTime_ > 50000) // 20ms is about the maximum time Windows would sleep for too long -
code/trunk/src/libraries/core/GraphicsManager.cc
r6417 r6502 366 366 uint64_t timeAfterTick = time.getRealMicroseconds(); 367 367 // Subtract the time used for rendering from the tick time counter 368 Game::getInstance().subtractTickTime( timeAfterTick - timeBeforeTick);368 Game::getInstance().subtractTickTime((int32_t)(timeAfterTick - timeBeforeTick)); 369 369 370 370 // again, just to be sure OGRE works fine -
code/trunk/src/libraries/util/Math.h
r6417 r6502 79 79 inline T sgn(T x) 80 80 { 81 return (x >= 0) ? 1 :-1;81 return (x >= 0) ? (T)1 : (T)-1; 82 82 } 83 83
Note: See TracChangeset
for help on using the changeset viewer.