mirror of
https://github.com/edubart/otclient.git
synced 2025-10-14 19:44:54 +02:00
graphics optimization feature inspirated by diablo3 engine
* the rendering now consits of two panes - the background pane (for animated stuff like the map) - the foreground pane (for steady stuff, like UI) each pane has it own max FPS and works idependently this may increase graphics performance on many platforms
This commit is contained in:
@@ -69,9 +69,19 @@ TopPanel
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.right: parent.right
|
||||
|
||||
FrameCounter
|
||||
UILabel
|
||||
size: 68 16
|
||||
text-align: right
|
||||
color: white
|
||||
id: frameCounter
|
||||
anchors.top: parent.top
|
||||
anchors.right: prev.left
|
||||
margin-top: 8
|
||||
margin-right: 5
|
||||
@onSetup: |
|
||||
local updateFunc
|
||||
updateFunc = function()
|
||||
self:setText('FPS: ' .. g_app.getBackgroundPaneFps())
|
||||
scheduleEvent(updateFunc, 250)
|
||||
end
|
||||
updateFunc()
|
||||
|
Reference in New Issue
Block a user