Run the DirectX Sample
This section walks you through how to set up and run the DirectX Sample on a local environment. Seeing how it works will help you understand how we integrate the SDK with this application and what you need to do with your own project.
The Cube Sample displays 3 cubes named Athos, Porthos, and Aramis. The cubes rotate and move in different fixed directions. When a cube reaches an edge, it moves to the opposite side of the world to continue its movement without interruption. The player controls one cube at a time using these controls:
- The arrow and W A S D keys change the trajectory of the selected cube.
Modifying the direction also affects the rotation of the object.
The 1, 2, and 3 keys select different cubes.
The numeric keypad keys change the selected cube’s color.
The 0 key resets the orientation of the selected cube.
The P key resets the position of the selected cube.
The Backspace key stops the cube from moving.
Clean and load the project configuration.
genvid-sdk setup # Make sure the local cluster is created. genvid-sdk clean-config # Clean old config in case of existing cluster. genvid-sdk load-config-sdk # Configure the basic services for the SDK.
Go to the
Generate and load the cube web sample to be able to view the streaming session.
py web.py build py web.py load
Go to the
Copy the Genvid files used to build the project.
py directx.py prepare
Build the project and the website.
py directx.py build
Load the DirectX configuration.
py directx.py load
Launch the Cluster UI.
Click the Jobs tab.
Click START ALL.
This starts the following jobs:
You can also start the services individually.
The links become active after the job status changes to
Click CUBE SAMPLE in the Links section to launch the website.
When finished, click STOP ALL to stop all the services.