Renderer
Description
The Renderer app extends the VRNativeApplication by demonstrating how to render a simple coordinate system into VR. This visual representation helps in understanding spatial orientation in VR environments.
Within the onFramebufferInitialized()
function, a 3D coordinate system is established. The scene remains static, meaning its appearance does not change over time. Optionally, the app also demonstrates how to integrate a custom render call, for instance, utilizing a third-party rendering engine. This feature provides flexibility for developers looking to customize the rendering process according to specific requirements or to leverage advanced rendering technologies.
Use this app as a foundational template for developing lightweight VR applications with minimal dependencies. It offers a streamlined approach for those looking to create efficient and straightforward VR experiences.
Building
- Quest
The following instructions are for macOS but can be easily converted to other host operating systems. First, ensure that the
have been completed. And that the third-party libraries have been built according to these instructions.
Then run the following steps:
# Define environment variables required for Android and Quest apps as per setup instructions above:
# ANDROID_HOME, ANDROID_NDK, ANDROID_NDK_VERSION, JAVA_HOME, and OVRPlatformSDK_ROOT
# Adjust this to your location of the third-party libraries
export OCEAN_THIRDPARTY_PATH="${HOME}/install_ocean_thirdparty"
cd ${OCEAN_DEVELOPMENT_PATH}/build/gradle/application/ocean/demo/platform/meta/quest/openxr/renderer/quest
./gradlew assemble
# Install debug build of the app
adb install app/build/outputs/apk/debug/app-debug.apk
# Install release build of the app
adb install app/build/outputs/apk/release/app-release.apk
Features
- Coordinate System Visualization: Displays the Quest's world coordinate system with 1-meter long axes in front of the user. Each axis has an own color (red for x-axis, green for y-axis, blue for z-axis).
- Custom OpenGL ES Engine Integration: Demonstrates how a custom OpenGL ES engine could be integrated into the rendering pipeline (disabled by default).
Usage
- Immediate Visual Representation: Unlike the previous apps, this app provides immediate visual feedback by displaying the coordinate system upon app start.