After a very long time in development I'm pleased to announce the public release of PureGDK 2.0 Beta!
You can download the most recent version at
http://puregdk.com by registering for an account. The PureGDK beta will appear under the "My Products" tab of your account page.
PureBasic users: You "must" uninstall any previous release of PureGDK 1.0 before installing PureGDK 2.0. Older releases are not compatible and you will not be able to compile.
C++ users: If you are having trouble with the latest release, try running the uninstaller which will clear out any old, possibly conflicting .h/.cpp files. Then reinstall and try again.
Changelog:
Quote: "
PureGDK 2.0 Release Candidate 1
-------------------
Bug fixes:
- The gdkc.exe tool will no longer evaluate invalid string table entries which do not have exports.
Updates:
- Added registry keys to HKLM/HKCU which identify the PureGDK install path and version number for third-party developers.
- Added an uninstaller and an entry for it in the add/remove programs dialog in the control panel.
- The installer now expects a serial number to install. This number can be obtained from your user account at http://puregdk.com.
- Reverted renaming of "chroma" back to "color" as the key is actually 1-bit instead of a range of colors.
- Removed the builddocs tool and its source code from the PureGDK SDK for the time being.
- The installer now provides better context menu handling.
- Corrected some erroneous constants which did not match the documentation."
PureGDK 2.0 beta 14
-------------------
Bug fixes:
- dbHideMouse now correctly hides the mouse as expected.
Updates:
- Added a new tool "strtable.exe" for extracting string tables from DarkBasic Professional plugins. This tool will work with both licensed and user plugins.
- Added several new pages to the documentation regarding command-line tools, engine extensibility, wrapping plugins, and how to add additional language support.
- The PureGDK SDK is now bundled as part of the installer.
- The builddocs tool and source code is now bundled with the installer but will not receive any attention or documentation until after PureGDK 2.0 is released.
- Minor changes to libbuilder.h and plugin sources which are incompatible with previous releases.
- Added out-of-the-box support for the following plugins:
* Intel AppUp Helper Plugin : http://appdeveloper.intel.com/en-us/node/1097
* DarkBasic Professional Enhancement Pack : http://www.thegamecreators.com/?m=view_product&id=2083
* FPSC ODE Physics : (Built into DBP)
PureGDK 2.0 beta 13
-------------------
Bug fixes:
- Fixed a few typos which created problems for PureBasic-generated code for recently added plugins.
- The documentation for PureBasic wasn't building properly and instead contained the documentation for C++.
- Fixed a bug where dbDot with the optional color parameter did not set the ink color as expected.
- Fixed a bug in the documentation builder where command cross-references were not parsing outside of the library currently being evaluated.
Updates:
- Added dbCloseScreen to all example projects where it was missing.
- Added an entry for dbCloseScreen to the documentation under "Fundamentals".
- Tweaked gdkc.exe parameter prefixes to be more consistent.
- Fixed a typo in the buldlibs.exe commandline help.
- Corrected formatting inconsistencies and innacurate constant references in the documentation.
- Renamed dbSprite to dbCreateSprite to be more consistent with other commands names and reordered its parameters to support automatic ID allocation.
- Clarified some parameter names and corrected a few inconsistencies.
- Added support for RegisterFunctionPtr in Matrix1Util_20.dll.
- The gdkc.exe "libraries" file now only requires a dll name to be listed for it to be included as part of the white-list, greatly simplifying the process required to add support for new libraries.
- Added documentation entries for the command-line tools "gdkc.exe" and "buildlibs.exe".
- New commands:
* dbGetDirect3D
* dbGetDirect3DDevice
PureGDK 2.0 beta 12
-------------------
Bug fixes:
- Fixed a bug where dbSetObjectFilter was passing its parameters in the wrong order.
Updates:
- Added out-of-the-box support for the following plugins:
* Blitzwerks Terrain : http://www.thegamecreators.com/?m=view_product&id=2286
* Box2D : http://www.thegamecreators.com/?m=view_product&id=2257
* DarkImposters : http://www.thegamecreators.com/?m=view_product&id=2293
PureGDK 2.0 beta 11
-------------------
Bug fixes:
- Fixed a bug where dbLimbName, dbLimbTextureName, and dbEntry were not returning a string as expected.
- Fixed a bug where functions which set shader constants were not evaluating structures correctly.
Updates:
- Added support for full-text search to the documentation.
- All documentation generated for a target language will now be compiled to its own .chm file.
- Various textual improvements to the library documentation.
- Added support for IanM's Matrix1Util library plugins 9, 12, 18, and 26 (for real this time).
- Support for DKShop and DKAVM has been removed, as these plugins no longer work.
- dbSetDisplayMode now calls dbReloadDisplayPointer internally (part of the DarkShader runtime).
- Added a new command dbSetRuntimeErrorCallback to allow logging of runtime errors.
- Added several commands introduced by the DarkShader runtime.
- Added out-of-the-box support for the following plugins:
* A* Pathfinding : http://forum.thegamecreators.com/?m=forum_view&t=114240&b=5
* Advanced Audio : http://forum.thegamecreators.com/?m=forum_view&t=111325&b=8
* Advanced Sprites : http://forum.thegamecreators.com/?m=forum_view&t=113378&b=5
* DarkData : http://www.thegamecreators.com/?m=view_product&id=2067
* DarkInk : http://www.thegamecreators.com/?m=view_product&id=2075
* DarkNet : http://www.thegamecreators.com/?m=view_product&id=2070
* DarkVideo : http://www.thegamecreators.com/?m=view_product&id=2227
* GreenEar : http://www.thegamecreators.com/?m=view_product&id=2227
* Image Kit V2 : http://forum.thegamecreators.com/?m=forum_view&t=177340&b=5
* Matrix1Util : http://forum.thegamecreators.com/?m=forum_view&t=85209&b=18
* Object LOD : http://forum.thegamecreators.com/?m=forum_view&t=159658&b=5
* Quadtree : http://forum.thegamecreators.com/?m=forum_view&t=108837&b=18
- New commands:
* dbApplyDynamicCubeMapToObject
* dbCreateDynamicCubeMap
* dbDeleteCameraEffect
* dbDeleteDynamicCubeMap
* dbGetCameraEffect
* dbIsCameraEffect
* dbIsDynamicCubeMap
* dbLoadCameraEffect
* dbRemoveCameraEffect
* dbRenderDynamicCubeMap
* dbSetCameraEffect
* dbSetCameraEffectConstantFloat
* dbSetCameraEffectConstantInteger
* dbSetCameraEffectConstantVector
* dbSetRuntimeErrorCallback
* dbSyncCamera
PureGDK 2.0 beta 10
-------------------
Bug fixes:
- Fixed a bug where plugin headers were not evaluating their include path correctly (really fixed it this time).
- Corrected some parameter name conflics that were illegal in C++ in a few third-party plugin templates.
- Fixed the PureBasic plugin examples to use the new parameter order convention update from beta 7.
- Fixed a bug with the C++ language plugin where return types for doubles and 64-bit integers weren't being resolved correctly.
- Fixed a bug with the C++ language plugin where function call typedefs for polymorphized functions were not being enumerated.
- Fixed a bug where dbCreateObjectTriangle was erroneously passing the wrong parameter type, causing it to fail.
Updates:
- Updated Sparky's collision library to support the latest 2.05 release.
- Updated the D3DFunc library to support the latest 3.7.1 release.
- PureGDK now also copies over the TGC certificates viewer application to help you verify whether a commercial plugin you've installed is properly licensed.
- Included plugin templates for third-party plugins have been reevaulated for consistency. Various prefixes have been adjusted align to the prefix-underscore convention.
- Updated the D3DFunc library to conform to beta 4 optional parameter specification.
- Added example C++ projects for DarkAI, DarkClouds, DarkLights, and DarkPhysics.
- The PureGDK installer will now build the gdkengine.dll with commercial and user plugins by default.
- Added support for IanM's Matrix1Util library plugins 9, 12, 18, and 26.
- Merged legacy third-party templates into a single file per-library instead of one file per-dll; to be resolved to a single header.
- gdkc.exe and buildlibs.exe now print their errors to stderr instead of stdout.
PureGDK 2.0 beta 9
------------------
Bug fixes:
- Fixed a bug where plugin headers were not evaluating their include path correctly.
- Fixed creation and load functions which were failing to return the IDs passed to them.
- Fixed creation and load functions which were failing to return a unique ID when passed -1 as expected.
Updates:
- The documentation has received a lot of polish for this release including font style, text placement, new topics, index revisions, as well as a few minor bug fixes.
- puregdk_cpp.chm and puregdk_purebasic.chm have been merged into puregdk.chm. All documentation for language targets have been split into aliased folders within the Library/ path of the documentation. Searching the index will now provide links to all supported languages to eliminate ambiguity.
- Added new entries for PureBasic and C++ fundamentals, source examples in the documentation, and full walkthroughs on how to setup a project in PureBasic, Visual Studio 2008 and Visual Studio 2010.
- Vector and matrix structures now use their fully-qualified name by default (Vector2 vs. v2) for clarity.
PureGDK 2.0 beta 8
------------------
Bug fixes:
- Fixed a bug in Matrix.gdt which was preventing dbCreateMatrix from evaluating correctly.
Updates:
- The installer now creates start menu entries with links to the documentation, projects, and useful batch files.
- The installer now checks for licensing errors when it builds the engine dll during installation an will report the offending library if a problem has occurred.
- The installer now checks checks for the existence of a DarkBasic Professional and will provide useful information about where to download it if it cannot be found. This is in contrast to previous versions which simply asked for a directory path.
- The installer now verifies whether a compatible version of DarkBasic Professional has been selected. It will not continue unless the correct version (at least 7.7) has been detected. It will also provide useful information about where to download it if it was not detected.
- The installer now verifies that the engine dll has been created successfully after calling gdkc.exe.
- Various other small bits of polish, fixing typos, and textual changes to the installer.
PureGDK 2.0 beta 7
------------------
Bug fixes:
- dbCameraExist no longer has a default parameter.
- Fixed a few erroneous command names:
* dbLockpixels -> dbLockPixels
* dbStopRecodingSound -> dbStopRecordingSound
* dbGetBackbufferWidthWidth -> dbGetBackbufferWidth
Updates:
- Document commands are also now verified against existing commands in the template libraries to eliminate the documenting of erroneous parameters and non-existent commands. The documentation itself has gotten a major visual overhaul as well.
- The documentation builder now has the ability to create .chm documentation for multiple languages using shared templates. Any change to the documentation will propegate to every targeted language.
- Added runtime error constants to PureGDK.gdt as well as the documentation. Every command which returns an error is now documented.
- Added the dbSetD3DDeviceCallback command for recovering from an invalid render device.
- dbSyncRate now uses DBP's more accurate frame rate limiter.
- Added '-v' parameter to buildlibs.exe to provide additional verbose output for aggregating command documentation. Several parameters for this tool have also been adjusted for consistency.
- Updated the SDK specification and plugins to support verbose output and new arc/argv parameters. Changes are incompatible with previous beta SDK releases.
- Specifying an ID explicitly for creation and load commands which would normally accept an ID is now optional. Many commands have had their parameters reordered for support this behavior.
- New commands:
* dbIsAdvancedTerrain
* dbIsCloth
* dbIsCollider
* dbIsEffector
* dbIsEmitter
* dbSetD3DDeviceCallback
* dbSetNVPerfHUD
- Renamed the following commands to be more specific and/or consistent with other commands:
* dbAddMeshToBuffer -> dbAddMeshToVertexBuffer
* dbAnimationExist -> dbIsAnimation
* dbBitmapExist -> dbIsBitmap
* dbCameraExist -> dbIsCamera
* dbChangeMesh -> dbReplaceMesh
* dbCreateObjectTerrain -> dbCreateAdvancedTerrain
* dbCSGDifferenceOnVertexData -> dbCSGDifferenceOnVertexBuffer
* dbCSGIntersectionOnVertexData -> dbCSGIntersectionOnVertexBuffer
* dbCSGUnionOnVertexData -> dbCSGUnionOnVertexBuffer
* dbDeleteMeshFromBuffer -> dbDeleteMeshFromVertexBuffer
* dbDestroyTerrain -> dbDeleteAdvancedTerain
* dbEffectExist -> dbIsEffect
* dbFreeAllClothPoints -> dbDeleteAllClothPoints
* dbFreeAllClothPointsOnAllObjects -> dbDeleteAllClothPointsOnAllObjects
* dbFreeAllClothPointsOnObject -> dbDeleteAllClothPointsOnObject
* dbFreeAllRagdollPoints -> dbDeleteAllRagdollPoints
* dbFreeClothNearestPoint -> dbDeleteClothNearestPoint
* dbFreeClothPoint -> dbDeleteClothPoint
* dbFreeClothPoints -> dbDeleteClothPoints
* dbFreeClothPointsRadius -> dbDeleteClothPointsRadius
* dbFreeNetGame -> dbDeleteNetGame
* dbFreeNetPlayer -> dbDeleteNetPlayer
* dbGetBufferIndexCount -> dbGetVertexBufferIndexCount
* dbGetBufferIndexData -> dbGetVertexBufferIndexData
* dbGetBufferVertexCount -> dbGetVertexBufferVertexCount
* dbImageExist -> dbIsImage
* dbLimbExist -> dbIsLimb
* dbMakeBasicEmitter -> dbCreateBasicEmitter
* dbMakeBitmapFromMemblock -> dbCreateBitmapFromMemblock
* dbMakeBoxEmitter -> dbCreateBoxEmitter
* dbMakeCamera -> dbCreateCamera
* dbMakeChaosEffector -> dbCreateChaosEffector
* dbMakeCloth -> dbCreateCloth
* dbMakeCollisionBox -> dbCreateCollisionBox
* dbMakeCollisionDisc -> dbCreateCollisionDisc
* dbMakeCollisionPlane -> dbCreateCollisionPlane
* dbMakeCollisionSphere ->dbCreateCollisionSphere
* dbMakeCollisionSquare -> dbCreateCollisionSquare
* dbMakeColorEffector -> dbCreateColorEffector
* dbMakeDampingEffector -> dbCreateDampingEffector
* dbMakeDragEffector ->dbCreateDragEffector
* dbMakeFireParticles -> dbCreateFireParticles
* dbMakeFlockEffector -> dbCreateFlockEffector
* dbMakeForceEffector -> dbCreateForceEffector
* dbMakeGravityEffector -> dbCreateGravityEffector
* dbMakeImageFromMemblock -> dbCreateImageFromMemblock
* dbMakeLight -> dbCreateLight
* dbMakeMatrix -> dbCreateMatrix
* dbMakeMemblock -> dbCreateMemblock
* dbMakeMemblockFromBitmap -> dbCreateMemblockFromBitmap
* dbMakeMemblockFromImage -> dbCreateMemblockFromImage
* dbMakeMemblockFromMesh -> dbCreateMemblockFromMesh
* dbMakeMemblockFromSound -> dbCreateMemblockFromSound
* dbMakeMeshFromMemblock -> dbCreateMeshFromMemblock
* dbMakeMeshFromObject -> dbCreateMeshFromObject
* dbMakeObject -> dbCreateObject
* dbMakeObjectBox -> dbCreateObjectBox
* dbMakeObjectCollisionBox -> dbCreateObjectCollisionBox
* dbMakeObjectCone -> dbCreateObjectCone
* dbMakeObjectCube -> dbCreateObjectCube
* dbMakeObjectCylinder -> dbCreateObjectCylinder
* dbMakeObjectFromLimb -> dbCreateObjectFromLimb
* dbMakeObjectPlane -> dbCreateObjectPlane
* dbMakeObjectSphere -> dbCreateObjectSphere
* dbMakeObjectTerrain -> dbCreateObjectTerrain
* dbMakeObjectTriangle -> dbCreateObjectTriangle
* dbMakeParticles -> dbCreateParticles
* dbMakePointEffector -> dbCreatePointEffector
* dbMakeSizeEffector -> dbCreateSizeEffector
* dbMakeSnowParticles -> dbCreateSnowParticles
* dbMakeSoundFromMemblock -> dbCreateSoundFromMemblock
* dbMakeSphericalEmitter -> dbCreateSphericalEmitter
* dbMakeStaticCollisionBox -> dbCreateStaticCollisionBox
* dbMakeStaticLimb -> dbCreateStaticLimb
* dbMakeStaticObject -> dbCreateStaticObject
* dbMakeTerrain -> dbCreateTerrain
* dbMakeVortexEffector -> dbCreateVortexEffector
* dbMakeWindEffector -> dbCreateWindEffector
* dbMakeWrapAroundEffector -> dbCreateWrapAroundEffector
* dbMatrixExist -> dbIsMatrix
* dbMatrixTilesExist -> dbIsMatrixTextured
* dbMemblockExist -> dbIsMemblock
* dbMeshExist -> dbIsMesh
* dbMusicExist -> dbIsMusic
* dbNetGameExist -> dbIsNetGame
* dbNetMessageExist -> dbIsNetMessage
* dbObjectExist -> dbIsObject
* dbParticlesExist -> dbIsParticles
* dbPixelShaderExist -> dbIsPixelShader
* dbSetImageColorkey -> dbSetImageChromaKey
* dbSetStaticPortalsOff -> dbHideStaticPortals
* dbSetStaticPortalsOn -> dbShowStaticPortals
* dbSoundExist -> dbIsSound
* dbSpriteExist -> dbIsSprite
* dbTerrainExist -> dbIsTerrain
* dbUnlockBuffer -> dbUnlockVertexBuffer
* dbVertexShaderExist -> dbIsVertexShader
* dbChangeMeshFromMemblock -> dbReplaceMeshWithMemblock
- Reordered parameters to support automatic ID allocation
* dbCloneObject(ObjectCloneID, SourceID, SharedDataFlag) -> (SourceID, ObjectCloneID, SharedDataFlag)
* dbCopyMemblock(SourceID, MemblockID, SourceStartPos, DestinationStartPos, Length) -> (SourceStartPos, DestinationStartPos, Length, SourceID, MemblockID)
* dbCreateAnimatedSprite(SpriteID, FileName.s, Across, Down, ImageID) -> (FileName.s, Across, Down, ImageID, SpriteID)
* dbCreateBasicEmitter(EmitterID, ParticleCount) -> (ParticleCount, EmitterID)
* dbCreateBitmap(BitmapID, Width, Height) -> (Width, Height, BitmapID)
* dbCreateBitmapFromMemblock(BitmapID, MemblockID) -> dbCreateBitmapFromMemblock(MemblockID, BitmapID)
* dbCreateBoxEmitter(EmitterID, ParticleCount) -> (ParticleCount, EmitterID)
* dbCreateFireParticles(ParticleID, ImageID, Frequency, x.f, y.f, z.f, Width.f, Height.f, Depth.f) -> (ImageID, Frequency, x.f, y.f, z.f, Width.f, Height.f, Depth.f, ParticleID)
* dbCreateImageFromMemblock(ImageID, MemblockID) -> dbCreateBitmapFromMemblock(MemblockID, ImageID)
* dbCreateMatrix(MatrixID, Width.f, Depth.f, xSegments, zSegments) -> (Width.f, Depth.f, xSegments, zSegments, MatrixID)
* dbCreateMemblock(MemblockID, Size) -> (Size, MemblockID)
* dbCreateMemblockFromBitmap(MemblockID, BitmapID) -> (BitmapID, MemblockID)
* dbCreateMemblockFromImage(MemblockID, ImageID) -> (ImageID, MemblockID)
* dbCreateMemblockFromMesh(MemblockID, MeshID) -> (MeshID, MemblockID)
* dbCreateMemblockFromSound(MemblockID, SoundID) -> (SoundID, MemblockID)
* dbCreateMeshFromMemblock(MeshID, MemblockID) -> dbCreateBitmapFromMemblock(MemblockID, MeshID)
* dbCreateMeshFromObject(MeshID, ObjectID) -> (ObjectID, MeshID)
* dbCreateObject(ObjectID, MeshIndex, ImageID) -> (MeshIndex, ImageID, ObjectID)
* dbCreateObjectBox(ObjectID, Width.f, Height.f, Depth.f) -> (Width.f, Height.f, Depth.f, ObjectID)
* dbCreateObjectCone(ObjectID, Size.f) -> (Size.f, ObjectID)
* dbCreateObjectCube(ObjectID, Size.f) -> (Size.f, ObjectID)
* dbCreateObjectCylinder(ObjectID, Size.f) -> (Size.f, ObjectID)
* dbCreateObjectFromLimb(ObjectID, NewObjectID, LimbID, CopyAllFlag) -> (ObjectID, LimbID, CopyAllFlag, NewObjectID)
* dbCreateObjectPlane(ObjectID, Width.f, Height.f, Orientation) -> (Width.f, Height.f, Orientation, ObjectID)
* dbCreateObjectSphere(ObjectID, Size.f, Rows, Columns) -> (Size.f, Rows, Columns, ObjectID)
* dbCreateObjectTriangle(ObjectID, x1, y1, z1, x2, y2, z2, x3, y3, z3) -> (x1, y1, z1, x2, y2, z2, x3, y3, z3, ObjectID)
* dbCreateParticles(ParticleID, ImageID, Frequency, Radius.f) -> (ImageID, Frequency, Radius.f, ParticleID)
* dbCreateSnowParticles(ParticleID, ImageID, Frequency, x.f, y.f, z.f, Width.f, Height.f, Depth.f) -> (ImageID, Frequency, x.f, y.f, z.f, Width.f, Height.f, Depth.f, ParticleID)
* dbCreateSoundFromMemblock(SoundID, MemblockID) -> dbCreateBitmapFromMemblock(MemblockID, SoundID)
* dbCreateSphericalEmitter(EmitterID, ParticleCount) -> (ParticleCount, EmitterID)
* dbCreateTerrain(TerrainID, HeightmapFileName.s) -> (HeightmapFileName.s, TerrainID)
* dbGetImage(ImageID, Left, Top, Right, Bottom, TextureFlag) -> (Left, Top, Right, Bottom, TextureFlag, ImageID)
* dbInstanceObject(ObjectID, SourceID) -> (SourceID, ObjectID)
* dbLoadEffect(FileName.s, EffectID, TextureFlag, DoNotGenerateExtraData) -> (FileName.s, TextureFlag, DoNotGenerateExtraData, EffectID)
* dbLoadEffect(FileName.s, EffectID, TextureFlag, DoNotGenerateExtraData) -> (FileName.s, TextureFlag, EffectID, DoNotGenerateExtraData)
* dbLoadImage(FileName.s, ImageID, TextureFlag) -> (FileName.s, TextureFlag, ImageID)
* dbLoadMesh(FileName.s, MeshID)
* dbLoadObject(FileName.s, ObjectID, TextureMode, TextureReduce) -> (FileName.s, TextureReduce, TextureMode, ObjectID)
* dbLoadPixelShader(FileName.s, PixelShaderID)
* dbLoadVertexShader(FileName.s, VertexShaderID)
* dbRecordSound(SoundID, Duration) -> (Duration, SoundID)
* dbReplaceMeshWithMemblock(MeshID, MemblockID) -> dbReplaceMeshWithMemblock(MemblockID, MeshID)
PureGDK 2.0 beta 6
------------------
Updates:
- Removed legacy code required to support syncing in previous versions of DBP. The DBP 7.7 release candidate is now REQUIRED to be installed BEFORE installing PureGDK. Sync will NOT work without it!
- Thread safety code is now disabled by default providing performance improvement of up to 20%. To reenable thread safety, pass the #kGDK_ThreadSafe flag to dbOpenScreen.
PureGDK 2.0 beta 5
------------------
Updates:
- Added an optional depth parameter to dbOpenScreen. If 0 is passed then it will default to the screen depth.
- Added dbSetDisplayMode. Somewhere it went missing in PureGDK 2.0 but it's back! If 0 is passed for the Depth parameter then it will default to the screen depth. If 0 is passed for the BackBufferWidth or BackBufferHeight parameter it will default to the specified width/height for the DBP screen resolution.
PureGDK 2.0 beta 4
------------------
Updates:
- Major changes to the PureGDK plugin SDK specification which are incompatible with previous beta SDK releases.
- Completed full support for DBP-compatible plugins. The library builder is now capable of handling multiple instances of functions of the same name but with different parameters. Code generation is entirely dependent on the plugin's implementation.
- Minor changes to the template specification and buildlibs.exe parsing routines.
PureGDK 2.0 beta 3
------------------
Bug fixes:
- gdkc.exe will now report an appropriate error if an illegal command is used to specify a plugin.
- Fix a bug where functions returning a string would cause the program to become unstable.
- Updated the following commands to work with DBP 7.5:
* dbAddMeshToBuffer
* dbDeleteMeshFromBuffer
* dbGetBufferIndexCount
* dbGetBufferVertexCount
* dbGetVertexDiffuse
* dbGetVertexNormalsX
* dbGetVertexNormalsY
* dbGetVertexNormalsZ
* dbGetVertexPositionX
* dbGetVertexPositionY
* dbGetVertexPositionZ
* dbGetVertexU
* dbGetVertexV
* dbLockVertexBufferForLimb
* dbLockVertexBufferForMesh
* dbSetBufferDiffuse
* dbSetBufferIndexData
* dbSetBufferNormals
* dbSetBufferPosition
* dbSetBufferUV
* dbUnlockBuffer
Updates:
- Renamed dbSetIndexData to dbSetBufferIndexData.
- Updated gdkc.exe to support unix-style command line parameters. See gdkc.exe --help for a list of options.
- Added the parameter "-all" to gdkc.exe to support compiling the engine with existing plugins which have been properly configured. This is now the default behavior invoked by the installer.
- Added preliminary support for plugins. This feature will be enhanced in a future version to properly address default parameters.
- Added PureBasic example projects for cloth and advanced terrain and some TGC plugins.
PureGDK 2.0 beta 2
------------------
Bug fixes:
- dbSetD3DDeviceCallback and all functions from the 3d math functions were using the wrong calling convention and corrupting the stack.
- Updated several templates which were passing the wrong type.
- Fixed dbSetEffectConstantVector, dbSetEffectConstantMatrix, dbSetVertexShaderVector, and dbSetVertexShaderMatrix which were not passing their vector and matrix parameters as expected.
- Fixed a memory leak for all functions which return a string.
- Fixed a bug where the beta can expire early if the computer spends a lot of time in hibernation.
Updates:
- Added a new C++ plugin to the library builder for header generation.
- Added C++ examples for make/g++, nmake/vc++, vs6, vs2002, vs2003, vs2005, vs2008, and vs2010.
- Added new supplemental typing to templates to add support for type strict languages like C++.
- Updated the library builder plugin specification. The new specification is incompatible with the one from beta 1.
- Added the command dbCloseScreen for instances where it is necessary to perform the cleanest possible program termination. Some compilers are less forgiving than others.
- Significantly increased the delay allowed for the engine to start up on slower processors.
Feature highlights:
All of DBP compressed down into a single DLL
Engine customization; basic 3D in less than 800 KB!
Future support is anticipated for additional programming languages.
Language agnostic interface; all exports are C function calls
Internal multithreading support. Go thread crazy!
Enhanced commands including true support for structured parameters
Potential support for rendering in a web browser
Rewritten, extremely fast 3D math library
Improved documentation for all DarkBasic Professional commands
Superior runtime error support that is thread-aware
Easy to use command line tools for automated compiling
Plugin-based parser. Adding support for your own language is a breeze!
Projects supported by PureGDK out of the box:
Visual Studio 2010
Visual Studio 2008
Visual Studio 2005
Visual Studio .NET 2003
Visual Studio .NET
Visual Studio 6
GNU make/GCC g++
Nmake/VC++
PureBasic 4
This list is not finite! PureGDK will "just work" with any standards-compliant C++ compiler. This includes any version of Visual Studio Express, g++, Borland, Watcom, Intel, Comeau, etc.
The new engine is extremely lightweight and highly customizable. And best of all, it's fully compatible with DBP's plugins. Now you can enjoy the power of DarkBasic Professional from your favorite language. And if you have multiple favorites-- no problem!
Program using your favorite IDE. Any IDE. Any language!
PureGDK: Project Setup in Visual Studio 2008
Screenshot of PureGDK and the PureBasic IDE:
Screenshot of PureGDK and the Qt Creator C++ IDE:
Here is a video of a C++ example project being run and debugged from the Qt Creator IDE. It also demos the flexibility of PureGDK by compiling from a UNIX (cygwin) command line using Make and the GNU g++ compiler. It should work with most any C/C++ compiler.
http://puregdk.com/files/upload/TGCForum/pgdk_cpp_demo_xvid.avi
Brand new language-specific documentation!
Here is a screenshot of the DarkGDK documentation for a comparison:
The documentation is in the excellent .chm format with an index and full text search.
All source code and templates for the documentation builder will be available in the SDK for you to help extend the existing docs and also for you to apply to your own projects if you like.
Many of the commands have been renamed for clarity and others have had their parameters reordered to support default parameters and function polymorphism.
Here is an example of a function which will have its parameters reordered for automatic ID allocation:
Quote: "
dbLoadSound(string fileName [, int soundID])"
The "soundID" parameter is optional and therefore appears at the end of the function. If no ID is specified, one will be returned as the result.
For functions which take advantage of default parameters, the header might look like this:
Quote: "
dbLoadSound(string fileName, int soundID = -1)"
And for others which use function polymorphism, for example:
Quote: "
dbLoadSound(string fileName)
dbLoadSound(string fileName, int soundID)"
Another example where a command might be different is "dbSetDisplayMode".
In DarkGDK you can use these commands to change the resolution:
Quote: "
void dbSetDisplayMode (int iWidth, int iHeight, int iDepth)
bool dbSetDisplayModeEx(int iWidth, int iHeight)
bool dbSetDisplayModeEx(int iWidth, int iHeight, int iDepth)
bool dbSetDisplayModeEx(int iWidth, int iHeight, int iDepth, int iMode)
bool dbSetDisplayModeEx(int iWidth, int iHeight, int iDepth, int iMode, int iVertexProcessing)
bool dbSetDisplayModeEx(int iWidth, int iHeight, int iDepth, int iMode, int iVertexProcessing, int iLockable)
bool dbSetDisplayModeVSync(int iWidth, int iHeight, int iDepth, int iVSyncOn)
bool dbSetDisplayModeAntialias (int iWidth, int iHeight, int iDepth, int iVSyncOn, int iMultisamplingFactor, int iMultimonitorMode)"
In PureGDK the same command with optional parameters is:
Quote: "
dbSetDisplayMode(int width, int height[, int depth [, int vSync [, int multiSampling [, int multiMonitor [, int backBufferWidth [, int backBufferHeight [, int vrMode]]]]]]])"
In this function each parameter after width and height can be optionally specified.
PureGDK has built-in support for multithreading by providing function-level critical sections for your convenience behind the scenes as well as thread-aware error handling. Each function can have several possible error codes which can be detected are caught at runtime for you to examine and respond to.
For example, dbMakeMatrix() can throw any of the following errors for you to catch with dbGetLastError():
Quote: "
kGDK_Error_3D_Matrix_ID_Invalid
kGDK_Error_3D_Matrix_Exists
kGDK_Error_3D_Matrix_Segment_Invalid
kGDK_Error_3D_Matrix_Dimension_Invalid
kGDK_Error_3D_Matrix_Too_Large"
dbGetLastError() will return the last error to occur in the current thread. It can safely and accurately be used across multiple threads.
Never have to use a vector or matrix "ID" again! PureGDK supports vector and matrix datatypes as structures. This means that you can access any part of this data and they can be written to and read from memory:
// Declare variables with pre-defined structures
Vector2 Vector2a;
Vector2 Vector2b;
Vector2 Vector2Result;
// Set vector data
Vector2a.x = 3;
Vector2b.x = 7;
Vector2a.y = 5;
Vector2b.y = 5;
// Add vectors together
dbAddVector2(&Vector2Result, &Vector2a, &Vector2b);
// Output results
cout << Vector2Result.x << endl; // 3 + 7 = 10
cout << Vector2Result.y << endl; // 5 + 5 = 10
How to write a library builder plugin for your language:
The library builder (buildlibs.exe) tool handles all of the template parsing for you and will automatically compile headers for any language which has a plugin to generate it.
Command line parameters for buildlibs.exe are:
Compile language-specific header files from pre-generated templates. These
header files contain function definitions for every command supported by PureGDK
and associated plugins.
Usage: buildlibs file -plugin <plugin> [options]
Options:
--help Display this information.
--help-plugins Display help information for all plugins.
--ext-header <arg> Set the output extension of the output header file.
--ext-lib <arg> Set the output extension of the output library file.
--header <file> The file name of the primary header file. All header
files created by this tool will be appended to it.
--lcasefile Set the output file name to lower-case.
-o <file/path> Specifies the location and/or name of the header file
to be written to disk. If no file is specified then the
base name will be used.
-q Disable all text output at the command line.
--plugin <plugin> Load a specific plugin for the target language
--plugin-args <arg> Passes a string of additional command line switches to
the plugin for additional processing.
--prefix-header <arg> Set the output prefix of the output header file.
--prefix-lib <arg> Set the output prefix of the output library file.
-v <detail|docs> Specifies additional verbosity for the command line
output. By specifying 'detail', the function name and
its parameters will be displayed. The 'docs' option
will format the output specifically to be parsed by the
documentation builder.
Here is the source code for gdk_purebasic.dll. This plugin has been written in C++. The code should be fairly easy to read but I'll be happy to answer any questions you may have. The "Version 1" specification may change between now and the final release:
Version 1 Plugin Specification:
#ifndef _LIBBUILDER_H
#define _LIBBUILDER_H
#ifdef _MSC_VER
#include <windows.h>
typedef __int32 int32_t;
typedef unsigned __int32 uint32_t;
typedef __int64 int64_t;
typedef unsigned __int32 uint64_t;
#else
#include <stdint.h>
#endif
namespace LibBuilder {
const int32_t kVersion1 = 1;
const int32_t kVersion2 = 2;
const int32_t kVersion3 = 4;
const int32_t kPlugin_Flags_LoadPtr = 1;
const int32_t kPlugin_Flags_Camera = 2;
const int32_t kPlugin_Flags_NoSafeCall = 4;
const int32_t kPlugin_Flags_NoDefaultOverride = 8;
const int32_t kType_Integer = 1;
const int32_t kType_Long = 2;
const int32_t kType_Float = 4;
const int32_t kType_String = 8;
const int32_t kType_Double = 16;
const int32_t kType_Quad = 32;
const int32_t kType_Char = 64;
const int32_t kType_Byte = 128;
const int32_t kType_Word = 256;
const int32_t kType_Pointer = 512;
const int32_t kType_Hex = 1024;
const int32_t kVerbose_Detail = 1;
const int32_t kVerbose_Docs = 2;
// Global structure
struct Glob_LibPlugin {
string programFileName;
};
class Version1 {
public:
struct Command {
struct Element {
int32_t lineNumber;
char* paramString;
char* rParamType;
char* exportName;
char* paramList;
char* paramListAlt;
char* findFreeParam;
char* findFreeType;
char* dllName;
char* flags;
};
char* name;
int32_t elementCount;
LibBuilder::Version1::Command::Element **elements;
};
struct Constant {
int32_t lineNumber;
char* name;
char* value;
int32_t type;
};
struct Structure {
struct Element {
char* name;
int32_t type;
};
int32_t lineNumber;
char* name;
int32_t elementCount;
LibBuilder::Version1::Structure::Element **elements;
};
struct Return {
char* library;
char* header;
char* include;
char* prefixHeader;
char* prefixLib;
char* extHeader;
char* extLib;
};
int32_t version;
char* fileName;
int32_t verbose;
int32_t constantCount;
int32_t structCount;
int32_t commandCount;
LibBuilder::Version1::Constant **constants;
LibBuilder::Version1::Structure **structures;
LibBuilder::Version1::Command **commands;
};
}
#endif /* _LIBBUILDER_H */
How to run the examples:
The PureGDK installer should automatically generate header files as well as build a complete engine .dll from all of the DarkBasic Professional core libraries. If you need to generate these files again, there are batch files to automate the process in the PureGDK install directory.
If you cannot run the examples for some reason, try to generate the headers and the engine .dll again using these batch files. If they do not report a success then please submit a report on this board as a bug.
All examples located in the install directory under the examples folder should compile out of the box without modification.
One major difference you must be aware of is that PureGDK does NOT use "DarkGDK()/LoopGDK()". It can use whatever entry point you want, be it main(), WinMain(), _tWinMain(), etc:
#include <puregdk.h>
#include <initPureGDK.h>
#include <simpleWindow.h>
int __stdcall WinMain(HINSTANCE, HINSTANCE, LPSTR, int) {
HWND hWnd;
If (!initPureGDK("gdkengine.dll"))
Return 1;
hWnd = OpenWindow(0, 0, 640, 480, "DarkBasic Professional - PureGDK",
WS_OVERLAPPED | WS_CLIPSIBLINGS | WS_CAPTION | WS_SYSMENU |
WS_CLIPCHILDREN, true);
dbOpenScreen(hWnd, 0, 0, 640, 480);
ShowWindow(hWnd, SW_SHOW);
// Set the current directory
SetCurrentDirectory("media1");
..
return 0;
}
Unlike DBP and DarkGDK, in PureGDK, the renderable area is separate from the actual window. As you can see from this example code, dbOpenScreen accepts a target window handle "hWnd" which tells it where to render the output. This allows PureGDK to render to "any" window owned by the process and is not limited to any one implementation.
For example, you can use PureGDK with GLUT, Qt, Win32, wxWidgets, etc.
There are a lot of changes compared to DBP/DarkGDK. It is not targeted as being 1:1 compatible with DarkGDK and there will be growing pains while you encounter the differences. However, the idea behind PureGDK is to bring evolution to the engine to streamline it and in the end make it easier to use as well as being portable to other languages.
Don't forget! PureGDK is also compatible with all DarkBasic Professional plugins and includes many headers to provide support out-of-the-box. An SDK is also provided which allows anyone to add support for additional languages!!
PureGDK is designed such that whenever you decide to move to a different language, you can take the engine with you. You could say that compared to DarkGDK, that's even revolutionary!