try again without macro

This commit is contained in:
Seth Alves 2015-04-07 09:59:04 -07:00
parent e63b39f061
commit 9014397167
31 changed files with 150 additions and 76 deletions

View file

@ -331,7 +331,7 @@ Application::Application(int& argc, char** argv, QElapsedTimer &startup_time) :
_applicationStartupTime = startup_time;
debugLog << "[VERSION] Build sequence: " << qPrintable(applicationVersion());
qCDebug(interfaceapp) << "[VERSION] Build sequence: " << qPrintable(applicationVersion());
_bookmarks = new Bookmarks(); // Before setting up the menu
@ -529,7 +529,7 @@ Application::Application(int& argc, char** argv, QElapsedTimer &startup_time) :
// check first run...
if (_firstRun.get()) {
debugLog << "This is a first run...";
qCDebug(interfaceapp) << "This is a first run...";
// clear the scripts, and set out script to our default scripts
clearScriptsBeforeRunning();
loadScript(DEFAULT_SCRIPTS_JS_URL);
@ -650,7 +650,7 @@ Application::~Application() {
}
void Application::initializeGL() {
debugLog << "Created Display Window.";
qCDebug(interfaceapp) << "Created Display Window.";
// initialize glut for shape drawing; Qt apparently initializes it on OS X
#ifndef __APPLE__
@ -662,10 +662,10 @@ void Application::initializeGL() {
}
#endif
debugLog << "GL Version: " << QString((const char*) glGetString(GL_VERSION));
debugLog << "GL Shader Language Version: " << QString((const char*) glGetString(GL_SHADING_LANGUAGE_VERSION));
debugLog << "GL Vendor: " << QString((const char*) glGetString(GL_VENDOR));
debugLog << "GL Renderer: " << QString((const char*) glGetString(GL_RENDERER));
qCDebug(interfaceapp) << "GL Version: " << QString((const char*) glGetString(GL_VERSION));
qCDebug(interfaceapp) << "GL Shader Language Version: " << QString((const char*) glGetString(GL_SHADING_LANGUAGE_VERSION));
qCDebug(interfaceapp) << "GL Vendor: " << QString((const char*) glGetString(GL_VENDOR));
qCDebug(interfaceapp) << "GL Renderer: " << QString((const char*) glGetString(GL_RENDERER));
#ifdef WIN32
GLenum err = glewInit();
@ -1801,7 +1801,7 @@ bool Application::exportEntities(const QString& filename, float x, float y, floa
}
exportTree.writeToSVOFile(filename.toLocal8Bit().constData());
} else {
debugLog << "No models were selected";
qCDebug(interfaceapp) << "No models were selected";
return false;
}
@ -1899,7 +1899,7 @@ void Application::init() {
DependencyManager::get<AddressManager>()->loadSettings(addressLookupString);
debugLog << "Loaded settings";
qCDebug(interfaceapp) << "Loaded settings";
#ifdef __APPLE__
if (Menu::getInstance()->isOptionChecked(MenuOption::SixenseEnabled)) {
@ -2380,7 +2380,7 @@ int Application::sendNackPackets() {
void Application::queryOctree(NodeType_t serverType, PacketType packetType, NodeToJurisdictionMap& jurisdictions) {
//debugLog << ">>> inside... queryOctree()... _viewFrustum.getFieldOfView()=" << _viewFrustum.getFieldOfView();
//qCDebug(interfaceapp) << ">>> inside... queryOctree()... _viewFrustum.getFieldOfView()=" << _viewFrustum.getFieldOfView();
bool wantExtraDebugging = getLogger()->extraDebugging();
// These will be the same for all servers, so we can set them up once and then reuse for each server we send to.
@ -2483,7 +2483,7 @@ void Application::queryOctree(NodeType_t serverType, PacketType packetType, Node
if (jurisdictions.find(nodeUUID) == jurisdictions.end()) {
unknownView = true; // assume it's in view
if (wantExtraDebugging) {
debugLog << "no known jurisdiction for node " << *node << ", assume it's visible.";
qCDebug(interfaceapp) << "no known jurisdiction for node " << *node << ", assume it's visible.";
}
} else {
const JurisdictionMap& map = (jurisdictions)[nodeUUID];
@ -2503,7 +2503,7 @@ void Application::queryOctree(NodeType_t serverType, PacketType packetType, Node
}
} else {
if (wantExtraDebugging) {
debugLog << "Jurisdiction without RootCode for node " << *node << ". That's unusual!";
qCDebug(interfaceapp) << "Jurisdiction without RootCode for node " << *node << ". That's unusual!";
}
}
}
@ -2512,7 +2512,7 @@ void Application::queryOctree(NodeType_t serverType, PacketType packetType, Node
_octreeQuery.setMaxOctreePacketsPerSecond(perServerPPS);
} else if (unknownView) {
if (wantExtraDebugging) {
debugLog << "no known jurisdiction for node " << *node << ", give it budget of "
qCDebug(interfaceapp) << "no known jurisdiction for node " << *node << ", give it budget of "
<< perUnknownServer << " to send us jurisdiction.";
}
@ -2526,11 +2526,11 @@ void Application::queryOctree(NodeType_t serverType, PacketType packetType, Node
_octreeQuery.setCameraNearClip(0.1f);
_octreeQuery.setCameraFarClip(0.1f);
if (wantExtraDebugging) {
debugLog << "Using 'minimal' camera position for node" << *node;
qCDebug(interfaceapp) << "Using 'minimal' camera position for node" << *node;
}
} else {
if (wantExtraDebugging) {
debugLog << "Using regular camera position for node" << *node;
qCDebug(interfaceapp) << "Using regular camera position for node" << *node;
}
}
_octreeQuery.setMaxOctreePacketsPerSecond(perUnknownServer);
@ -3303,7 +3303,7 @@ void Application::updateWindowTitle(){
}
void Application::clearDomainOctreeDetails() {
debugLog << "Clearing domain octree details...";
qCDebug(interfaceapp) << "Clearing domain octree details...";
// reset the environment so that we don't erroneously end up with multiple
_environment.resetToDefault();
@ -3707,7 +3707,7 @@ bool Application::askToSetAvatarUrl(const QString& url) {
QNetworkRequest networkRequest = QNetworkRequest(url);
networkRequest.setHeader(QNetworkRequest::UserAgentHeader, HIGH_FIDELITY_USER_AGENT);
QNetworkReply* reply = networkAccessManager.get(networkRequest);
debugLog << "Downloading avatar file at " << url;
qCDebug(interfaceapp) << "Downloading avatar file at " << url;
QEventLoop loop;
QObject::connect(reply, &QNetworkReply::finished, &loop, &QEventLoop::quit);
loop.exec();
@ -3756,13 +3756,13 @@ bool Application::askToSetAvatarUrl(const QString& url) {
msgBox.exec();
if (msgBox.clickedButton() == headButton) {
debugLog << "Chose to use for head: " << url;
qCDebug(interfaceapp) << "Chose to use for head: " << url;
_myAvatar->setFaceModelURL(url);
UserActivityLogger::getInstance().changedModel("head", url);
_myAvatar->sendIdentityPacket();
emit faceURLChanged(url);
} else if (msgBox.clickedButton() == bodyButton) {
debugLog << "Chose to use for body: " << url;
qCDebug(interfaceapp) << "Chose to use for body: " << url;
_myAvatar->setSkeletonModelURL(url);
// if the head is empty, reset it to the default head.
if (_myAvatar->getFaceModelURLString().isEmpty()) {
@ -3774,7 +3774,7 @@ bool Application::askToSetAvatarUrl(const QString& url) {
_myAvatar->sendIdentityPacket();
emit skeletonURLChanged(url);
} else if (msgBox.clickedButton() == bodyAndHeadButton) {
debugLog << "Chose to use for body + head: " << url;
qCDebug(interfaceapp) << "Chose to use for body + head: " << url;
_myAvatar->setFaceModelURL(QString());
_myAvatar->setSkeletonModelURL(url);
UserActivityLogger::getInstance().changedModel("skeleton", url);
@ -3782,7 +3782,7 @@ bool Application::askToSetAvatarUrl(const QString& url) {
emit faceURLChanged(QString());
emit skeletonURLChanged(url);
} else {
debugLog << "Declined to use the avatar: " << url;
qCDebug(interfaceapp) << "Declined to use the avatar: " << url;
}
return true;
}
@ -3794,10 +3794,10 @@ bool Application::askToLoadScript(const QString& scriptFilenameOrURL) {
reply = QMessageBox::question(getWindow(), "Run Script", message, QMessageBox::Yes|QMessageBox::No);
if (reply == QMessageBox::Yes) {
debugLog << "Chose to run the script: " << scriptFilenameOrURL;
qCDebug(interfaceapp) << "Chose to run the script: " << scriptFilenameOrURL;
loadScript(scriptFilenameOrURL);
} else {
debugLog << "Declined to run the script: " << scriptFilenameOrURL;
qCDebug(interfaceapp) << "Declined to run the script: " << scriptFilenameOrURL;
}
return true;
}
@ -3855,7 +3855,7 @@ void Application::handleScriptEngineLoaded(const QString& scriptFilename) {
}
void Application::handleScriptLoadError(const QString& scriptFilename) {
debugLog << "Application::loadScript(), script failed to load...";
qCDebug(interfaceapp) << "Application::loadScript(), script failed to load...";
QMessageBox::warning(getWindow(), "Error Loading Script", scriptFilename + " failed to load.");
}
@ -3877,7 +3877,7 @@ void Application::stopAllScripts(bool restart) {
connect(it.value(), SIGNAL(finished(const QString&)), SLOT(loadScript(const QString&)));
}
it.value()->stop();
debugLog << "stopping script..." << it.key();
qCDebug(interfaceapp) << "stopping script..." << it.key();
}
// HACK: ATM scripts cannot set/get their animation priorities, so we clear priorities
// whenever a script stops in case it happened to have been setting joint rotations.
@ -3889,7 +3889,7 @@ void Application::stopScript(const QString &scriptName) {
const QString& scriptURLString = QUrl(scriptName).toString();
if (_scriptEnginesHash.contains(scriptURLString)) {
_scriptEnginesHash.value(scriptURLString)->stop();
debugLog << "stopping script..." << scriptName;
qCDebug(interfaceapp) << "stopping script..." << scriptName;
// HACK: ATM scripts cannot set/get their animation priorities, so we clear priorities
// whenever a script stops in case it happened to have been setting joint rotations.
// TODO: expose animation priorities and provide a layered animation control system.
@ -3987,8 +3987,8 @@ void Application::domainSettingsReceived(const QJsonObject& domainSettingsObject
voxelWalletUUID = QUuid(voxelObject[VOXEL_WALLET_UUID].toString());
}
debugLog << "Octree edits costs are" << satoshisPerVoxel << "per octree cell and" << satoshisPerMeterCubed << "per meter cubed";
debugLog << "Destination wallet UUID for edit payments is" << voxelWalletUUID;
qCDebug(interfaceapp) << "Octree edits costs are" << satoshisPerVoxel << "per octree cell and" << satoshisPerMeterCubed << "per meter cubed";
qCDebug(interfaceapp) << "Destination wallet UUID for edit payments is" << voxelWalletUUID;
}
QString Application::getPreviousScriptLocation() {
@ -4286,7 +4286,7 @@ void Application::notifyPacketVersionMismatch() {
void Application::checkSkeleton() {
if (_myAvatar->getSkeletonModel().isActive() && !_myAvatar->getSkeletonModel().hasSkeleton()) {
debugLog << "MyAvatar model has no skeleton";
qCDebug(interfaceapp) << "MyAvatar model has no skeleton";
QString message = "Your selected avatar body has no skeleton.\n\nThe default body will be loaded...";
QMessageBox msgBox;

View file

@ -36,7 +36,7 @@ void Bookmarks::insert(const QString& name, const QString& address) {
_bookmarks.insert(name, address);
if (contains(name)) {
debugLog << "Added bookmark:" << name << "," << address;
qCDebug(interfaceapp) << "Added bookmark:" << name << "," << address;
persistToFile();
} else {
qWarning() << "Couldn't add bookmark: " << name << "," << address;
@ -47,7 +47,7 @@ void Bookmarks::remove(const QString& name) {
_bookmarks.remove(name);
if (!contains(name)) {
debugLog << "Deleted bookmark:" << name;
qCDebug(interfaceapp) << "Deleted bookmark:" << name;
persistToFile();
} else {
qWarning() << "Couldn't delete bookmark:" << name;

View file

@ -126,8 +126,8 @@ void DatagramProcessor::processDatagrams() {
// output to the log so the user knows they got a denied connection request
// and check and signal for an access token so that we can make sure they are logged in
debugLog << "The domain-server denied a connection request: " << reason;
debugLog << "You may need to re-log to generate a keypair so you can provide a username signature.";
qCDebug(interfaceapp) << "The domain-server denied a connection request: " << reason;
qCDebug(interfaceapp) << "You may need to re-log to generate a keypair so you can provide a username signature.";
application->domainConnectionDenied(reason);
AccountManager::getInstance().checkAndSignalForAccessToken();
break;

View file

@ -9,8 +9,11 @@
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
#ifndef hifi_InterfaceLogging_h
#define hifi_InterfaceLogging_h
#include <QLoggingCategory>
Q_DECLARE_LOGGING_CATEGORY(interfaceapp)
#define debugLog qCDebug(interfaceapp)
#endif // hifi_InterfaceLogging_h

View file

@ -79,7 +79,7 @@ void LODManager::autoAdjustLOD(float currentFPS) {
doDownShift = _fpsAverageDownWindow.getAverage() < getLODDecreaseFPS();
if (!doDownShift) {
debugLog << "---- WE APPEAR TO BE DONE DOWN SHIFTING -----";
qCDebug(interfaceapp) << "---- WE APPEAR TO BE DONE DOWN SHIFTING -----";
_isDownshifting = false;
_lastStable = now;
}
@ -103,7 +103,7 @@ void LODManager::autoAdjustLOD(float currentFPS) {
if (changed) {
if (_isDownshifting) {
// subsequent downshift
debugLog << "adjusting LOD DOWN..."
qCDebug(interfaceapp) << "adjusting LOD DOWN..."
<< "average fps for last "<< DOWN_SHIFT_WINDOW_IN_SECS <<"seconds was "
<< _fpsAverageDownWindow.getAverage()
<< "minimum is:" << getLODDecreaseFPS()
@ -111,7 +111,7 @@ void LODManager::autoAdjustLOD(float currentFPS) {
<< " NEW _octreeSizeScale=" << _octreeSizeScale;
} else {
// first downshift
debugLog << "adjusting LOD DOWN after initial delay..."
qCDebug(interfaceapp) << "adjusting LOD DOWN after initial delay..."
<< "average fps for last "<< START_DELAY_WINDOW_IN_SECS <<"seconds was "
<< _fpsAverageStartWindow.getAverage()
<< "minimum is:" << getLODDecreaseFPS()
@ -146,7 +146,7 @@ void LODManager::autoAdjustLOD(float currentFPS) {
}
if (changed) {
debugLog << "adjusting LOD UP... average fps for last "<< UP_SHIFT_WINDOW_IN_SECS <<"seconds was "
qCDebug(interfaceapp) << "adjusting LOD UP... average fps for last "<< UP_SHIFT_WINDOW_IN_SECS <<"seconds was "
<< _fpsAverageUpWindow.getAverage()
<< "upshift point is:" << getLODIncreaseFPS()
<< "elapsedSinceUpShift:" << elapsedSinceUpShift

View file

@ -744,7 +744,7 @@ void Menu::triggerOption(const QString& menuOption) {
if (action) {
action->trigger();
} else {
debugLog << "NULL Action for menuOption '" << menuOption << "'";
qCDebug(interfaceapp) << "NULL Action for menuOption '" << menuOption << "'";
}
}
@ -988,7 +988,7 @@ void Menu::setVisibility() {
} else if (Menu::getInstance()->isOptionChecked(MenuOption::VisibleToNoOne)) {
discoverabilityManager->setDiscoverabilityMode(Discoverability::None);
} else {
debugLog << "ERROR Menu::setVisibility() called with unrecognized value.";
qCDebug(interfaceapp) << "ERROR Menu::setVisibility() called with unrecognized value.";
}
}
@ -1000,6 +1000,6 @@ void Menu::visibilityChanged(Discoverability::Mode discoverabilityMode) {
} else if (discoverabilityMode == Discoverability::None) {
setIsOptionChecked(MenuOption::VisibleToNoOne, true);
} else {
debugLog << "ERROR Menu::visibilityChanged() called with unrecognized value.";
qCDebug(interfaceapp) << "ERROR Menu::visibilityChanged() called with unrecognized value.";
}
}

View file

@ -85,7 +85,7 @@ bool ModelPackager::loadModel() {
qWarning() << QString("ModelPackager::loadModel(): Could not open FST file %1").arg(_modelFile.filePath());
return false;
}
debugLog << "Reading FST file : " << _modelFile.filePath();
qCDebug(interfaceapp) << "Reading FST file : " << _modelFile.filePath();
_mapping = FSTReader::readMapping(fst.readAll());
fst.close();
@ -104,7 +104,7 @@ bool ModelPackager::loadModel() {
qWarning() << QString("ModelPackager::loadModel(): Could not open FBX file %1").arg(_fbxInfo.filePath());
return false;
}
debugLog << "Reading FBX file : " << _fbxInfo.filePath();
qCDebug(interfaceapp) << "Reading FBX file : " << _fbxInfo.filePath();
QByteArray fbxContents = fbx.readAll();
_geometry = readFBX(fbxContents, QVariantHash());
@ -189,7 +189,7 @@ bool ModelPackager::zipModel() {
fst.write(FSTReader::writeMapping(_mapping));
fst.close();
} else {
debugLog << "Couldn't write FST file" << fst.fileName();
qCDebug(interfaceapp) << "Couldn't write FST file" << fst.fileName();
return false;
}
@ -197,7 +197,7 @@ bool ModelPackager::zipModel() {
QString saveDirPath = QFileDialog::getExistingDirectory(nullptr, "Save Model",
"", QFileDialog::ShowDirsOnly);
if (saveDirPath.isEmpty()) {
debugLog << "Invalid directory" << saveDirPath;
qCDebug(interfaceapp) << "Invalid directory" << saveDirPath;
return false;
}
@ -405,7 +405,7 @@ bool ModelPackager::copyTextures(const QString& oldDir, const QDir& newDir) {
if (!errors.isEmpty()) {
QMessageBox::warning(nullptr, "ModelPackager::copyTextures()",
"Missing textures:" + errors);
debugLog << "ModelPackager::copyTextures():" << errors;
qCDebug(interfaceapp) << "ModelPackager::copyTextures():" << errors;
return false;
}

View file

@ -182,7 +182,7 @@ void ScriptsModel::downloadFinished() {
if (!data.isEmpty()) {
finished = parseXML(data);
} else {
debugLog << "Error: Received no data when loading remote scripts";
qCDebug(interfaceapp) << "Error: Received no data when loading remote scripts";
}
}
@ -231,7 +231,7 @@ bool ScriptsModel::parseXML(QByteArray xmlFile) {
// Error handling
if (xml.hasError()) {
debugLog << "Error loading remote scripts: " << xml.errorString();
qCDebug(interfaceapp) << "Error loading remote scripts: " << xml.errorString();
return true;
}

View file

@ -140,13 +140,13 @@ void SpeechRecognizer::setEnabled(bool enabled) {
_enabled = SUCCEEDED(hr);
debugLog << "Speech recognition" << (_enabled ? "enabled" : "enable failed");
qCDebug(interfaceapp) << "Speech recognition" << (_enabled ? "enabled" : "enable failed");
} else {
_commandRecognizedNotifier->setEnabled(false);
static_cast<ISpRecoContext*>(_speechRecognizerContext)->Release();
static_cast<ISpRecognizer*>(_speechRecognizer)->Release();
debugLog << "Speech recognition disabled";
qCDebug(interfaceapp) << "Speech recognition disabled";
}
emit enabledUpdated(_enabled);
@ -208,7 +208,7 @@ void SpeechRecognizer::reloadCommands() {
}
if (FAILED(hr)) {
debugLog << "ERROR: Didn't successfully reload speech commands";
qCDebug(interfaceapp) << "ERROR: Didn't successfully reload speech commands";
}
}

View file

@ -139,7 +139,7 @@ void Avatar::simulate(float deltaTime) {
this);
break;
default:
debugLog << "[WARNING] Avatar::simulate(): Unknown referential type.";
qCDebug(interfaceapp) << "[WARNING] Avatar::simulate(): Unknown referential type.";
break;
}
}

View file

@ -26,7 +26,7 @@ ModelReferential::ModelReferential(Referential* referential, EntityTree* tree, A
referential->getExtraData().size());
if (!isValid()) {
debugLog << "ModelReferential::copyConstructor(): Not Valid";
qCDebug(interfaceapp) << "ModelReferential::copyConstructor(): Not Valid";
return;
}
@ -46,7 +46,7 @@ ModelReferential::ModelReferential(const QUuid& entityID, EntityTree* tree, Avat
{
const EntityItem* item = _tree->findEntityByID(_entityID);
if (!isValid() || item == NULL) {
debugLog << "ModelReferential::constructor(): Not Valid";
qCDebug(interfaceapp) << "ModelReferential::constructor(): Not Valid";
_isValid = false;
return;
}
@ -101,7 +101,7 @@ JointReferential::JointReferential(Referential* referential, EntityTree* tree, A
{
_type = JOINT;
if (!isValid()) {
debugLog << "JointReferential::copyConstructor(): Not Valid";
qCDebug(interfaceapp) << "JointReferential::copyConstructor(): Not Valid";
return;
}
@ -123,7 +123,7 @@ JointReferential::JointReferential(uint32_t jointIndex, const QUuid& entityID, E
const EntityItem* item = _tree->findEntityByID(_entityID);
const Model* model = getModel(item);
if (!isValid() || model == NULL || _jointIndex >= (uint32_t)(model->getJointStateCount())) {
debugLog << "JointReferential::constructor(): Not Valid";
qCDebug(interfaceapp) << "JointReferential::constructor(): Not Valid";
_isValid = false;
return;
}

View file

@ -448,7 +448,7 @@ void MyAvatar::stopRecording() {
void MyAvatar::saveRecording(QString filename) {
if (!_recorder) {
debugLog << "There is no recording to save";
qCDebug(interfaceapp) << "There is no recording to save";
return;
}
if (QThread::currentThread() != thread()) {
@ -467,7 +467,7 @@ void MyAvatar::loadLastRecording() {
return;
}
if (!_recorder) {
debugLog << "There is no recording to load";
qCDebug(interfaceapp) << "There is no recording to load";
return;
}
if (!_player) {
@ -781,7 +781,7 @@ AttachmentData MyAvatar::loadAttachmentData(const QUrl& modelURL, const QString&
}
int MyAvatar::parseDataAtOffset(const QByteArray& packet, int offset) {
debugLog << "Error: ignoring update packet for MyAvatar"
qCDebug(interfaceapp) << "Error: ignoring update packet for MyAvatar"
<< " packetLength = " << packet.size()
<< " offset = " << offset;
// this packet is just bad, so we pretend that we unpacked it ALL
@ -1352,13 +1352,13 @@ void MyAvatar::goToLocation(const glm::vec3& newPosition,
bool hasOrientation, const glm::quat& newOrientation,
bool shouldFaceLocation) {
debugLog.nospace() << "MyAvatar goToLocation - moving to " << newPosition.x << ", "
qCDebug(interfaceapp).nospace() << "MyAvatar goToLocation - moving to " << newPosition.x << ", "
<< newPosition.y << ", " << newPosition.z;
glm::vec3 shiftedPosition = newPosition;
if (hasOrientation) {
debugLog.nospace() << "MyAvatar goToLocation - new orientation is "
qCDebug(interfaceapp).nospace() << "MyAvatar goToLocation - new orientation is "
<< newOrientation.x << ", " << newOrientation.y << ", " << newOrientation.z << ", " << newOrientation.w;
// orient the user to face the target

View file

@ -177,7 +177,7 @@ bool DdeFaceTracker::isActive() const {
//private slots and methods
void DdeFaceTracker::socketErrorOccurred(QAbstractSocket::SocketError socketError) {
debugLog << "[Error] DDE Face Tracker Socket Error: " << _udpSocket.errorString();
qCDebug(interfaceapp) << "[Error] DDE Face Tracker Socket Error: " << _udpSocket.errorString();
}
void DdeFaceTracker::socketStateChanged(QAbstractSocket::SocketState socketState) {
@ -205,7 +205,7 @@ void DdeFaceTracker::socketStateChanged(QAbstractSocket::SocketState socketState
state = "Unconnected";
break;
}
debugLog << "[Info] DDE Face Tracker Socket: " << state;
qCDebug(interfaceapp) << "[Info] DDE Face Tracker Socket: " << state;
}
void DdeFaceTracker::readPendingDatagrams() {
@ -299,7 +299,7 @@ void DdeFaceTracker::decodePacket(const QByteArray& buffer) {
}
} else {
debugLog << "[Error] DDE Face Tracker Decode Error";
qCDebug(interfaceapp) << "[Error] DDE Face Tracker Decode Error";
}
_lastReceiveTimestamp = usecTimestampNow();
}

View file

@ -156,7 +156,7 @@ void Faceshift::noteConnected() {
void Faceshift::noteError(QAbstractSocket::SocketError error) {
if (!_tcpRetryCount) {
// Only spam log with fail to connect the first time, so that we can keep waiting for server
debugLog << "Faceshift: " << _tcpSocket.errorString();
qCDebug(interfaceapp) << "Faceshift: " << _tcpSocket.errorString();
}
// retry connection after a 2 second delay
if (_tcpEnabled) {

View file

@ -55,7 +55,7 @@ void MIDIManager::openDefaultPort() {
_midiInput = new RtMidiIn();
if (_midiInput->getPortCount() > 0) {
debugLog << "MIDIManager opening port" << DEFAULT_MIDI_PORT;
qCDebug(interfaceapp) << "MIDIManager opening port" << DEFAULT_MIDI_PORT;
_midiInput->openPort(DEFAULT_MIDI_PORT);
@ -64,7 +64,7 @@ void MIDIManager::openDefaultPort() {
_midiInput->setCallback(&MIDIManager::midiCallback);
} else {
debugLog << "MIDIManager openDefaultPort called but there are no ports available.";
qCDebug(interfaceapp) << "MIDIManager openDefaultPort called but there are no ports available.";
delete _midiInput;
_midiInput = NULL;
}

View file

@ -129,7 +129,7 @@ void OculusManager::connect() {
initSdk();
#endif
_calibrationState = UNCALIBRATED;
debugLog << "Oculus SDK" << OVR_VERSION_STRING;
qCDebug(interfaceapp) << "Oculus SDK" << OVR_VERSION_STRING;
if (_ovrHmd) {
if (!_isConnected) {
UserActivityLogger::getInstance().connectedDevice("hmd", "oculus");
@ -279,7 +279,7 @@ void OculusManager::calibrate(glm::vec3 position, glm::quat orientation) {
_calibrationState = WAITING_FOR_ZERO_HELD;
if (!_calibrationMessage) {
debugLog << "Hold still to calibrate HMD";
qCDebug(interfaceapp) << "Hold still to calibrate HMD";
billboard = new Text3DOverlay();
billboard->setDimensions(glm::vec2(2.0f, 1.25f));
@ -306,7 +306,7 @@ void OculusManager::calibrate(glm::vec3 position, glm::quat orientation) {
&& glm::angle(orientation * glm::inverse(_calibrationOrientation)) < CALIBRATION_ZERO_MAXIMUM_ANGLE) {
if ((usecTimestampNow() - _calibrationStartTime) > CALIBRATION_ZERO_HOLD_TIME) {
_calibrationState = CALIBRATED;
debugLog << "HMD calibrated";
qCDebug(interfaceapp) << "HMD calibrated";
Application::getInstance()->getOverlays().deleteOverlay(_calibrationMessage);
_calibrationMessage = NULL;
Application::getInstance()->resetSensors();
@ -347,7 +347,7 @@ void OculusManager::recalibrate() {
void OculusManager::abandonCalibration() {
_calibrationState = CALIBRATED;
if (_calibrationMessage) {
debugLog << "Abandoned HMD calibration";
qCDebug(interfaceapp) << "Abandoned HMD calibration";
Application::getInstance()->getOverlays().deleteOverlay(_calibrationMessage);
_calibrationMessage = NULL;
}
@ -471,7 +471,7 @@ void OculusManager::display(const glm::quat &bodyOrientation, const glm::vec3 &p
if (timerActive && timerQuery.isResultAvailable()) {
auto result = timerQuery.waitForResult();
if (result) { debugLog << "Distortion took " << result << "ns"; };
if (result) { qCDebug(interfaceapp) << "Distortion took " << result << "ns"; };
timerActive = false;
}
#endif
@ -684,7 +684,7 @@ void OculusManager::display(const glm::quat &bodyOrientation, const glm::vec3 &p
if (nonZero)
{
debugLog << QString().sprintf("M2P Latency: Ren: %4.2fms TWrp: %4.2fms PostPresent: %4.2fms Err: %4.2fms %4.2fms",
qCDebug(interfaceapp) << QString().sprintf("M2P Latency: Ren: %4.2fms TWrp: %4.2fms PostPresent: %4.2fms Err: %4.2fms %4.2fms",
latencies[0], latencies[1], latencies[2], latencies[3], latencies[4]);
}
}

View file

@ -109,9 +109,9 @@ void SixenseManager::initialize() {
}
if (_sixenseLibrary->load()){
debugLog << "Loaded sixense library for hydra support -" << _sixenseLibrary->fileName();
qCDebug(interfaceapp) << "Loaded sixense library for hydra support -" << _sixenseLibrary->fileName();
} else {
debugLog << "Sixense library at" << _sixenseLibrary->fileName() << "failed to load."
qCDebug(interfaceapp) << "Sixense library at" << _sixenseLibrary->fileName() << "failed to load."
<< "Continuing without hydra support.";
return;
}

View file

@ -26,7 +26,7 @@ bool Controller::computeStars(unsigned numStars, unsigned seed) {
double NSEC_TO_MSEC = 1.0 / 1000000.0;
double timeDiff = (double)startTime.nsecsElapsed() * NSEC_TO_MSEC;
debugLog << "Total time to retile and generate stars: " << timeDiff << "msec";
qCDebug(interfaceapp) << "Total time to retile and generate stars: " << timeDiff << "msec";
return true;
}

View file

@ -9,6 +9,12 @@
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
#ifndef hifi_AudioClientLogging_h
#define hifi_AudioClientLogging_h
#include <QLoggingCategory>
Q_DECLARE_LOGGING_CATEGORY(audioclient)
#endif // hifi_AudioClientLogging_h

View file

@ -9,6 +9,11 @@
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
#ifndef hifi_AudioLogging_h
#define hifi_AudioLogging_h
#include <QLoggingCategory>
Q_DECLARE_LOGGING_CATEGORY(audio)
#endif // hifi_AudioLogging_h

View file

@ -9,6 +9,12 @@
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
#ifndef hifi_AvatarLogging_h
#define hifi_AvatarLogging_h
#include <QLoggingCategory>
Q_DECLARE_LOGGING_CATEGORY(avatars)
#endif // hifi_AvatarLogging_h

View file

@ -9,6 +9,11 @@
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
#ifndef hifi_EmbeddedWebserverLogging_h
#define hifi_EmbeddedWebserverLogging_h
#include <QLoggingCategory>
Q_DECLARE_LOGGING_CATEGORY(embeddedwebserver)
#endif // hifi_EmbeddedWebserverLogging_h

View file

@ -9,6 +9,12 @@
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
#ifndef hifi_EntitiesRendererLogging_h
#define hifi_EntitiesRendererLogging_h
#include <QLoggingCategory>
Q_DECLARE_LOGGING_CATEGORY(entitiesrenderer)
#endif // hifi_EntitiesRendererLogging_h

View file

@ -9,6 +9,11 @@
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
#ifndef hifi_EntitiesLogging_h
#define hifi_EntitiesLogging_h
#include <QLoggingCategory>
Q_DECLARE_LOGGING_CATEGORY(entities)
#endif // hifi_EntitiesLogging_h

View file

@ -9,6 +9,11 @@
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
#ifndef hifi_ModelFormatLogging_h
#define hifi_ModelFormatLogging_h
#include <QLoggingCategory>
Q_DECLARE_LOGGING_CATEGORY(modelformat)
#endif // hifi_ModelFormatLogging_h

View file

@ -9,6 +9,12 @@
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
#ifndef hifi_GPULogging_h
#define hifi_GPULogging_h
#include <QLoggingCategory>
Q_DECLARE_LOGGING_CATEGORY(gpulogging)
#endif // hifi_GPULogging_h

View file

@ -9,6 +9,11 @@
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
#ifndef hifi_NetworkLogging_h
#define hifi_NetworkLogging_h
#include <QLoggingCategory>
Q_DECLARE_LOGGING_CATEGORY(networking)
#endif // hifi_NetworkLogging_h

View file

@ -9,6 +9,11 @@
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
#ifndef hifi_OctreeLogging_h
#define hifi_OctreeLogging_h
#include <QLoggingCategory>
Q_DECLARE_LOGGING_CATEGORY(octree)
#endif // hifi_OctreeLogging_h

View file

@ -9,6 +9,11 @@
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
#ifndef hifi_PhysicsLogging_h
#define hifi_PhysicsLogging_h
#include <QLoggingCategory>
Q_DECLARE_LOGGING_CATEGORY(physics)
#endif // hifi_PhysicsLogging_h

View file

@ -9,6 +9,12 @@
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
#ifndef hifi_ScriptEngineLogging_h
#define hifi_ScriptEngineLogging_h
#include <QLoggingCategory>
Q_DECLARE_LOGGING_CATEGORY(scriptengine)
#endif // hifi_ScriptEngineLogging_h

View file

@ -9,6 +9,12 @@
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
#ifndef hifi_SharedLogging_h
#define hifi_SharedLogging_h
#include <QLoggingCategory>
Q_DECLARE_LOGGING_CATEGORY(shared)
#endif // hifi_SharedLogging_h