compiling and various updates

This commit is contained in:
ykeara
2025-10-09 18:45:53 -05:00
parent 44a05dfd57
commit 1152cfee1f
25 changed files with 542 additions and 297 deletions
+1 -1
View File
@@ -25,7 +25,7 @@ VrAlarm::VrAlarm()
ovr_overlay_wrapper::hideOverlay( m_alarmOverlayHandle );
// Only need to set it once, no need to keep it in memory
QImage alarmIcon( QString( ":/alarm/alarm_activated.png" ) );
QImage alarmIcon( ":qt/qml/AdvancedSettings/src/res/img/alarm/alarm_activated.png" );
ovr_overlay_wrapper::setOverlayFromQImage( m_alarmOverlayHandle,
alarmIcon );
+12 -6
View File
@@ -46,20 +46,25 @@ int main( int argc, char* argv[] )
openvr_init::initializeOpenVR(
openvr_init::OpenVrInitializationType::Overlay );
try
{
QQmlEngine qmlEngine;
// Just error checking to ensure QRC works properly
//qDebug() << "list of qmldirs";
//QDirIterator it( ":", QDirIterator::Subdirectories );
//while ( it.hasNext() )
//{
// qDebug() << it.next();
//}
std::unique_ptr<advsettings::OverlayController> controller(
new advsettings::OverlayController( commandLineArgs.desktopMode,
commandLineArgs.forceNoSound,
qmlEngine ) );
const auto url
= QUrl( "qrc:/qt/qml/AdvancedSettings/common/mainwidget.qml" );
QQmlComponent component( &qmlEngine, url );
//const auto url
// = QUrl( ":/qt/qml/AdvancedSettings/src/res/qml/common/mainwidget.qml" );
QQmlComponent component( &qmlEngine, ":/qt/qml/AdvancedSettings/src/res/qml/common/mainwidget.qml" );
auto errors = component.errors();
for ( auto& e : errors )
{
@@ -98,6 +103,7 @@ int main( int argc, char* argv[] )
|| settings::getSetting(
settings::BoolSetting::APPLICATION_desktopModeToggle ) )
{
qDebug() << "Desktop MODE!";
auto m_pWindow = new QQuickWindow();
qobject_cast<QQuickItem*>( quickObj )
->setParentItem( m_pWindow->contentItem() );
+14 -5
View File
@@ -77,13 +77,13 @@ OverlayController::OverlayController( bool desktopMode,
qInfo() << "VR Runtime Path: " << m_runtimePathUrl.toLocalFile();
const double initVol = soundVolume();
m_activationSoundEffect.setSource( QUrl( "qrc:/sounds/click.wav" ) );
m_activationSoundEffect.setSource( QUrl( ":/qt/qml/AdvancedSettings/src/res/sounds/click.wav" ) );
m_activationSoundEffect.setVolume( initVol );
m_focusChangedSoundEffect.setSource( QUrl( "qrc:/sounds/focus.wav" ) );
m_focusChangedSoundEffect.setSource( QUrl( ":/qt/qml/AdvancedSettings/src/res/sounds/focus.wav" ) );
m_focusChangedSoundEffect.setVolume( initVol );
m_alarm01SoundEffect.setSource( QUrl( "qrc:/sounds/alarm01.wav" ) );
m_alarm01SoundEffect.setSource( QUrl( ":/qt/qml/AdvancedSettings/src/res/sounds/alarm01.wav" ) );
m_alarm01SoundEffect.setVolume( 1.0 );
// If we have desktop mode flag ignore waht toggle says otherwise we use
@@ -362,6 +362,7 @@ void OverlayController::SetWidget( QQuickItem* quickItem,
{
if ( !m_desktopMode )
{
qDebug() << "not desktop mode";
vr::VROverlayError overlayError
= vr::VROverlay()->CreateDashboardOverlay(
key.c_str(),
@@ -390,7 +391,7 @@ void OverlayController::SetWidget( QQuickItem* quickItem,
true );
{
QImage thumbiconImg( QString( ":/icons/thumbicon.png" ) );
QImage thumbiconImg( ":qt/qml/AdvancedSettings/src/res/img/icons/thumbicon.png");
ovr_overlay_wrapper::setOverlayFromQImage(
m_ulOverlayThumbnailHandle, thumbiconImg );
}
@@ -422,7 +423,6 @@ void OverlayController::SetWidget( QQuickItem* quickItem,
if ( !m_renderControl.initialize() )
throw std::runtime_error( "could not initialize m_renderControl" );
QRhi* rhi = this->rhi();
qInfo() << "Started with" << rhi->backendName();
@@ -533,6 +533,15 @@ void OverlayController::SetOverlayFromQRhiTexture( QRhiTexture& tex )
vrTex.eColorSpace = vr::ColorSpace_Auto;
}
break;
case QRhi::D3D11:
{
qInfo() << "YEPPPERS HERE WE GO!";
vrTex.handle = reinterpret_cast<void*>( tex.nativeTexture().object );
vrTex.eType = vr::TextureType_DirectX;
vrTex.eColorSpace = vr::ColorSpace_Auto;
}
break;
#if QT_CONFIG( vulkan )
case QRhi::Vulkan:
{
+16 -17
View File
@@ -1,7 +1,7 @@
import QtQuick 2.7
import QtQuick.Controls 2.0
import QtQuick.Layouts 1.3
import ovras.advsettings 1.0
import QtQuick
import QtQuick.Controls
import QtQuick.Layouts
import ovras.advsettings
import "." // QTBUG-34418, singletons require explicit import to load qmldir file
import "common"
import "utilities_page"
@@ -33,7 +33,7 @@ MyStackViewPage {
text: " SteamVR"
Layout.fillWidth: true
onClicked: {
MyResources.playFocusChangedSound()
OverlayController.playFocusChangedSound()
mainView.push(steamVRPage)
}
}
@@ -45,7 +45,7 @@ MyStackViewPage {
text: " Chaperone"
Layout.fillWidth: true
onClicked: {
MyResources.playFocusChangedSound()
OverlayController.playFocusChangedSound()
mainView.push(chaperonePage)
}
}
@@ -57,7 +57,7 @@ MyStackViewPage {
text: " Offsets"
Layout.fillWidth: true
onClicked: {
MyResources.playFocusChangedSound()
OverlayController.playFocusChangedSound()
mainView.push(playspacePage)
}
}
@@ -69,7 +69,7 @@ MyStackViewPage {
text: " Motion"
Layout.fillWidth: true
onClicked: {
MyResources.playFocusChangedSound()
OverlayController.playFocusChangedSound()
mainView.push(motionPage)
}
}
@@ -80,7 +80,7 @@ MyStackViewPage {
text: " Rotation"
Layout.fillWidth: true
onClicked: {
MyResources.playFocusChangedSound()
OverlayController.playFocusChangedSound()
mainView.push(rotationPage)
}
}
@@ -92,7 +92,7 @@ MyStackViewPage {
text: " Space Fix"
Layout.fillWidth: true
onClicked: {
MyResources.playFocusChangedSound()
OverlayController.playFocusChangedSound()
mainView.push(fixFloorPage)
}
}
@@ -104,7 +104,7 @@ MyStackViewPage {
text: " Audio"
Layout.fillWidth: true
onClicked: {
MyResources.playFocusChangedSound()
OverlayController.playFocusChangedSound()
mainView.push(audioPage)
}
}
@@ -116,7 +116,7 @@ MyStackViewPage {
text: " Video"
Layout.fillWidth: true
onClicked: {
MyResources.playFocusChangedSound()
OverlayController.playFocusChangedSound()
mainView.push(videoPage)
}
}
@@ -128,7 +128,7 @@ MyStackViewPage {
text: " Utilities"
Layout.fillWidth: true
onClicked: {
MyResources.playFocusChangedSound()
OverlayController.playFocusChangedSound()
mainView.push(utilitiesPage)
}
}
@@ -141,7 +141,7 @@ MyStackViewPage {
text: " Statistics"
Layout.fillWidth: true
onClicked: {
MyResources.playFocusChangedSound()
OverlayController.playFocusChangedSound()
mainView.push(statisticsPage)
}
}
@@ -169,7 +169,7 @@ MyStackViewPage {
text: " Settings"
Layout.fillWidth: true
onClicked: {
MyResources.playFocusChangedSound()
OverlayController.playFocusChangedSound()
mainView.push(settingsPage)
}
}
@@ -470,9 +470,8 @@ MyStackViewPage {
summaryMicMuteToggle.checked = AudioTabController.micMuted
summaryPttToggle.checked = AudioTabController.pttEnabled
}
Connections {
target: OverlayController
target: OverlayController
function onNewVersionDetectedChanged() {
if (OverlayController.newVersionDetected)
{
+2 -2
View File
@@ -494,7 +494,7 @@ MyStackViewPage {
text: "Proximity Warning Settings"
Layout.preferredWidth: 350
onClicked: {
MyResources.playFocusChangedSound()
OverlayController.playFocusChangedSound()
mainView.push(chaperoneWarningsPage)
}
}
@@ -506,7 +506,7 @@ MyStackViewPage {
Layout.preferredWidth: 400
onClicked: {
MyResources.playFocusChangedSound()
OverlayController.playFocusChangedSound()
mainView.push(chaperoneAdditionalPage)
}
}
@@ -40,7 +40,7 @@ GroupBox {
Layout.preferredWidth: 200
onCheckedChanged: {
if(checked){
MyResources.playActivationSound()
OverlayController.playActivationSound()
ChaperoneTabController.setCollisionBoundStyle(0)
}
}
@@ -52,7 +52,7 @@ GroupBox {
Layout.preferredWidth: 200
onCheckedChanged: {
if(checked){
MyResources.playActivationSound()
OverlayController.playActivationSound()
ChaperoneTabController.setCollisionBoundStyle(1)
}
}
@@ -64,7 +64,7 @@ GroupBox {
Layout.preferredWidth: 200
onCheckedChanged: {
if(checked){
MyResources.playActivationSound()
OverlayController.playActivationSound()
ChaperoneTabController.setCollisionBoundStyle(2)
}
}
@@ -76,7 +76,7 @@ GroupBox {
Layout.preferredWidth: 200
onCheckedChanged: {
if(checked){
MyResources.playActivationSound()
OverlayController.playActivationSound()
ChaperoneTabController.setCollisionBoundStyle(3)
}
}
@@ -88,7 +88,7 @@ GroupBox {
Layout.preferredWidth: 200
onCheckedChanged: {
if(checked){
MyResources.playActivationSound()
OverlayController.playActivationSound()
ChaperoneTabController.setCollisionBoundStyle(4)
}
}
@@ -124,4 +124,7 @@ GroupBox {
}
}
Connections {
target: OverlayController
}
}
+4 -1
View File
@@ -63,11 +63,14 @@ ComboBox {
onActivated: {
if (activeFocus) {
MyResources.playActivationSound()
OverlayController.playActivationSound()
}
}
Component.onCompleted: {
popup.background.color = "#2a2e35"
}
Connections {
target: OverlayController
}
}
+4 -1
View File
@@ -35,7 +35,10 @@ Button {
onClicked: {
if (activationSoundEnabled) {
MyResources.playActivationSound()
OverlayController.playActivationSound()
}
}
Connections {
target: OverlayController
}
}
+4 -1
View File
@@ -24,6 +24,9 @@ Button {
}
onClicked: {
MyResources.playActivationSound()
OverlayController.playActivationSound()
}
Connections {
target: OverlayController
}
}
+4 -1
View File
@@ -19,6 +19,9 @@ RadioButton {
}
onClicked: {
MyResources.playActivationSound()
OverlayController.playActivationSound()
}
Connections {
target: OverlayController
}
}
+3
View File
@@ -10,4 +10,7 @@ QtObject {
function playFocusChangedSound() {
OverlayController.playFocusChangedSound()
}
Connections {
target: OverlayController
}
}
+1 -1
View File
@@ -48,7 +48,7 @@ Slider {
onValueChanged: {
if (activeFocus) {
//MyResources.playActivationSound()
//OverlayController.playActivationSound()
}
}
}
+5 -2
View File
@@ -2,7 +2,7 @@ import QtQuick 2.7
import QtQuick.Controls 2.0
import QtQuick.Layouts 1.2
import "." // QTBUG-34418, singletons require explicit import to load qmldir file
// Needed for MyResources in the default folder.
// Needed for OverlayController in the default folder.
import ".."
Rectangle {
@@ -45,7 +45,7 @@ Rectangle {
}
}
onClicked: {
MyResources.playFocusChangedSound()
OverlayController.playFocusChangedSound()
stackView.pop()
}
}
@@ -90,4 +90,7 @@ Rectangle {
content.Layout.rightMargin = 40
content.Layout.bottomMargin = 40
}
Connections {
target: OverlayController
}
}
+5 -2
View File
@@ -1,7 +1,7 @@
import QtQuick 2.7
import QtQuick.Controls 2.0
import "." // QTBUG-34418, singletons require explicit import to load qmldir file
// Needed for MyResources in the default folder.
// Needed for OverlayControllers in the default folder.
import ".."
CheckBox {
@@ -60,6 +60,9 @@ CheckBox {
}
onClicked: {
MyResources.playActivationSound()
OverlayController.playActivationSound()
}
Connections {
target: OverlayController
}
}
+3 -3
View File
@@ -1,6 +1,6 @@
import QtQuick 2.7
import QtQuick.Controls 2.0
import QtQuick.Layouts 1.0
import QtQuick
import QtQuick.Controls
import QtQuick.Layouts
import ".."
import "../utilities_page"
import "../audio_page"
+4 -1
View File
@@ -32,7 +32,7 @@ MyStackViewPage {
Layout.preferredWidth: 350
onClicked: {
MyResources.playFocusChangedSound()
OverlayController.playFocusChangedSound()
mainView.push(steamVRTXRXPage)
SteamVRTabController.updateRXTXList()
}
@@ -50,4 +50,7 @@ MyStackViewPage {
}
}
}
Connections {
target: OverlayController
}
}
+75
View File
@@ -1,4 +1,79 @@
<RCC>
<qresource prefix="/qt">
<file>qml/ChaperoneWarningsPage.qml</file>
<file>qml/FixFloorPage.qml</file>
<file>qml/PlayspacePage.qml</file>
<file>qml/RootPage.qml</file>
<file>qml/SettingsPage.qml</file>
<file>qml/StatisticsPage.qml</file>
<file>qml/audio_page/AudioPage.qml</file>
<file>qml/audio_page/device_selector/AudioDeviceSelector.qml</file>
<file>qml/audio_page/device_selector/MicDeviceSelector.qml</file>
<file>qml/audio_page/device_selector/MicVolumeSlider.qml</file>
<file>qml/audio_page/device_selector/MirrorDeviceSelector.qml</file>
<file>qml/audio_page/device_selector/MirrorVolumeSlider.qml</file>
<file>qml/audio_page/dialog_boxes/AudioDeleteProfileDialog.qml</file>
<file>qml/audio_page/dialog_boxes/AudioMessageDialog.qml</file>
<file>qml/audio_page/dialog_boxes/AudioNewProfileDialog.qml</file>
<file>qml/audio_page/profiles/ProfileButtons.qml</file>
<file>qml/audio_page/proximity/ProximityToggle.qml</file>
<file>qml/audio_page/push_to_talk/PttButtons.qml</file>
<file>qml/chaperone_page/ChaperonePage.qml</file>
<file>qml/chaperone_page/change_orientation/ChangeOrientationGroupBox.qml</file>
<file>qml/chaperone_page/chaperone_additional/ChaperoneAdditionalPage.qml</file>
<file>qml/chaperone_page/chaperone_additional/chaperoneboundscolor/ChaperoneBoundsColorGroupBox.qml</file>
<file>qml/chaperone_page/chaperone_additional/chaperonemisc/ChaperoneMiscGroupBox.qml</file>
<file>qml/chaperone_page/chaperone_additional/chaperonetype/ChaperoneTypeGroupBox.qml</file>
<file>qml/common/FullWidthSliderBox.qml</file>
<file>qml/common/HourComboBox.qml</file>
<file>qml/common/LineSeparator.qml</file>
<file>qml/common/mainwidget.qml</file>
<file>qml/common/MinuteSecondComboBox.qml</file>
<file>qml/common/MyComboBox.qml</file>
<file>qml/common/MyDialogOkCancelPopup.qml</file>
<file>qml/common/MyDialogOkPopup.qml</file>
<file>qml/common/MyPushButton.qml</file>
<file>qml/common/MyPushButton2.qml</file>
<file>qml/common/MyRadioButton.qml</file>
<file>qml/common/MyResources.qml</file>
<file>qml/common/MySlider.qml</file>
<file>qml/common/MyStackViewPage.qml</file>
<file>qml/common/MyText.qml</file>
<file>qml/common/MyTextField.qml</file>
<file>qml/common/MyToggleButton.qml</file>
<file>qml/common/TimeAssembly.qml</file>
<file>qml/motion_page/MotionPage.qml</file>
<file>qml/motion_page/gravity/GravityGroupBox.qml</file>
<file>qml/motion_page/height_toggle/HeightToggleGroupBox.qml</file>
<file>qml/motion_page/space_drag/SpaceDragGroupBox.qml</file>
<file>qml/rotation_page/RotationPage.qml</file>
<file>qml/rotation_page/redirected/AutoTurnGroupBox.qml</file>
<file>qml/rotation_page/redirected/RedirectedGroupBox.qml</file>
<file>qml/rotation_page/snap_turn/SnapTurnGroupBox.qml</file>
<file>qml/rotation_page/space_turn/SpaceTurnGroupBox.qml</file>
<file>qml/rotation_page/view_ratchet/ViewRatchetGroupBox.qml</file>
<file>qml/steamvr_page/SteamVRPage.qml</file>
<file>qml/steamvr_page/camera/CameraGroupBox.qml</file>
<file>qml/steamvr_page/steamvrbind/SteamVRBindGroupBox.qml</file>
<file>qml/steamvr_page/steamvrmisc/SteamVRMiscGroupBox.qml</file>
<file>qml/steamvr_page/steamvr_additional/SteamVRTXRXPage.qml</file>
<file>qml/utilities_page/UtilitiesPage.qml</file>
<file>qml/utilities_page/alarm_clock/AlarmGroupBox.qml</file>
<file>qml/utilities_page/keyboard_utils/KeyboardGroupBox.qml</file>
<file>qml/utilities_page/media_keys/MediaButton.qml</file>
<file>qml/utilities_page/media_keys/MediaControllerKeys.qml</file>
<file>qml/utilities_page/misc/MiscBox.qml</file>
<file>qml/video_page/VideoPage.qml</file>
<file>qml/video_page/brightness/BrightnessGroupBox.qml</file>
<file>qml/video_page/color/ColorGroupBox.qml</file>
<file>qml/video_page/dialogboxes/VideoDeleteProfileDialog.qml</file>
<file>qml/video_page/dialogboxes/VideoMessageDialog.qml</file>
<file>qml/video_page/dialogboxes/VideoNewProfileDialog.qml</file>
<file>qml/video_page/miscvid/VideoMiscGroupBox.qml</file>
<file>qml/video_page/overlaycolorbright/OverlayMethodGroupBox.qml</file>
<file>qml/video_page/profiles/VideoProfileGroupBox.qml</file>
<file>qml/video_page/supersampling/SuperSamplingGroupBox.qml</file>
</qresource>
<qresource prefix="/common">
<file alias="backarrow">img/common/backarrow.svg</file>
<file alias="box_checkmark">img/common/check.svg</file>
+3 -3
View File
@@ -7,7 +7,7 @@
#include "../settings/settings.h"
#include "../settings/settings_object.h"
#include "../utils/update_rate.h"
#include "openvr/ovr_overlay_wrapper.h"
#include "../openvr/ovr_overlay_wrapper.h"
#ifdef _WIN32
# include "audiomanager/AudioManagerWindows.h"
#elif __linux__
@@ -89,9 +89,9 @@ void AudioTabController::initStage2( OverlayController* var_parent )
}
m_pushToTalkValues.pushToTalkImg.reset(
new QImage( QString( ":/microphone/ptt_notification.png" ) ) );
new QImage( ":qt/qml/AdvancedSettings/src/res/img/microphone/ptt_notification.png" ) );
m_pushToTalkValues.pushToMuteImg.reset(
new QImage( QString( ":/microphone/ptm_notification.png" ) ) );
new QImage( ":qt/qml/AdvancedSettings/src/res/img/microphone/ptm_notification.png" ) );
auto* pushToImg = m_pushToTalkValues.pushToTalkImg.get();
if ( settings::getSetting( settings::BoolSetting::AUDIO_micReversePtt ) )
@@ -1620,19 +1620,19 @@ void ChaperoneTabController::initCenterMarkerOverlay()
if ( overlayError == ovr_overlay_wrapper::OverlayError::NoError )
{
m_floorMarkers[-3] = std::unique_ptr<QImage>(
new QImage( QString( ":/chaperone/centermarkl3.png" ) ) );
new QImage( ":qt/qml/AdvancedSettings/src/res/img/chaperone/centermarkl3.png" ) );
m_floorMarkers[-2] = std::unique_ptr<QImage>(
new QImage( QString( ":/chaperone/centermarkl2.png" ) ) );
new QImage( ":qt/qml/AdvancedSettings/src/res/img/chaperone/centermarkl2.png" ) );
m_floorMarkers[-1] = std::unique_ptr<QImage>(
new QImage( QString( ":/chaperone/centermarkl1.png" ) ) );
new QImage( ":qt/qml/AdvancedSettings/src/res/img/chaperone/centermarkl1.png" ) );
m_floorMarkers[0] = std::unique_ptr<QImage>(
new QImage( QString( ":/chaperone/centermark.png" ) ) );
new QImage( ":qt/qml/AdvancedSettings/src/res/img/chaperone/centermark.png" ) );
m_floorMarkers[1] = std::unique_ptr<QImage>(
new QImage( QString( ":/chaperone/centermarkr1.png" ) ) );
new QImage( ":qt/qml/AdvancedSettings/src/res/img/chaperone/centermarkr1.png" ) );
m_floorMarkers[2] = std::unique_ptr<QImage>(
new QImage( QString( ":/chaperone/centermarkr2.png" ) ) );
new QImage( ":qt/qml/AdvancedSettings/src/res/img/chaperone/centermarkr2.png" ) );
m_floorMarkers[3] = std::unique_ptr<QImage>(
new QImage( QString( ":/chaperone/centermarkr3.png" ) ) );
new QImage( ":qt/qml/AdvancedSettings/src/res/img/chaperone/centermarkr3.png" ) );
ovr_overlay_wrapper::setOverlayFromQImage(
m_chaperoneFloorOverlayHandle, *m_floorMarkers[0], "" );
ovr_overlay_wrapper::setOverlayWidthInMeters(
+2 -2
View File
@@ -40,9 +40,9 @@ void RotationTabController::initStage2( OverlayController* var_parent )
return;
}
m_autoturnValues.autoturnImg.reset(
new QImage( QString( ":/rotation/autoturn.png" ) ) );
new QImage( ":qt/qml/AdvancedSettings/src/res/img/rotation/autoturn.png" ) );
m_autoturnValues.noautoturnImg.reset(
new QImage( QString( ":/rotation/noautoturn.png" ) ) );
new QImage( ":qt/qml/AdvancedSettings/src/res/img/rotation/noautoturn.png" ) );
ovr_overlay_wrapper::setOverlayFromQImage( m_autoturnValues.overlayHandle,
*m_autoturnValues.autoturnImg );
@@ -7,7 +7,7 @@
#include "../keyboard_input/input_sender.h"
#include "../settings/settings.h"
#include "../utils/update_rate.h"
#include "openvr/ovr_overlay_wrapper.h"
#include "../openvr/ovr_overlay_wrapper.h"
#include <chrono>
#include <qimage.h>
#include <thread>
@@ -260,17 +260,17 @@ vr::VROverlayHandle_t UtilitiesTabController::createBatteryOverlay(
if ( overlayError == vr::VROverlayError_None )
{
m_batteryImgs[0] = std::unique_ptr<QImage>(
new QImage( QString( ":/battery/battery_0.png" ) ) );
new QImage( ":qt/qml/AdvancedSettings/src/res/img/battery/battery_0.png" ) );
m_batteryImgs[1] = std::unique_ptr<QImage>(
new QImage( QString( ":/battery/battery_1.png" ) ) );
new QImage( ":qt/qml/AdvancedSettings/src/res/img/battery/battery_1.png" ) );
m_batteryImgs[2] = std::unique_ptr<QImage>(
new QImage( QString( ":/battery/battery_2.png" ) ) );
new QImage( ":qt/qml/AdvancedSettings/src/res/img/battery/battery_2.png" ) );
m_batteryImgs[3] = std::unique_ptr<QImage>(
new QImage( QString( ":/battery/battery_3.png" ) ) );
new QImage( ":qt/qml/AdvancedSettings/src/res/img/battery/battery_3.png" ) );
m_batteryImgs[4] = std::unique_ptr<QImage>(
new QImage( QString( ":/battery/battery_4.png" ) ) );
new QImage( ":qt/qml/AdvancedSettings/src/res/img/battery/battery_4.png" ) );
m_batteryImgs[5] = std::unique_ptr<QImage>(
new QImage( QString( ":/battery/battery_5.png" ) ) );
new QImage( ":qt/qml/AdvancedSettings/src/res/img/battery/battery_5.png" ) );
ovr_overlay_wrapper::setOverlayFromQImage( handle, *m_batteryImgs[0] );
vr::VROverlay()->SetOverlayWidthInMeters( handle, 0.045f );
vr::HmdMatrix34_t notificationTransform;
+2 -2
View File
@@ -52,7 +52,7 @@ void VideoTabController::initBrightnessOverlay()
notifKey.c_str(), notifKey.c_str(), &m_brightnessOverlayHandle );
if ( overlayError == vr::VROverlayError_None )
{
QImage notifIcon( QString( ":/video/dimmer.png" ) );
QImage notifIcon( ":qt/qml/AdvancedSettings/src/res/img/video/dimmer.png" );
ovr_overlay_wrapper::setOverlayFromQImage( m_brightnessOverlayHandle,
notifIcon );
vr::VROverlay()->SetOverlayWidthInMeters( m_brightnessOverlayHandle,
@@ -86,7 +86,7 @@ void VideoTabController::initColorOverlay()
notifKey.c_str(), notifKey.c_str(), &m_colorOverlayHandle );
if ( overlayError == vr::VROverlayError_None )
{
QImage notifIcon( QString( ":/video/color.png" ) );
QImage notifIcon(":qt/qml/AdvancedSettings/src/res/img/video/color.png");
ovr_overlay_wrapper::setOverlayFromQImage( m_colorOverlayHandle,
notifIcon );
vr::VROverlay()->SetOverlayWidthInMeters( m_colorOverlayHandle,