home *** CD-ROM | disk | FTP | other *** search
-
- -- get the list of videofiles
- szScriptFolder = "Scripts/UIScreens/";
-
- -- Load Configuration
- Script:LoadScript(szScriptFolder.."UISystemCfg.lua", 1); -- Load Configuration File
-
- -- Load the skin
- Script:LoadScript(UI.szSkinPath, 1);
-
- UI.PageBenchmarkResults=
- {
- GUI=
- {
-
- -- ------------------------- Current Result -------------------------
-
- Result_Background =
- {
- classname = "static",
- left = 230, top = 100,
- width = 340, height = 400,
-
- color = UI.szMessageBoxScreenColor,
-
- zorder = -1,
- },
-
- Result_Label =
- {
- skin = UI.skins.Label,
- left = 245, top = 105,
- width = 310, height = 32,
-
- text = "Benchmark Result",
- fontname = "UI_Default_Bold",
- fontsize = 18,
- halign = UIALIGN_CENTER,
- },
-
- Result_Separator =
- {
- classname = "static",
- left = 245, top = 142,
- width = 310, height = 5,
-
- texture = System:LoadImage("Textures/GUI/Titlebar"),
- halign = UIALIGN_CENTER,
-
- },
-
- --Time_Label =
- --{
- -- skin = UI.skins.Label,
- -- left = 260, top = 182,
- -- width = 295, height = 20,
-
- -- text = "Time Elapsed: 0min 0sec",
- -- fontname = "UI_Default_Bold",
- -- fontsize = 14,
- -- halign = UIALIGN_LEFT,
- --},
-
- FPS_Label =
- {
- skin = UI.skins.Label,
- left = 260, top = 202,
- width = 295, height = 20,
-
- text = "??.? frames per second",
- fontname = "UI_Default_Bold",
- fontsize = 14,
- halign = UIALIGN_LEFT,
- },
-
- Settings_Label =
- {
- skin = UI.skins.Label,
- left = 260, top = 282,
- width = 295, height = 20,
-
- text = "Settings:",
- fontname = "UI_Default_Bold",
- fontsize = 14,
- halign = UIALIGN_LEFT,
- },
-
- Config_Res_Label =
- {
- skin = UI.skins.Label,
- left = 275, top = 302,
- width = 280, height = 20,
-
- text = "1024x768 with 32bit color",
- fontname = "UI_Default",
- fontsize = 12,
- halign = UIALIGN_LEFT,
- },
-
- Config_FSAA_Label =
- {
- skin = UI.skins.Label,
- left = 275, top = 322,
- width = 280, height = 20,
-
- text = "?x FSAA",
- fontname = "UI_Default",
- fontsize = 12,
- halign = UIALIGN_LEFT,
- },
-
-
- -- ------------------------- Bottom Buttons -------------------------
-
- StartOver =
- {
- text = "Configure Options",
- skin = UI.skins.ActionButton,
- fontname = "UI_Control",
-
- left = 250, top = 544,
- width = 160, height = 32,
-
- tabstop = 1,
-
- OnCommand = function(self)
- TechDemo:GoToScreen( ".." );
- TechDemo:GoToScreen( ".." );
- end,
- },
-
- AnotherTry =
- {
- text = "Run Benchmark",
- skin = UI.skins.ActionButton,
- fontname = "UI_Control",
-
- left = 425, top = 544,
- width = 160, height = 32,
-
- tabstop = 1,
-
- OnCommand = function(self)
- TechDemo:GoToScreen( ".." );
- end,
- },
-
- Quit =
- {
- text = "Quit",
- skin = UI.skins.ActionButton,
- fontname = "UI_Control",
-
- left = 600, top = 544,
- width = 160, height = 32,
-
- tabstop = 1,
-
- OnCommand = function(self)
- TechDemo:Quit();
- end,
- },
-
- OnInit = function(self)
- --szResults = TechDemo:GetBenchmarkResults();
- --UI.PageBenchmarkResults.GUI.Result_Title.text = szResults;
- end,
-
- OnActivate= function(self) -- this will be called everytime you activate this screen
-
- local szResults = TechDemo:GetBenchmarkResults();
- UI.PageBenchmarkResults.GUI.FPS_Label:SetText( szResults.." frames per second" );
-
- UI.PageBenchmarkResults.GUI.Config_Res_Label:SetText( tostring(r_Width).."x"..tostring(r_Height).." with "..tostring(r_ColorBits).."bit color" );
- UI.PageBenchmarkResults.GUI.Config_FSAA_Label:SetText( tostring(r_FSAA).."x FSAA" );
-
- --UI.PageBenchmarkResults.GUI.Time_Label:SetText( "Time Elapsed: "..tostring(Benchmark_TotalMinutes).."min "..tostring(Benchmark_TotalSeconds).."sec" );
-
- end,
- },
- };
-
- szScreen = "BenchmarkResults";
- UI:CreateScreenFromTable(szScreen, UI.PageBenchmarkResults.GUI);
- Script:LoadScript("Scripts/UIScreens/UISystem.lua", 1);
-