Content Creation Tutorial

NameLocation
Content Creation<Vortex Studio Installation Folder>\tutorials\ExContentCreation

This tutorial provides an example to create content with code. 

In this tutorial, a rover is built, is connected to a joystick, and rolls on a plane.

It showcases the following

  • Assembly Document
    • Parts and collision geometry creation
    • Assembling with constraint
    • Materials between the wheels and ground
  • Graphics Gallery Document
    • Import graphics from a graphics file
  • Assembly with Graphics
    • Adding a Gallery instance
    • Creating parts from a node
    • Part-node mapping
    • Creating collision geometries from graphics
  • Mechanism Document
    • Adds controls of the Assembly via
      • VHL Interface
      • Joystick
      • Python script
      • Connection Container
    • Configuration
      • Add an option to have a "Turbo mode" to the rover
  • Scene Document
    • Instantiate 9 Rovers in a 3x3 grid
    • Activate the Turbo configuration for some rovers
    • Adds Configuration to control the amount of rover visible in the scene.
    • Adds a material table
    • Adds an assembly instance as an obstacle

See Vortex Studio SDK - Creating Content for more details.

Using the tutorial

  1. Open Tutorials solution
  2. Set ExContentCreation as the active project.
  3. Compile the project.
  4. The code is fully documented explaining each steps.
  5. Run the executable with the following arguments:
    1. --destinationFolder <folder>: this is the folder where to save the scene, mechanism, gallery, and assembly documents
    2. --pythonScript <path>: This is the python script path used by the rover controller. It is located at <Vortex Studio Installation Folder>\resouces\ExContentCreation\controller.py
      1. For convenience, the python 2 version of the same script is provided <Vortex Studio Installation Folder>\resouces\ExContentCreation\rovercontroller.py
    3. --materialsPath <materials>: Path to the Material table. One is provided at <Vortex Studio Installation Folder>\resouces\ExContentCreation\default.vxmaterials
      1. The table must contain a material named "Ground" and another named "Wheel".
    4. --graphicsPath <graphics>: Path to the dump truck graphics file. It is located at <Vortex Studio Installation Folder>\resouces\ExContentCreation\dumptruck.ive
      1. The file is imported into a gallery, then into an assembly where it is mapped to parts.
  6. In the destination folder, you will have the vortex file created by the executable.
    1. Open them in the editor to try them. There is almost no graphics so you will need to enable Geometry visualization.
  7. To go into detail, debug the project and follow the code execution step by step.



Command Line Example

Here is an example of the Command to type into the Terminal to execute step #5.
(Take note that Paths may have to be changed in order to match your directories)

runExContentCreation.bat --destinationFolder "C:/TemporaryFolder/" --pythonScriptPath "C:/CM Labs/Vortex Studio 2021a/tutorials/Resources/ExContentCreation/controller.py" --materialsPath "C:/CM Labs/Vortex Studio 2021a/tutorials/Resources/ExContentCreation/default.vxmaterials" --graphicsPath "C:/CM Labs/Vortex Studio 2021a/tutorials/Resources/ExContentCreation/dumptruck.ive"