Compiler Subsystem Details
Posted: Sat Oct 01, 2011 8:47 pm
The whole time I have been using PB, I have never been very clear on the different subsystems available in the compiler. I usually program on Windows, using the default subsystem (directx9 now?).
The 4.51 help file reads:
I'm mainly interested in the Windows subsystems, including directx7 which isn't listed in the help (?). If anyone has any more details or experiences to share, the advantages/disadvantages of each, when or when NOT to use them, performance tradeoffs, bugs, etc. please mention them.
My motivation for asking is that I'm working on a decent-sized game and everything is drawn by the 2D drawing library in real-time. I'm developing on XP Pro and I get smooth 60 FPS gameplay. However the recent "2D drawing is slow as hell" thread has got me paranoid about future issues when porting to newer Windows, plus hopefully Mac, and possibly Linux. This might happen around New Years time, so 4.60 should be finished.
I've been experimenting with the available subsystems and getting bizarre results... here are some examples (all PB 4.60 RC 1):
XP Pro, default subsystem: game runs/draws smoothly, ~60 fps
XP Pro, directx7: game draws ~60 fps, but the collision system somehow becomes buggy and unreliable (collision code is independent of drawing code!) which reminds me of an old thread about the graphics subsystem affecting the floating-point operations somehow... I will try to find this.
XP Pro, nt4: game doesn't start, because OpenScreen() fails for me in 4.51+, or at least returns 0...
XP Pro, opengl: first I have to remove DisplayTranslucentSprite(), then I have to remove writing to the DrawingBuffer() because I get IMA crashes... then the game runs but the screen is all white. This also happens with some help examples, like the Direct Screen Drawing one.
Windows 7, default subsystem: game crashes with IMA, I will get more details when I have access to it again
I need to investigate all these problems... any insight? For what it's worth, I have Intel integrated laptop graphics, which seem to have their own issues, which I once brought up here: http://www.purebasic.fr/english/viewtop ... 13&t=45577 I hope my 5-year-old cheap graphics card / drivers are to blame for most of these problems here. I have seen commercial games that specifically say they will not run on Intel integrated graphics...
Anyway, I am busy with finishing school and job hunting right now, so this game won't even be near finished until 2012, so these issues aren't terribly urgent.
The 4.51 help file reads:
Code: Select all
Windows
nt4 : uses DirectX3 only for any library that uses DirectX in order to be compatible to Windows NT 4.
opengl : uses OpenGL for the 3D libraries.
Linux
gtk1 : uses Gtk1.2 instead of Gtk2 for the compilation. (requires the gtk1.2-dev package)
Note that this subsystem is no longer maintained and some features may be missing.
MacOSX
There are currently no official subsystems for MacOSX.My motivation for asking is that I'm working on a decent-sized game and everything is drawn by the 2D drawing library in real-time. I'm developing on XP Pro and I get smooth 60 FPS gameplay. However the recent "2D drawing is slow as hell" thread has got me paranoid about future issues when porting to newer Windows, plus hopefully Mac, and possibly Linux. This might happen around New Years time, so 4.60 should be finished.
I've been experimenting with the available subsystems and getting bizarre results... here are some examples (all PB 4.60 RC 1):
XP Pro, default subsystem: game runs/draws smoothly, ~60 fps
XP Pro, directx7: game draws ~60 fps, but the collision system somehow becomes buggy and unreliable (collision code is independent of drawing code!) which reminds me of an old thread about the graphics subsystem affecting the floating-point operations somehow... I will try to find this.
XP Pro, nt4: game doesn't start, because OpenScreen() fails for me in 4.51+, or at least returns 0...
XP Pro, opengl: first I have to remove DisplayTranslucentSprite(), then I have to remove writing to the DrawingBuffer() because I get IMA crashes... then the game runs but the screen is all white. This also happens with some help examples, like the Direct Screen Drawing one.
Windows 7, default subsystem: game crashes with IMA, I will get more details when I have access to it again
I need to investigate all these problems... any insight? For what it's worth, I have Intel integrated laptop graphics, which seem to have their own issues, which I once brought up here: http://www.purebasic.fr/english/viewtop ... 13&t=45577 I hope my 5-year-old cheap graphics card / drivers are to blame for most of these problems here. I have seen commercial games that specifically say they will not run on Intel integrated graphics...
Anyway, I am busy with finishing school and job hunting right now, so this game won't even be near finished until 2012, so these issues aren't terribly urgent.