' SET_GL_SCALE sample ' ' Modern GL 2D game lib needed - Page 2 - freebasic.net ' https://www.freebasic.net/forum/viewtopic.php?t=27886&sid=0942fe5b636aa4942ffe0c43f162003b&start=15 #define NO_BLUR 1 'change to 1 #include "fbgfx.bi" using fb Dim As Integer scrw, scrh scrw = 320 scrh = 240 Dim As Integer dispw, disph, dispdepth ScreenInfo dispw, disph, dispdepth Dim As Double dscale = disph / scrh If dscale < (dispw / scrw) Then dscale = dispw / scrw Dim As Integer scale = Int(dscale) 'If Int(dscale) <> dscale Then scale += 1 screencontrol(SET_GL_2D_MODE, OGL_2D_MANUAL_SYNC) screencontrol(SET_GL_SCALE, scale) ' screenres scrw, scrh, 32, , GFX_OPENGL screenres scrw, scrh, 32, , GFX_OPENGL Or GFX_NO_FRAME #if (NO_BLUR = 1) #include "GL/gl.bi" glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST) glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST) #endif dim as integer w, h, d dim as string driverName screeninfo w, h, d, , , , driverName color RGB(255, 255, 255), RGB(40, 80, 160) cls circle (scrw / 2, scrh / 2), (scrh / 2), rgb(200, 200, 0) Draw String (scrw / 2, 30), str(w) & "x" & h & "x" & d & "@" & driverName Draw String (scrw / 2, 40), "Scale: " & scale & " (" & dscale & ")" '' You need to poll flip() so the window doesn't become unresponsive do sleep 12 flip loop until( len( inkey() ) )