.benchmarks

This commit is contained in:
Mirek Fidler 2023-11-11 15:13:15 +01:00
parent e385d0bb48
commit 6cc877ec98
3 changed files with 48 additions and 0 deletions

View file

@ -0,0 +1,10 @@
uses
CtrlLib;
file
main.cpp,
info.txt;
mainconfig
"" = "GUI";

View file

@ -0,0 +1,7 @@
TIMING Blend : 435.99 ms - 435.99 us (436.00 ms / 1000 ), min: 0.00 ns, max: 1.00 ms, nesting: 0 - 1000
TIMING Stroke : 236.99 ms - 236.99 us (237.00 ms / 1000 ), min: 0.00 ns, max: 1.00 ms, nesting: 0 - 1000
TIMING Fill : 471.99 ms - 471.99 us (472.00 ms / 1000 ), min: 0.00 ns, max: 1.00 ms, nesting: 0 - 1000
TIMING Rect : 596.99 ms - 596.99 us (597.00 ms / 1000 ), min: 0.00 ns, max: 2.00 ms, nesting: 0 - 1000
TIMING Clear 2 : 704.99 ms - 704.99 us (705.00 ms / 1000 ), min: 0.00 ns, max: 1.00 ms, nesting: 0 - 1000
TIMING Clear : 604.99 ms - 604.99 us (605.00 ms / 1000 ), min: 0.00 ns, max: 2.00 ms, nesting: 0 - 1000

View file

@ -0,0 +1,31 @@
#include <CtrlLib/CtrlLib.h>
using namespace Upp;
GUI_APP_MAIN
{
ImagePainter iw(4000, 2000);
iw.Co();
for(int i = 0; i < 10; i++) {
{
RTIMING("Clear");
iw.Clear();
}
{
RTIMING("Text");
for(int y = 0; y < 2000; y += 30)
iw.DrawText(0, y,
"U++ is a C++ cross-platform rapid application development framework focused on programmers productivity. It includes a set of libraries (GUI, SQL, etc.), and an integrated development environment.",
Arial(25));
iw.Finish();
}
}
TopWindow win;
ImageCtrl h;
h.SetImage(iw);
win << h.SizePos();
win.Sizeable().Zoomable();
win.Run();
}