User Tools

Site Tools

Version 5.0 Final

Release Note

This is the final 5.0 for-production release of the SpeedTree SDK.

General Notes

  • Support for DirectX 10 added. August 2009 SDK required.
  • Support for Xbox 360 added, built against the June 2009 XDK.
  • PLAYSTATION3 support is not part of this release and will be added in the next version.
  • This is the first SDK release to work with Unreal Engine 3 (integration must be acquired from Epic).
  • OpenGL version requires OpenGL 2.0 or higher.
  • There is a Cg bug that causes the grass to render white when SPEEDTREE_TERRAIN_MATCHING_IN_VERTEX is #defined in Grass.fx. The bug was reported and acknowledge by NVIDIA.
  • There is an NVIDIA driver bug, starting with 190.38, that will sometimes cause grass and billboards to not render. The bug was reported and acknowledge by NVIDIA and should be fixed by the latest drivers publicly available by the time of this release.
  • All libraries were compiled and tested under Intel's Parallel Studio compiler under Windows, however Visual Studio-compiled binaries were shipped with the SDK. Intel Compiler binaries, measurably faster in culling & on-the-fly population functions, are available upon request to evaluators.
  • All uses of the macros min()/max()/min()/max() were replaced with templated functions st_min() and st_max() throughout the SDK and reference applications.
  • Libraries were compiled with gcc 4.1.1 which uncovered a number of non-portable areas, particularly with templates and protected inheritance in the container classes.
  • There are known issues with running the reference application on Windows 7.

Core Library

  • SCollisionObject user data member variable switch from CFixedString to char[].
  • CCore::SSupportingData and associated functions added for UE3 engine integration purposes.
  • Moved SPEEDTREE_WORLD_TRANSLATE definition from Core.h to ForestRI.h. It is undefined by default. Defining it helps increase depth buffer resolution when dealing with large world coordinates.
  • Stripped the remaining exceptions from Memory.h. There are no exceptions used throughout the SDK.
  • One of the code paths in CMap::erase() was copying both the key and value. This has been optimized to no longer happen.

Forest Library

  • Fix numerous culling and population issues related to dynamically populated forests, most commonly uncovered when the SDK was used in a world building environment. This was a sizeable collection of bug fixes and enhancements. The documentation detailing forest population was also supplemented.
  • Grass cull system would occasionally allow cell popping at the fade line.
  • Grass cull system was under-performing, rendering a lot of full-faded grass cells. With correction, 30-40% less grass geometry is drawn per frame, but due to the fill-bound nature of the grass system, it will shave only ~10% of the grass draw time, depending on the system.
  • CCellBaseTreeItr used internally to walk the forest population data structure. Its internal use is abstracted from the SDK user, but it will allow an easier transition to a more heap friendly version of the SDK in the next release.
  • SForestCullResults's member variable m_aNewlyActiveCells renamed to m_aCellsToPopulateWithBillboards.
  • Added instance-querying functions CForest::NumInstances() and CForest::GetInstances().
  • Added CForest::GetPopulationStats(). The reference application includes a sample usage.

CInstance::m_fRotation was not properly initialized. CForest::UnregisterTree() incorrectly deleted the tree that was passed to it. As CForest()::RegisterTree() does not allocate a tree object, CForest::UnregisterTree() does not delete the tree object.

Render Interface Library

  • Specular lighting for all 3D geometry was being incorrectly multiplied against the diffuse texture.
  • Horizontal billboard vertical offset factor not scaling correctly with instances.
  • Shored up 3D-to-billboard transitions under alpha testing by adding noise pattern lookup in pixel shaders. Active under alpha testing only.
  • Added support for grass matching the terrain on both the top and bottom of the grass blades (was previously top only).
  • Moved SPEEDTREE_WORLD_TRANSLATE definition from Core.h to ForestRI.h. It is undefined by default. Defining it helps increase depth buffer resolution when dealing with large world coordinates.
  • RenderTarget objects and files renamed to DepthTexture.
  • Some of the policy class and template parameters were expanded to facilitate the DirectX 10 port which required that more information be available at certain stages (e.g. the shader techniques have to be visible when creating the vertex buffers).
  • Not all of the templated policy class symbols were named consistently.
  • The sky is now rendered as a tessellated sphere instead of a box, and it is scaled to exist between the far clipping plane and the far fog distance. These changes allow the sky to be rendered after all other geometry, instead of needing to be rendered first.
  • Fog used to be based on screen depth, which would lead to artifacts due to the frustum. Now it is based on actual distance from the camera.
  • Added the CRenderStateOpenGL class to help with threading issues encountered when using openmp in the terrain and grass population code.
  • Grass billboard did not orient correctly for one of the alternate coordinate systems.
  • In TreeRI.inl, moved local SVertex structure definitions in the geometry initialization functions to file scope due to gcc not supporting local definitions. They were also renamed to prevent conflicts.
  • SPEEDTREE_MAX_BILLBOARD_IMAGES, used in Billboard.fx, is now defined at run-time based on the forest population instead of using a hard-coded value. If dynamic population will used, it may be best to set your own overriding value.
  • SpeedTree.fx reworked considerably to adapt to syntax needed for DirectX 10. Textures.fx was added to provide a number of texture declaration and lookup macros to abstract the compile target.
  • Overhauled Compile_Shaders.bat batch file to work with Cg, DX9, DX10, and Xbox 360.

Reference Application

  • Command-line option “-grass_terrain_match” now takes two parameters: <top> <bottom>. Previously it took top only.
  • CApplication class expanded to include functions to make it easier to control from an external class (mostly state toggling).
  • The OpenGL reference application now checks for OpenGL 2.0 or better and will exit if not found.