Two fbgfx bugs on Linux

Linux specific questions.
Post Reply
Landeel
Posts: 777
Joined: Jan 25, 2007 10:32
Location: Brazil
Contact:

Two fbgfx bugs on Linux

Post by Landeel »

Borderless window (GFX_NO_FRAME) will freeze at exit, only in opengl mode (GFX_OPENGL).

Code: Select all

dim as integer fullscreen=0, useopengl=1,  gfxnoswitch=0, borderlesswindow=1, alwaysontop=0, alphaprimitives=0, highpriority=0, multisample=0

dim as long screenflags=iif(fullscreen,&h01,0) or iif(useopengl,&h02,0) or iif(gfxnoswitch,&h04,0) or iif(borderlesswindow,&h08,0) or iif(alwaysontop,&h20,0) or iif(alphaprimitives,&h40,0) or iif(highpriority,&h80,0) or iif(multisample,&h40000,0)	
screenres 1920, 1080, 32, 1, screenflags, 60

do
	screensync
	flip
loop until inkey<>""
Starting fullscreen (GFX_FULLSCREEN) in opengl mode (GFX_OPENGL) will cause the program to steal keyboard input from all other windows.
Can do ALT+ENTER, but can't ALT+TAB, can't type...

Code: Select all

dim as integer fullscreen=1, useopengl=1,  gfxnoswitch=0, borderlesswindow=0, alwaysontop=0, alphaprimitives=0, highpriority=0, multisample=0

dim as long screenflags=iif(fullscreen,&h01,0) or iif(useopengl,&h02,0) or iif(gfxnoswitch,&h04,0) or iif(borderlesswindow,&h08,0) or iif(alwaysontop,&h20,0) or iif(alphaprimitives,&h40,0) or iif(highpriority,&h80,0) or iif(multisample,&h40000,0)	
screenres 1920, 1080, 32, 1, screenflags, 60

do
	screensync
	flip
loop until multikey(1)
I think this behaviour was introduced trying to fix another already fixed bug (freeze on start).

Should I report this?
sean_vn
Posts: 283
Joined: Aug 06, 2012 8:26

Re: Two fbgfx bugs on Linux

Post by sean_vn »

I wasn't able to use FB for a while with Xenial Linux. I thought that was the end of it. However with the new ScPup64 Linux version the graphics are working again. Okay............
MrSwiss
Posts: 3910
Joined: Jun 02, 2013 9:27
Location: Switzerland

Re: Two fbgfx bugs on Linux

Post by MrSwiss »

One of the problems is, from my point of view the Main-Loop.
It is clearly *hogging* the CPU ... I'd add a Sleep, to prevent that:

Code: Select all

Do
    'ScreenSync                          ' is useless, on none CRT-Monitors
    Flip                                ' needed for OpenGL
    Sleep(16, 1)                        ' no CPU hogging (approx. 60 FPS)
Loop Until InKey() <> ""                ' decent way to terminate (no [ESC])
Landeel
Posts: 777
Joined: Jan 25, 2007 10:32
Location: Brazil
Contact:

Re: Two fbgfx bugs on Linux

Post by Landeel »

1) Screensync does sleep;
2) Adding sleep doesn't fix any of the 2 problems.
fatman2021
Posts: 215
Joined: Dec 14, 2013 0:43

Re: Two fbgfx bugs on Linux

Post by fatman2021 »

Unable to swich to fullscreen mode. I am using Manjaro Linux with all the latest updates.
badidea
Posts: 2591
Joined: May 24, 2007 22:10
Location: The Netherlands

Re: Two fbgfx bugs on Linux

Post by badidea »

I can confirm both (keyboard) issues here.
Ubuntu (Mate) 16.04 64-bit.
FBC 1.0.5 32 & 64-bit.
Landeel
Posts: 777
Joined: Jan 25, 2007 10:32
Location: Brazil
Contact:

Re: Two fbgfx bugs on Linux

Post by Landeel »

I want to publish my game on Steam.
The bug that causes keyboard input to be stolen makes it impossible to use the Steam overlay. :(
Landeel
Posts: 777
Joined: Jan 25, 2007 10:32
Location: Brazil
Contact:

Re: Two fbgfx bugs on Linux

Post by Landeel »

Post Reply