SpeedTree
    Show / Hide Table of Contents

    Introduction to the reference application

    The purpose of the reference application is to provide an example of how to use the SpeedTree Runtime SDK.

    All source files prefixed with "My" indicate an example implementation meant to detail what an application might (and, in a lot of cases, should) do when interfacing with the SpeedTree Runtime SDK. These files constitute the bulk of the reference application and are not part of the official Runtime SDK; they are merely examples or "reference" implementations.

    Most of the code in the reference application is dedicated to feeding the following data to the Runtime SDK:

    • Forest population, both random and by .stf files

    • Terrain population via an example height map class

    • Grass population using a procedural system

    The other main parts of the reference application are as follows:

    • The actual render loop

    • Mouse, keyboard, and gamepad controls

    • Gathering and printing rendering statistics

    • Extracting the user configuration from the given .sfc (SpeedTree Forest Configuration) file (which has a considerable number of options) and passing them into the Runtime SDK. Example .sfc files are shown in the Reference App Launcher application (screenshot below, executable is at [SDK]/SDK/Bin/Reference Application Launcher.exe). The .sfc syntax is not part of the Runtime SDK, but a handy mini-language our developers use to build example forests. Runtime SDK users can use it for experimentation and running their own art assets through the reference application.

    In the figure below, the reference application serves as an example of one of the blue application boxes.

    Note

    To execute the reference application in Linux, refer to the Linux version's instructions.

    Copyright © 2023 Unity Technologies
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX.