Initial FrameAssistant baseline from the vrdashboard template

Template stripped to the overlay platform (examples, demo UI and Frame
test package removed), renamed to FrameAssistant, and working rules for
the project recorded in CLAUDE.md.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-05 00:06:58 +02:00
co-authored by Claude Opus 5.5
commit 4a5b09053e
63 changed files with 5193 additions and 0 deletions
+69
View File
@@ -0,0 +1,69 @@
configure_file(AppConfig.h.in ${CMAKE_CURRENT_BINARY_DIR}/generated/AppConfig.h @ONLY)
# Everything except main() lives in a static library: the dashboard executables and
# the tests link against it.
qt_add_library(vrdashboard_core STATIC
app/DashboardApplication.h app/DashboardApplication.cpp
app/Surface.h app/Surface.cpp
vr/Overlay.h vr/Overlay.cpp
render/RenderBackend.h render/RenderBackend.cpp
render/OpenGLRenderBackend.h render/OpenGLRenderBackend.cpp
render/OffscreenQuickRenderer.h render/OffscreenQuickRenderer.cpp
vr/VrRuntime.h vr/VrRuntime.cpp
vr/DashboardOverlay.h vr/DashboardOverlay.cpp
input/OverlayInputBridge.h input/OverlayInputBridge.cpp
input/ControllerNavigation.h input/ControllerNavigation.cpp
)
target_include_directories(vrdashboard_core PUBLIC
${CMAKE_CURRENT_SOURCE_DIR}
${CMAKE_CURRENT_BINARY_DIR}/generated)
target_link_libraries(vrdashboard_core PUBLIC
Qt6::Core Qt6::Gui Qt6::OpenGL Qt6::Qml Qt6::Quick Qt6::QuickControls2
OpenVR::OpenVR)
target_compile_options(vrdashboard_core PRIVATE -Wall -Wextra)
# Optional Vulkan backend: needs the Vulkan headers and a Qt built with Vulkan support.
if(VRDASH_VULKAN STREQUAL "AUTO")
find_package(Vulkan QUIET)
set(_vulkan_ok FALSE)
if(TARGET Vulkan::Headers AND QT_FEATURE_vulkan)
set(_vulkan_ok TRUE)
endif()
elseif(VRDASH_VULKAN)
find_package(Vulkan REQUIRED)
if(NOT QT_FEATURE_vulkan)
message(FATAL_ERROR "VRDASH_VULKAN=ON but Qt was built without Vulkan support")
endif()
set(_vulkan_ok TRUE)
else()
set(_vulkan_ok FALSE)
endif()
if(_vulkan_ok)
target_sources(vrdashboard_core PRIVATE
render/VulkanRenderBackend.h render/VulkanRenderBackend.cpp)
# Headers only: Qt loads libvulkan at runtime, nothing links against it.
target_link_libraries(vrdashboard_core PUBLIC Vulkan::Headers)
target_compile_definitions(vrdashboard_core PUBLIC VRDASH_HAS_VULKAN=1)
else()
target_compile_definitions(vrdashboard_core PUBLIC VRDASH_HAS_VULKAN=0)
endif()
message(STATUS "Vulkan backend: ${_vulkan_ok}")
# The app: its UI is the QML module "FrameAssistant" (src/qml/).
vrdash_add_dashboard(frameassistant
OUTPUT_NAME ${VRDASH_EXECUTABLE_NAME}
QML_URI FrameAssistant
SOURCES main.cpp Dashboard.h Dashboard.cpp
QML_FILES
qml/Main.qml
qml/Card.qml)
install(FILES ${OPENVR_LIBRARY} DESTINATION ${CMAKE_INSTALL_LIBDIR})
# Licenses: ours, the overview of third-party components, OpenVR's.
install(FILES ${PROJECT_SOURCE_DIR}/LICENSE ${PROJECT_SOURCE_DIR}/THIRD_PARTY_NOTICES.md
DESTINATION ${CMAKE_INSTALL_DOCDIR})
if(EXISTS ${OPENVR_LICENSE})
install(FILES ${OPENVR_LICENSE} DESTINATION ${CMAKE_INSTALL_DOCDIR}/third-party
RENAME openvr.LICENSE)
endif()