Hi,
I just installed the latest PB(6.02) to date on a Win10 laptop, and when I run something that has the InitEngine3D() command I get the error "The 3D Engine can´t be initialized".
I have not had PB installed on this machine before. The default compiler subsystem is "DirectX11" and my laptop is running DX12 with no errors when I run "dxdiag".
What do I have to do to get the 3D engine system in PB to work?
I have installed some 3D-games that utilize DX9, DX11 and DX12 and also OpenGL and Vulcan and they all work without any issues so I assume the video drivers and those subsystems work.
The laptop has 2 gfx-cards, both an Intel and an Nvidia, if that might have something to do with this?
I did try to change, in the Nvidia settings, which card the purebasic.exe app should use but it didn´t make any difference.
Any help on this in much appreciated.
//Andreas..
3D problem with new computer and PB installation
Re: 3D problem with new computer and PB installation
Change the InitEngine3D() command in the example source into InitEngine3D(#PB_Engine3D_DebugLog) and examine ogre.log.
{Home}.:|:.{Dialog Design0R}.:|:.{Codes}.:|:.{History Viewer Online}.:|:.{Send a Beer}
Re: 3D problem with new computer and PB installation
+ When you compile your executable, make sure Engine3D.dll is copied in the same directory as the .exe file (and that they are for the same x64 or x86 target architecture).
Re: 3D problem with new computer and PB installation
Thanks for your replies.
I got it to work when I cleared the value in Compiler Options and Library Subsystems.
I was also wrong about "DirectX11" being a default value in PB. Atleast in PB v6.02 a blank value is the default.
I learned that the compiler options are saved individually in the .pb code file itself. Did not know that.
I also learned that in PB v6 and newer only OpenGL is used for HW3D operations, when older versions could use both DirectX and OpenGL as HW3D.
Would be interesting to know why this is? This would mean that from now on all HW3D program cannot use DirectX. Please correct me if I´m wrong here.
I got it to work when I cleared the value in Compiler Options and Library Subsystems.
I was also wrong about "DirectX11" being a default value in PB. Atleast in PB v6.02 a blank value is the default.
I learned that the compiler options are saved individually in the .pb code file itself. Did not know that.
I also learned that in PB v6 and newer only OpenGL is used for HW3D operations, when older versions could use both DirectX and OpenGL as HW3D.
Would be interesting to know why this is? This would mean that from now on all HW3D program cannot use DirectX. Please correct me if I´m wrong here.
Re: 3D problem with new computer and PB installation
Available SubSystem (enter in compiler option)
- DirectX9
- DirectX11
OpenGL its default
- DirectX9
- DirectX11
OpenGL its default
My Projects ThreadToGUI / OOP-BaseClass / EventDesigner V3
PB v3.30 / v5.75 - OS Mac Mini OSX 10.xx - VM Window Pro / Linux Ubuntu
Downloads on my Webspace / OneDrive
PB v3.30 / v5.75 - OS Mac Mini OSX 10.xx - VM Window Pro / Linux Ubuntu
Downloads on my Webspace / OneDrive
Re: 3D problem with new computer and PB installation
For me, I get the error above in my original post when I have "DirectX11" listed as sybsystem.
But games that use HW3D and DirectX11 works on this computer so why doesn´t PB work for me?
If I put "DirectX9", then it works, but not 11.
But games that use HW3D and DirectX11 works on this computer so why doesn´t PB work for me?
If I put "DirectX9", then it works, but not 11.
Re: 3D problem with new computer and PB installation
I just tried this with "DirectX11" as subsystem and there are no errors in the ogre.log file.HeX0R wrote: Thu Jul 06, 2023 7:34 pm Change the InitEngine3D() command in the example source into InitEngine3D(#PB_Engine3D_DebugLog) and examine ogre.log.
There are about 30 lines and these 2 are the last:
13:01:45: *-*-* OGRE Initialising
13:01:45: *-*-* Version 1.8.2 (Byatis)
If I check the same log using blank sybsystem I get lots more information.
Re: 3D problem with new computer and PB installation
Unfortunately, I can't test it because I only have a Windows 10 VM on Parallels. (Optimised for OpenGL)
My Projects ThreadToGUI / OOP-BaseClass / EventDesigner V3
PB v3.30 / v5.75 - OS Mac Mini OSX 10.xx - VM Window Pro / Linux Ubuntu
Downloads on my Webspace / OneDrive
PB v3.30 / v5.75 - OS Mac Mini OSX 10.xx - VM Window Pro / Linux Ubuntu
Downloads on my Webspace / OneDrive



