Example code, why is this is slow using fullscreen? font fnt

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
gcmartijn
Party member
Posts: 134
Joined: Sat Dec 28, 2019 6:35 pm

Example code, why is this is slow using fullscreen? font fnt

Post by gcmartijn »

Why is this example slow ?

At the moment this is the case:
- ipad 4gen (I think) - running fast
- imac M1 - running fast (window and full screen)
- old macbook air (target machine at the moment), window mode running fast, fullscreen not.

When I use an Image (not using text), then fullscreen is 60FPS, when I use a Text object it is 34FPS.
This is only the case when using full screen.

Another fact is that in window mode the cpu around 7% mem 94MB. fullscreen cpu 87% mem 245MB.


main.lua

Code: Select all

fonts = {
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt"),
    love.graphics.newFont("font/impact-32-255_255_255.fnt")
}

texts = {}
canvas = {}
redraw = {}
for _, font in pairs(fonts) do
    table.insert(texts, love.graphics.newText(font, "test"))
    table.insert(canvas, love.graphics.newCanvas())
    table.insert(redraw, true)
end

function drawCanvas(index)
    if redraw[index] == false then
        return
    end
    love.graphics.clear()
    love.graphics.setBlendMode("alpha", "alphamultiply")
    love.graphics.setColor(1, 0, 0)
    love.graphics.rectangle("fill", love.math.random(50, 400), love.math.random(50, 400), 100, 100)
    love.graphics.draw(texts[index], love.math.random(50, 400), love.math.random(50, 400))
    redraw[index] = false
end

function love.load()
    for index, canvas in pairs(canvas) do
        canvas:renderTo(
            function()
                drawCanvas(index)
            end
        )
    end
end

function love.draw()
    love.graphics.print("FPS: " .. tostring(love.timer.getFPS()), 10, 10)
    love.graphics.setColor(1, 1, 1, 1)
    love.graphics.setBlendMode("alpha", "premultiplied")
    for _, canvas in pairs(canvas) do
        love.graphics.draw(canvas)
    end
    love.graphics.setBlendMode("alpha", "alphamultiply")
end

function love.keypressed(key, unicode)
    if key == "escape" then
        love.event.quit()
    end
end
config.lua

Code: Select all

function love.conf(t)
    t.identity = "Font"
    t.title = "Font"

    t.appendidentity = false -- Search files in source directory before save directory (boolean)
    t.version = "11.4" -- The LÖVE version this game was made for (string)
    t.console = false -- Attach a console (boolean, Windows only)
    t.accelerometerjoystick = false -- Enable the accelerometer on iOS and Android by exposing it as a Joystick (boolean)
    t.externalstorage = true -- True to save files (and read from the save directory) in external storage on Android (boolean)
    t.gammacorrect = false -- Enable gamma-correct rendering, when supported by the system (boolean)

    t.audio.mic = false -- Request and use microphone capabilities in Android (boolean)
    t.audio.mixwithsystem = true -- Keep background music playing when opening LOVE (boolean, iOS and Android only)

    t.window.icon = nil -- Filepath to an image to use as the window's icon (string)
    t.window.width = 800 -- The window width (number)
    t.window.height = 600 -- The window height (number)
    t.window.borderless = false -- Remove all border visuals from the window (boolean)
    t.window.resizable = false -- Let the window be user-resizable (boolean)
    t.window.minwidth = 1 -- Minimum window width if the window is resizable (number)
    t.window.minheight = 1 -- Minimum window height if the window is resizable (number)
    t.window.fullscreen = true -- Enable fullscreen (boolean)
    t.window.fullscreentype = "desktop" -- Choose between "desktop" fullscreen or "exclusive" fullscreen mode (string)
    t.window.usedpiscale = true -- Enable automatic DPI scaling (boolean)
    t.window.vsync = 1 -- Vertical sync mode (number)
    t.window.msaa = 0 -- The number of samples to use with multi-sampled antialiasing (number)
    t.window.depth = nil -- The number of bits per sample in the depth buffer
    t.window.stencil = nil -- The number of bits per sample in the stencil buffer
    t.window.display = 1 -- Index of the monitor to show the window in (number)
    t.window.highdpi = false -- Enable high-dpi mode for the window on a Retina display (boolean)
    t.window.x = 600 -- The x-coordinate of the window's position in the specified display (number)
    t.window.y = nil -- The y-coordinate of the window's position in the specified display (number)

    t.modules.audio = true -- Enable the audio module (boolean)
    t.modules.data = true -- Enable the data module (boolean)
    t.modules.event = true -- Enable the event module (boolean)
    t.modules.font = true -- Enable the font module (boolean)
    t.modules.graphics = true -- Enable the graphics module (boolean)
    t.modules.image = true -- Enable the image module (boolean)
    t.modules.joystick = false -- Enable the joystick module (boolean)
    t.modules.keyboard = true -- Enable the keyboard module (boolean)
    t.modules.math = true -- Enable the math module (boolean)
    t.modules.mouse = true -- Enable the mouse module (boolean)
    t.modules.physics = false -- Enable the physics module (boolean)
    t.modules.sound = true -- Enable the sound module (boolean)
    t.modules.system = true -- Enable the system module (boolean)
    t.modules.thread = true -- Enable the thread module (boolean)
    t.modules.timer = true -- Enable the timer module (boolean), Disabling it will result 0 delta time in love.update
    t.modules.touch = true -- Enable the touch module (boolean)
    t.modules.video = true -- Enable the video module (boolean)
    t.modules.window = true -- Enable the window module (boolean)
end
font/impact-32-255_255_255.fnt
(not possible to upload .fnt files)

Code: Select all

info face="Impact" size=-32 bold=0 italic=0 charset="" unicode=1 stretchH=100 smooth=0 aa=1 padding=0,0,0,0 spacing=0,0 outline=0
common lineHeight=30 base=36 scaleW=256 scaleH=256 pages=1 packed=0 alphaChnl=0 redChnl=4 greenChnl=4 blueChnl=4
page id=0 file="impact-32-255_255_255_0.png"
chars count=101
char id=32   x=0     y=0     width=0     height=0     xoffset=0     yoffset=0     xadvance=6     page=0  chnl=15
char id=33   x=129   y=21    width=8     height=25    xoffset=1     yoffset=11    xadvance=9     page=0  chnl=15
char id=35   x=0     y=74    width=20    height=23    xoffset=0     yoffset=13    xadvance=20    page=0  chnl=15
char id=36   x=25    y=26    width=17    height=31    xoffset=0     yoffset=8     xadvance=18    page=0  chnl=15
char id=37   x=77    y=0     width=22    height=25    xoffset=0     yoffset=11    xadvance=22    page=0  chnl=15
char id=38   x=86    y=48    width=19    height=22    xoffset=0     yoffset=14    xadvance=18    page=0  chnl=15
char id=39   x=9     y=248   width=6     height=8     xoffset=0     yoffset=11    xadvance=6     page=0  chnl=15
char id=40   x=135   y=190   width=9     height=25    xoffset=1     yoffset=11    xadvance=10    page=0  chnl=15
char id=41   x=126   y=46    width=9     height=25    xoffset=0     yoffset=11    xadvance=10    page=0  chnl=15
char id=42   x=0     y=248   width=9     height=8     xoffset=0     yoffset=11    xadvance=9     page=0  chnl=15
char id=43   x=34    y=122   width=17    height=16    xoffset=0     yoffset=15    xadvance=17    page=0  chnl=15
char id=44   x=41    y=109   width=5     height=8     xoffset=0     yoffset=31    xadvance=5     page=0  chnl=15
char id=45   x=15    y=248   width=9     height=5     xoffset=0     yoffset=23    xadvance=9     page=0  chnl=15
char id=46   x=16    y=241   width=6     height=5     xoffset=0     yoffset=31    xadvance=6     page=0  chnl=15
char id=48   x=83    y=105   width=15    height=25    xoffset=1     yoffset=11    xadvance=17    page=0  chnl=15
char id=49   x=59    y=84    width=11    height=25    xoffset=0     yoffset=11    xadvance=12    page=0  chnl=15
char id=50   x=100   y=21    width=16    height=25    xoffset=0     yoffset=11    xadvance=16    page=0  chnl=15
char id=51   x=16    y=141   width=16    height=25    xoffset=0     yoffset=11    xadvance=17    page=0  chnl=15
char id=52   x=0     y=148   width=16    height=25    xoffset=0     yoffset=11    xadvance=16    page=0  chnl=15
char id=53   x=0     y=173   width=16    height=25    xoffset=1     yoffset=11    xadvance=17    page=0  chnl=15
char id=54   x=0     y=198   width=16    height=25    xoffset=1     yoffset=11    xadvance=17    page=0  chnl=15
char id=55   x=116   y=21    width=13    height=25    xoffset=0     yoffset=11    xadvance=13    page=0  chnl=15
char id=56   x=0     y=223   width=16    height=25    xoffset=1     yoffset=11    xadvance=17    page=0  chnl=15
char id=57   x=16    y=166   width=16    height=25    xoffset=1     yoffset=11    xadvance=17    page=0  chnl=15
char id=58   x=36    y=106   width=5     height=16    xoffset=1     yoffset=20    xadvance=6     page=0  chnl=15
char id=59   x=36    y=87    width=5     height=19    xoffset=1     yoffset=20    xadvance=6     page=0  chnl=15
char id=60   x=48    y=238   width=16    height=16    xoffset=1     yoffset=15    xadvance=17    page=0  chnl=15
char id=61   x=86    y=70    width=16    height=9     xoffset=1     yoffset=19    xadvance=17    page=0  chnl=15
char id=62   x=128   y=229   width=16    height=16    xoffset=1     yoffset=15    xadvance=17    page=0  chnl=15
char id=63   x=16    y=191   width=16    height=25    xoffset=1     yoffset=11    xadvance=17    page=0  chnl=15
char id=64   x=27    y=0     width=25    height=26    xoffset=0     yoffset=11    xadvance=25    page=0  chnl=15
char id=65   x=70    y=80    width=18    height=25    xoffset=-1    yoffset=11    xadvance=16    page=0  chnl=15
char id=66   x=16    y=216   width=16    height=25    xoffset=1     yoffset=11    xadvance=18    page=0  chnl=15
char id=67   x=32    y=141   width=16    height=25    xoffset=1     yoffset=11    xadvance=18    page=0  chnl=15
char id=68   x=32    y=166   width=16    height=25    xoffset=1     yoffset=11    xadvance=18    page=0  chnl=15
char id=69   x=110   y=179   width=12    height=25    xoffset=1     yoffset=11    xadvance=13    page=0  chnl=15
char id=70   x=122   y=179   width=12    height=25    xoffset=1     yoffset=11    xadvance=13    page=0  chnl=15
char id=71   x=32    y=191   width=16    height=25    xoffset=1     yoffset=11    xadvance=18    page=0  chnl=15
char id=72   x=32    y=216   width=16    height=25    xoffset=1     yoffset=11    xadvance=18    page=0  chnl=15
char id=73   x=70    y=24    width=7     height=25    xoffset=1     yoffset=11    xadvance=9     page=0  chnl=15
char id=74   x=123   y=146   width=10    height=25    xoffset=0     yoffset=11    xadvance=11    page=0  chnl=15
char id=75   x=0     y=97    width=17    height=25    xoffset=1     yoffset=11    xadvance=17    page=0  chnl=15
char id=76   x=124   y=204   width=11    height=25    xoffset=1     yoffset=11    xadvance=12    page=0  chnl=15
char id=77   x=0     y=49    width=21    height=25    xoffset=1     yoffset=11    xadvance=23    page=0  chnl=15
char id=78   x=88    y=79    width=15    height=25    xoffset=1     yoffset=11    xadvance=17    page=0  chnl=15
char id=79   x=48    y=138   width=16    height=25    xoffset=1     yoffset=11    xadvance=17    page=0  chnl=15
char id=80   x=64    y=209   width=15    height=25    xoffset=1     yoffset=11    xadvance=16    page=0  chnl=15
char id=81   x=20    y=88    width=16    height=28    xoffset=1     yoffset=11    xadvance=17    page=0  chnl=15
char id=82   x=79    y=209   width=15    height=25    xoffset=1     yoffset=11    xadvance=17    page=0  chnl=15
char id=83   x=51    y=109   width=16    height=25    xoffset=0     yoffset=11    xadvance=17    page=0  chnl=15
char id=84   x=80    y=183   width=15    height=25    xoffset=0     yoffset=11    xadvance=15    page=0  chnl=15
char id=85   x=48    y=163   width=16    height=25    xoffset=1     yoffset=11    xadvance=18    page=0  chnl=15
char id=86   x=41    y=84    width=18    height=25    xoffset=-1    yoffset=11    xadvance=17    page=0  chnl=15
char id=87   x=0     y=0     width=27    height=25    xoffset=0     yoffset=11    xadvance=26    page=0  chnl=15
char id=88   x=48    y=188   width=16    height=25    xoffset=0     yoffset=11    xadvance=15    page=0  chnl=15
char id=89   x=17    y=116   width=17    height=25    xoffset=-1    yoffset=11    xadvance=15    page=0  chnl=15
char id=90   x=110   y=154   width=13    height=25    xoffset=0     yoffset=11    xadvance=13    page=0  chnl=15
char id=91   x=126   y=71    width=8     height=25    xoffset=1     yoffset=11    xadvance=9     page=0  chnl=15
char id=93   x=134   y=71    width=8     height=25    xoffset=0     yoffset=11    xadvance=9     page=0  chnl=15
char id=94   x=24    y=241   width=16    height=13    xoffset=0     yoffset=11    xadvance=15    page=0  chnl=15
char id=95   x=77    y=46    width=19    height=2     xoffset=-1    yoffset=39    xadvance=18    page=0  chnl=15
char id=97   x=64    y=234   width=16    height=21    xoffset=0     yoffset=15    xadvance=16    page=0  chnl=15
char id=98   x=94    y=208   width=15    height=25    xoffset=1     yoffset=11    xadvance=17    page=0  chnl=15
char id=99   x=80    y=234   width=16    height=21    xoffset=0     yoffset=15    xadvance=16    page=0  chnl=15
char id=100  x=48    y=213   width=16    height=25    xoffset=0     yoffset=11    xadvance=17    page=0  chnl=15
char id=101  x=96    y=233   width=16    height=21    xoffset=0     yoffset=15    xadvance=16    page=0  chnl=15
char id=102  x=126   y=120   width=10    height=25    xoffset=0     yoffset=11    xadvance=9     page=0  chnl=15
char id=103  x=64    y=185   width=16    height=24    xoffset=0     yoffset=15    xadvance=17    page=0  chnl=15
char id=104  x=95    y=158   width=15    height=25    xoffset=1     yoffset=11    xadvance=17    page=0  chnl=15
char id=105  x=135   y=46    width=7     height=25    xoffset=1     yoffset=11    xadvance=9     page=0  chnl=15
char id=106  x=42    y=26    width=9     height=28    xoffset=-1    yoffset=11    xadvance=9     page=0  chnl=15
char id=107  x=95    y=183   width=15    height=25    xoffset=1     yoffset=11    xadvance=15    page=0  chnl=15
char id=108  x=137   y=0     width=7     height=25    xoffset=1     yoffset=11    xadvance=9     page=0  chnl=15
char id=109  x=77    y=25    width=23    height=21    xoffset=1     yoffset=15    xadvance=25    page=0  chnl=15
char id=110  x=105   y=46    width=15    height=21    xoffset=1     yoffset=15    xadvance=17    page=0  chnl=15
char id=111  x=112   y=233   width=16    height=21    xoffset=0     yoffset=15    xadvance=16    page=0  chnl=15
char id=112  x=96    y=130   width=15    height=24    xoffset=1     yoffset=15    xadvance=17    page=0  chnl=15
char id=113  x=79    y=159   width=16    height=24    xoffset=0     yoffset=15    xadvance=17    page=0  chnl=15
char id=114  x=134   y=169   width=11    height=21    xoffset=1     yoffset=15    xadvance=11    page=0  chnl=15
char id=115  x=122   y=0     width=15    height=21    xoffset=0     yoffset=15    xadvance=15    page=0  chnl=15
char id=116  x=133   y=145   width=10    height=24    xoffset=0     yoffset=12    xadvance=10    page=0  chnl=15
char id=117  x=111   y=125   width=15    height=21    xoffset=1     yoffset=15    xadvance=17    page=0  chnl=15
char id=118  x=98    y=104   width=16    height=21    xoffset=-1    yoffset=15    xadvance=14    page=0  chnl=15
char id=119  x=99    y=0     width=23    height=21    xoffset=-1    yoffset=15    xadvance=21    page=0  chnl=15
char id=120  x=114   y=99    width=15    height=21    xoffset=0     yoffset=15    xadvance=14    page=0  chnl=15
char id=121  x=80    y=134   width=16    height=24    xoffset=-1    yoffset=15    xadvance=14    page=0  chnl=15
char id=122  x=115   y=67    width=11    height=21    xoffset=0     yoffset=15    xadvance=11    page=0  chnl=15
char id=123  x=58    y=54    width=12    height=30    xoffset=0     yoffset=11    xadvance=12    page=0  chnl=15
char id=124  x=36    y=57    width=5     height=30    xoffset=2     yoffset=11    xadvance=9     page=0  chnl=15
char id=125  x=103   y=70    width=12    height=29    xoffset=0     yoffset=11    xadvance=12    page=0  chnl=15
char id=169  x=0     y=25    width=25    height=24    xoffset=0     yoffset=12    xadvance=25    page=0  chnl=15
char id=174  x=52    y=0     width=25    height=24    xoffset=0     yoffset=12    xadvance=25    page=0  chnl=15
char id=196  x=52    y=24    width=18    height=30    xoffset=-1    yoffset=6     xadvance=16    page=0  chnl=15
char id=209  x=21    y=57    width=15    height=31    xoffset=1     yoffset=5     xadvance=17    page=0  chnl=15
char id=214  x=70    y=49    width=16    height=31    xoffset=1     yoffset=5     xadvance=17    page=0  chnl=15
char id=220  x=42    y=54    width=16    height=30    xoffset=1     yoffset=6     xadvance=18    page=0  chnl=15
char id=223  x=64    y=134   width=16    height=25    xoffset=1     yoffset=11    xadvance=18    page=0  chnl=15
char id=228  x=0     y=122   width=16    height=26    xoffset=0     yoffset=10    xadvance=16    page=0  chnl=15
char id=241  x=64    y=159   width=15    height=26    xoffset=1     yoffset=10    xadvance=17    page=0  chnl=15
char id=246  x=67    y=109   width=16    height=25    xoffset=0     yoffset=11    xadvance=16    page=0  chnl=15
char id=252  x=109   y=208   width=15    height=25    xoffset=1     yoffset=11    xadvance=17    page=0  chnl=15
Attachments
impact-32-255_255_255_0.png
impact-32-255_255_255_0.png (18.39 KiB) Viewed 2877 times
main.lua
(2.56 KiB) Downloaded 81 times
conf.lua
(3.49 KiB) Downloaded 74 times
User avatar
BrotSagtMist
Party member
Posts: 607
Joined: Fri Aug 06, 2021 10:30 pm

Re: Example code, why is this is slow using fullscreen? font fnt

Post by BrotSagtMist »

How is that even a question, you are drawing a ton of pixels there, 20 times the size of your screen.
And since pixel count goes up quadratic with size even a tiny difference in window size has a big impact on performance.
obey
MrFariator
Party member
Posts: 509
Joined: Wed Oct 05, 2016 11:53 am

Re: Example code, why is this is slow using fullscreen? font fnt

Post by MrFariator »

Keep in mind that love.graphics.newCanvas, when not given any arguments, will create a canvas that matches the löve window. As such, the difference between windowed and fullscreen matters - particularly if the difference between the two is notable enough. Like how BrotSagMist put it, this makes the application handle and draw far more pixels in fullscreen, leading to worse performance.

As to why using an image works better than the fonts, well, you haven't provided an example case. My guess (assuming it really is a single image, and not multiple images) is that the way you had your image vs font setup made löve's autobatching work better with the image than it did with fonts, leading to fewer texture swaps while drawing. There may be other factors as well, but since I don't use text objects too often, I'm not well-versed in their pros and cons vs drawing text as images.

If you want comparable performance between fullscreen vs windowed, you'll have to pick an internal render resolution (like 800x600, as defined in your conf.lua), make all canvases that size, and then scale the canvases up/down to match your window resolution when drawn onto the screen. With black borders around the screen if you want to maintain aspect ratio.
User avatar
BrotSagtMist
Party member
Posts: 607
Joined: Fri Aug 06, 2021 10:30 pm

Re: Example code, why is this is slow using fullscreen? font fnt

Post by BrotSagtMist »

There really is no gain when using an image instead of text printing.
It only makes sense when each text is accompanied by tons of decor that takes time to compute.
If all texts where rendered on the same canvas and you would draw one single picture instead i dont even think it would be faster than calling all 20 prints manual.
obey
gcmartijn
Party member
Posts: 134
Joined: Sat Dec 28, 2019 6:35 pm

Re: Example code, why is this is slow using fullscreen? font fnt

Post by gcmartijn »

@mrFariator
Yes that is the solution, for the test example! Going to test it now inside the game.

Using a fixed canvas width and height will fix the FPS at fullscreen 60FPS again.
In the real world the canvas for a button is way smaller, so then it is even faster.
Going to give everything a width and height now.

Code: Select all

table.insert(canvas, love.graphics.newCanvas(800, 600))
@BrotSagtMist
I don't understand what your are saying:
"you are drawing a ton of pixels there, 20 times the size of your screen."

I'm drawing +/- 20 x the word "test" using a font image and 20x a rectangle.
Now I know I had to use a canvas width and height, to make it fast again.
But is there something I don't understand when using this fix ?

As you can see its 60FPS again with the fix.
Screenshot 2022-01-09 at 15.47.20.png
Screenshot 2022-01-09 at 15.47.20.png (41.98 KiB) Viewed 2826 times
gcmartijn
Party member
Posts: 134
Joined: Sat Dec 28, 2019 6:35 pm

Re: Example code, why is this is slow using fullscreen? font fnt

Post by gcmartijn »

Yes I can confirm that the game is now working fast using fullscreen on a old macbook air, the only thing that was needed is a canvas width and height.

I love this forum support :)
User avatar
ReFreezed
Party member
Posts: 612
Joined: Sun Oct 25, 2015 11:32 pm
Location: Sweden
Contact:

Re: Example code, why is this is slow using fullscreen? font fnt

Post by ReFreezed »

For future reference, don't use FPS when measuring performance - it can be very misleading. At least disable vsync - otherwise the FPS will jump from e.g. 60 down to half (30) when it should be 59 (right below 60).
Tools: Hot Particles, LuaPreprocess, InputField, (more) Games: Momento Temporis
"If each mistake being made is a new one, then progress is being made."
gcmartijn
Party member
Posts: 134
Joined: Sat Dec 28, 2019 6:35 pm

Re: Example code, why is this is slow using fullscreen? font fnt

Post by gcmartijn »

I have to find out what the 'best' strategy is too 'lock' 60FPS, for 'all' devices. At the moment I thought vsync was a good way.
It's on the todo list ;) for later.
MrFariator
Party member
Posts: 509
Joined: Wed Oct 05, 2016 11:53 am

Re: Example code, why is this is slow using fullscreen? font fnt

Post by MrFariator »

This is the article that typically gets linked when talking locked timesteps. One example of how to implement it is the tick library.
gcmartijn
Party member
Posts: 134
Joined: Sat Dec 28, 2019 6:35 pm

Re: Example code, why is this is slow using fullscreen? font fnt

Post by gcmartijn »

I did read it :) my first topic some years ago was about the 'best' strategy
https://love2d.org/forums/viewtopic.php ... 56#p231356

But then, I thought "well, i use deltatime at the moment, let check this later".
I will add the tick lib to the todo list, maybe its what I want to use, thanks
Post Reply

Who is online

Users browsing this forum: Google [Bot] and 47 guests