
PureGDK - 3D Programming for PureBasic
The timeout issue is related to the new thread safety code. The application doesn't end until it can verifies that all of the mutex lock has been released and the function queue has reached zero.
This error identifies that the wait/release functions aren't being handled properly somewhere. It may be a special-case that I'll have to deal with specifically for the custom error handler, but I won't know until I look into it.
I also don't check the contents of the effects folder when porting DBP data to PureGDK. If a plugin does copy one of these files then I will need to handle this.
If this is an oversight (please confirm by reinstalling DBP!), just create any file quad.fx to quiet the installer.
This error identifies that the wait/release functions aren't being handled properly somewhere. It may be a special-case that I'll have to deal with specifically for the custom error handler, but I won't know until I look into it.
The command prompt should not be visible when compiling from the IDE. I believe this is an oversight in the installer, which I will fix. Go to Tools -> Configure Tools... and set each entry for PureGDK as "Run Hidden". This won't affect the GUI that pops up.Olby wrote:is it okay that the command prompt is visible along with the GUI of the GDK compiler like this
As a test please uninstall DBP and delete the entire directory. Reinstall DBP, update to 7.1, and tell me if that file still does not exist. I'm pretty sure it's a core file and not something from a plugin. I have all of the plugins installed for debugging right now so it might have come from one of those.ale870 wrote:I tried to install it but I get an installation error:
Couldn't copy the file.
c:\program files\The game creators\Dark basic online\compiler\effects\quad.fx
I have no "quad.fx" file inside.
I also don't check the contents of the effects folder when porting DBP data to PureGDK. If a plugin does copy one of these files then I will need to handle this.
If this is an oversight (please confirm by reinstalling DBP!), just create any file quad.fx to quiet the installer.
Now I get, using this procedure:
Processing compiler parameters ..
Found APP_DATA_PATH C:\ProgramData\PureGDK\
Initializing basic parser ..
DBPProc found at line 91
Debugger off
Initializing full parser ..
Replaced End keyword at line 25
Found command dbsetambientlight at line 39
Found command dbphystart at line 98
Found command dbbackdropon at line 105
Found command dbloadimage at line 159
Found command dbmakeobjectterrain at line 181
Found command dbpositionobject at line 191
Found command dbhidemouse at line 256
Found command dbtext at line 327
Found command dbsubtractvector3 at line 369
Compiling GDKMain..
Resolving error lines...
Error: C:\temp\terrain puregdk\media1\prova_ale.pb
Error: Line 23 - dbGetErrorFilename() is not a function, array, macro or linked list.
Code: Select all
Procedure ErrorHandler()
description.s=GetErrorDescription()
module.s=GetErrorModuleName()
string.s+dbGetErrorDescription(@description.s)+#CRLF$
string.s+"Line: "+Str(GetErrorLineNR())+#CRLF$
string.s+"AFile: "+dbGetErrorFilename(@module.s)+#CRLF$
MessageRequester("Custom Error",string.s)
End
EndProcedure
Found APP_DATA_PATH C:\ProgramData\PureGDK\
Initializing basic parser ..
DBPProc found at line 91
Debugger off
Initializing full parser ..
Replaced End keyword at line 25
Found command dbsetambientlight at line 39
Found command dbphystart at line 98
Found command dbbackdropon at line 105
Found command dbloadimage at line 159
Found command dbmakeobjectterrain at line 181
Found command dbpositionobject at line 191
Found command dbhidemouse at line 256
Found command dbtext at line 327
Found command dbsubtractvector3 at line 369
Compiling GDKMain..
Resolving error lines...
Error: C:\temp\terrain puregdk\media1\prova_ale.pb
Error: Line 23 - dbGetErrorFilename() is not a function, array, macro or linked list.
ale870, see this line from the changelog:
I've already gone through and updated all of the examples for you.
None of the examples from the website will compile without modification. It will be faster if you use the examples provided for PureGDK 7.1 and compare what has changed if you want to debug the problem.The PureGDK functions for handling errors have changed. Please consult the 'How to... -> Reference Manual -> PureGDK' section of the documentation to see a list of revised commands.
I've already gone through and updated all of the examples for you.

It shouldn't. PureGDK 1.1 cleans up differently than the previous versions. It works fine on XP but I haven't tested on Vista, which I think is what you're using.Olby wrote:Looks like there are problems when releasing data or cleaning up after thread usage ?
The crash on my Vista machine points to nvd3dum.dll, which is an nvidia file. Can you confirm this? This does not appear to be a PureGDK issue perse:
http://forums.nvidia.com/lofiversion/in ... 43258.html
Try this patch and see if it fixes the problem for you. Copy it to your "\Users\UserName\AppData\Roaming\PureGDK\plugins-user" folder. If it's not there check your "\Program Files (x86)\PureBasic\PureGDK\PureGDK.ini" for your application data path.
http://puregdk.com/files/upload/PureGDK ... vd3dum.zip
If for some reason this doesn't work (I think it should!) try updating your video card drivers.
Please let me know what fixes it for you!
Last edited by Mistrel on Sat Jan 24, 2009 1:01 pm, edited 1 time in total.
No it did not fix the problem I copied both to the Users path of PGDK and also to where the rest of the PGDK files are located, recompiled and got the same error. Speaking about the video drivers I updated them a week ago and now I have December 2008 drivers which are the last that nvidia officially supports for laptops, I will try to install a different release and see if it helps.
And yes the problem indeed occurs with the nvidia file you mentioned.
And yes the problem indeed occurs with the nvidia file you mentioned.
Intel Core i7 Quad 2.3 Ghz, 8GB RAM, GeForce GT 630M 2GB, Windows 10 (x64)
Are you sure that it you copied it to the proper location?
The correct location for me would be:
"C:\Documents and Settings\UserName\Application Data\PureGDK\plugins-user"
I can confirm that it does correct the problem here for me on my nvidia notebook.
I may have sent you the wrong file -- let me double-check.
The correct location for me would be:
"C:\Documents and Settings\UserName\Application Data\PureGDK\plugins-user"
I can confirm that it does correct the problem here for me on my nvidia notebook.
I may have sent you the wrong file -- let me double-check.
Sorry, I wasn't clear with my initial instructions. I gave the incorrect folder. The correct location is:
"\Users\UserName\AppData\Roaming\PureGDK\plugins-user"
I left out the plugins-user folder at the end. This is important!
Also, please remove PureGDK.dll from wherever else you put it. Although it's unlikely, it might introduce an unexpected problem somewhere else.
"\Users\UserName\AppData\Roaming\PureGDK\plugins-user"
I left out the plugins-user folder at the end. This is important!

Also, please remove PureGDK.dll from wherever else you put it. Although it's unlikely, it might introduce an unexpected problem somewhere else.
-
- User
- Posts: 94
- Joined: Sun Oct 24, 2004 9:25 am
Hi Mistrel
Great work.
When I compile matrix-2.pb without debugger, at run time, I am greeted with
line 72 reads
With debugger enabled, all seems to be running smoothly.
Forgot to mention: The error occurs when i do a left click in the window.
Environment :
Win Xp 32/sp3, up to date patchlevel,
nvidia 8600M GS 512 MB Graphics Ram (not shared), nvida driver level: 6.14.11.7694,
db7.1,
pb4.3
core2duo 2 GB phys RAM
All other demos compile & run fine
kind regards
*edit: changed 8600GS to 8600M GS
Great work.
When I compile matrix-2.pb without debugger, at run time, I am greeted with
Code: Select all
"PureGDK Error"
Function Wait mutex released without lock. Line 72
Address 2088839915
File: P:\Devl\DBPro\matrix\matrix-2.pb
Code: Select all
dbGetMatrixPositionVector(@Vector3.v3, MatrixNumber)
Forgot to mention: The error occurs when i do a left click in the window.
Environment :
Win Xp 32/sp3, up to date patchlevel,
nvidia 8600M GS 512 MB Graphics Ram (not shared), nvida driver level: 6.14.11.7694,
db7.1,
pb4.3
core2duo 2 GB phys RAM
All other demos compile & run fine
kind regards
*edit: changed 8600GS to 8600M GS
Fixed.Captn. Jinguji wrote:When I compile matrix-2.pb without debugger, at run time, I am greeted withCode: Select all
"PureGDK Error" Function Wait mutex released without lock. Line 72 Address 2088839915 File: P:\Devl\DBPro\matrix\matrix-2.pb

This bug is related to the new thread safety code. Most of the code is all the same. Special-case functions like the 3D Math library, anything that accepts/returns a vector/matrix4, and other "custom" PureGDK functions may exhibit this type of error because this code has to be tweaked by hand.
You may run into these every once in a while. But they are the easiest to fix.
-
- User
- Posts: 94
- Joined: Sun Oct 24, 2004 9:25 am
Thanks.Mistrel wrote:Fixed.Captn. Jinguji wrote:When I compile matrix-2.pb without debugger, at run time, I am greeted withCode: Select all
"PureGDK Error"...
![]()

That's ok with me if you keep fixing 'em as fast as you fixed this oneMistrel wrote: This bug is related to the new thread safety code.
You may run into these every once in a while. But they are the easiest to fix.

Keep up the good work.
I cannot get PGDK to work perfectly in fullscreen windowed mode just like it should work in DBPro. I tried the example posted by Mistrel before but that didn't work. Then I tried to stretch window created by PB to my screen resolution, but that made the program to run very very slowly. This is very strange because I know that in DBPro I always use fs windowed mode and it was even faster than the old fullscreen exclusive mode. I don't want to change end user's desktop resolution because when the app will crash it will certainly leave the changed resolution and mess up the icons and such. You should really include a template for creating the same fullscreen windowed mode DBPro uses without affecting users desktop resolution. It utilizes a stretching to stretch small resolutions to fullscreen, but when used with users real desktop resolution there is no quality loss.
Intel Core i7 Quad 2.3 Ghz, 8GB RAM, GeForce GT 630M 2GB, Windows 10 (x64)