Review fixes.

This commit is contained in:
Yuri Gorshenin 2015-03-26 19:57:23 +03:00 committed by Alex Zolotarev
parent 2b0f412528
commit f29c8e6f35
2 changed files with 8 additions and 7 deletions

View file

@ -43,9 +43,11 @@ public:
~Thread();
/// Run thread immediately.
/// @param routine Routine that will be executed on m_thread and destroyed by
/// the current Thread instance or by the m_thread, if
/// it will be detached during the execution of routine.
///
/// @param routine Routine that will be executed on m_thread and
/// destroyed by the current Thread instance or by
/// the m_thread, if it is detached during the
/// execution of routine.
bool Create(unique_ptr<IRoutine> && routine);
/// Calling the IRoutine::Cancel method, and Join'ing with the task

View file

@ -321,8 +321,7 @@ void FrontendRenderer::Routine::Do()
context->makeCurrent();
my::Timer timer;
// double processingTime = InitAvarageTimePerMessage; // By init we think that one message
// processed by 1ms
//double processingTime = InitAvarageTimePerMessage; // By init we think that one message processed by 1ms
timer.Reset();
while (!IsCancelled())
@ -339,10 +338,10 @@ void FrontendRenderer::Routine::Do()
{
m_renderer.ProcessSingleMessage(availableTime * 1000.0);
availableTime = VSyncInterval - (timer.ElapsedSeconds() /*+ avarageMessageTime*/);
// messageCount++;
//messageCount++;
}
// processingTime = (timer.ElapsedSeconds() - processingTime) / messageCount;
//processingTime = (timer.ElapsedSeconds() - processingTime) / messageCount;
context->present();
timer.Reset();