mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-07-11 22:03:01 -06:00
.examples
git-svn-id: svn://ultimatepp.org/upp/trunk@12280 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
cbf64d097d
commit
e7449e8171
2 changed files with 7 additions and 4 deletions
|
|
@ -38,6 +38,6 @@ file
|
|||
Test.iml;
|
||||
|
||||
mainconfig
|
||||
"" = "GUI MT",
|
||||
"" = "GUI";
|
||||
"" = "GUI",
|
||||
"" = "GUI TIMING";
|
||||
|
||||
|
|
|
|||
|
|
@ -57,7 +57,7 @@ void App::Print()
|
|||
void App::Benchmark()
|
||||
{
|
||||
double tm[2];
|
||||
for(int pass = 0; pass < 2; pass++) {
|
||||
for(int pass = 0; pass < 1 + !!ctrl.mt; pass++) {
|
||||
int time0 = GetTickCount();
|
||||
int n = 0;
|
||||
int time;
|
||||
|
|
@ -72,7 +72,10 @@ void App::Benchmark()
|
|||
}
|
||||
tm[pass] = double(time - time0) / n;
|
||||
}
|
||||
PromptOK(Format("ST %.2f ms, MT %.2f ms, ST/MT %.2f", tm[0], tm[1], tm[0] / tm[1]));
|
||||
if(ctrl.mt)
|
||||
PromptOK(Format("ST %.2f ms, MT %.2f ms, ST/MT %.2f", tm[0], tm[1], tm[0] / tm[1]));
|
||||
else
|
||||
PromptOK(Format("%.2f ms", tm[0]));
|
||||
}
|
||||
|
||||
void App::Paint(Draw& w)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue