From 0b7d6cb7203a60e7f4b31154b4de8db01c498028 Mon Sep 17 00:00:00 2001 From: Dante Ruiz Date: Tue, 31 Jul 2018 14:10:19 -0700 Subject: [PATCH] start interstitial page work --- interface/src/Application.cpp | 12 ++++++++++++ interface/src/Application.h | 3 +++ libraries/audio-client/src/AudioClient.cpp | 8 ++++---- 3 files changed, 19 insertions(+), 4 deletions(-) diff --git a/interface/src/Application.cpp b/interface/src/Application.cpp index 136e44855a..b638c51342 100644 --- a/interface/src/Application.cpp +++ b/interface/src/Application.cpp @@ -3412,6 +3412,16 @@ bool Application::isServerlessMode() const { return false; } +bool Application::isInterstitialPage() { + return _interstitialMode; +} + +void Application::setInterstitialMode(bool interstitialMode) { + if (_interstitialMode != interstitialMode) { + _interstitialMode = interstitialMode; + } +} + void Application::setIsServerlessMode(bool serverlessDomain) { auto tree = getEntities()->getTree(); if (tree) { @@ -5471,6 +5481,8 @@ static bool domainLoadingInProgress = false; void Application::update(float deltaTime) { PROFILE_RANGE_EX(app, __FUNCTION__, 0xffff0000, (uint64_t)_renderFrameCount + 1); + auto audioClient = DependencyManager::get(); + audioClient->setMuted(true); if (!_physicsEnabled) { if (!domainLoadingInProgress) { PROFILE_ASYNC_BEGIN(app, "Scene Loading", ""); diff --git a/interface/src/Application.h b/interface/src/Application.h index 94e561e550..c084c0033f 100644 --- a/interface/src/Application.h +++ b/interface/src/Application.h @@ -304,6 +304,7 @@ public: void saveNextPhysicsStats(QString filename); bool isServerlessMode() const; + bool isInterstitialMode() const; void replaceDomainContent(const QString& url); @@ -423,6 +424,7 @@ public slots: void setPreferredCursor(const QString& cursor); void setIsServerlessMode(bool serverlessDomain); + void setIsInterstitialMode(bool interstialMode); void loadServerlessDomain(QUrl domainURL); void updateVerboseLogging(); @@ -624,6 +626,7 @@ private: QSet _keysPressed; bool _enableProcessOctreeThread; + bool _interstitialMode { true }; OctreePacketProcessor _octreeProcessor; EntityEditPacketSender _entityEditSender; diff --git a/libraries/audio-client/src/AudioClient.cpp b/libraries/audio-client/src/AudioClient.cpp index c57360b09f..0eadcc5b66 100644 --- a/libraries/audio-client/src/AudioClient.cpp +++ b/libraries/audio-client/src/AudioClient.cpp @@ -668,7 +668,7 @@ void AudioClient::stop() { void AudioClient::handleAudioEnvironmentDataPacket(QSharedPointer message) { - char bitset; + /*char bitset; message->readPrimitive(&bitset); bool hasReverb = oneAtBit(bitset, HAS_REVERB_BIT); @@ -680,11 +680,11 @@ void AudioClient::handleAudioEnvironmentDataPacket(QSharedPointer message) { - + /* if (message->getType() == PacketType::SilentAudioFrame) { _silentInbound.increment(); } else { @@ -709,7 +709,7 @@ void AudioClient::handleAudioDataPacket(QSharedPointer message) // Audio output must exist and be correctly set up if we're going to process received audio _receivedAudioStream.parseData(*message); #endif - } +}*/ } AudioClient::Gate::Gate(AudioClient* audioClient) :