From ae9f0bab372f3c8572734729cfe78dfaf49bbf35 Mon Sep 17 00:00:00 2001 From: Aaron Colwell <300262+acolwell@users.noreply.github.com> Date: Mon, 4 Sep 2023 13:40:02 -0700 Subject: [PATCH] Comment out #pragma message WARN lines Commenting out #pragma lines since they make it harder to see actual errors in the compiler output. These warnings don't actually seem useful and don't appear to be high priority issues that need to be addressed. --- Engine/AppManager.cpp | 2 +- Engine/EffectInstance.cpp | 2 +- Engine/Knob.cpp | 2 +- Engine/KnobTypes.cpp | 2 +- Engine/NodeMain.cpp | 2 +- Engine/OfxEffectInstance.cpp | 4 ++-- Engine/OfxParamInstance.cpp | 2 +- Engine/ParallelRenderArgs.cpp | 2 +- Engine/Project.cpp | 2 +- Engine/ProjectPrivate.cpp | 2 +- Engine/ReadNode.cpp | 6 +++--- Engine/RotoContextPrivate.h | 6 +++--- Engine/TrackerFrameAccessor.cpp | 2 +- Engine/ViewerInstance.cpp | 4 ++-- Engine/WriteNode.cpp | 6 +++--- Gui/DocumentationManager.cpp | 2 +- Gui/DopeSheetView.cpp | 2 +- Gui/Histogram.cpp | 2 +- Gui/NodeGraph10.cpp | 2 +- Gui/ViewerGL.cpp | 2 +- 20 files changed, 28 insertions(+), 28 deletions(-) diff --git a/Engine/AppManager.cpp b/Engine/AppManager.cpp index abd8a4081..cba7a4658 100644 --- a/Engine/AppManager.cpp +++ b/Engine/AppManager.cpp @@ -3844,7 +3844,7 @@ NATRON_PYTHON_NAMESPACE::isKeyword(const std::string& str) } #if !defined(NDEBUG) && !defined(DEBUG_PYTHON_GIL) -#pragma message WARN("define DEBUG_PYTHON_GIL in AppManager.h to debug Python GIL issues") +//#pragma message WARN("define DEBUG_PYTHON_GIL in AppManager.h to debug Python GIL issues") #endif #ifdef DEBUG_PYTHON_GIL diff --git a/Engine/EffectInstance.cpp b/Engine/EffectInstance.cpp index fd3f61d4f..b4c004ff8 100644 --- a/Engine/EffectInstance.cpp +++ b/Engine/EffectInstance.cpp @@ -3874,7 +3874,7 @@ EffectInstance::getRegionOfDefinition_public(U64 hash, if (isProjectFormat) { *isProjectFormat = false; } -#pragma message WARN("[FD] why is an empty RoD a failure case? this is ignored in renderRoI, search for 'if getRoD fails, this might be because the RoD is null after all (e.g: an empty Roto node), we don't want the render to fail'") +//#pragma message WARN("[FD] why is an empty RoD a failure case? this is ignored in renderRoI, search for 'if getRoD fails, this might be because the RoD is null after all (e.g: an empty Roto node), we don't want the render to fail'") if ( rod->isNull() ) { return eStatusFailed; } diff --git a/Engine/Knob.cpp b/Engine/Knob.cpp index d3c151072..2c0cd87ab 100644 --- a/Engine/Knob.cpp +++ b/Engine/Knob.cpp @@ -381,7 +381,7 @@ struct KnobHelperPrivate KnobHelper* publicInterface; #ifdef DEBUG -#pragma message WARN("This should be a weak_ptr") +//#pragma message WARN("This should be a weak_ptr") #endif KnobHolder* holder; mutable QMutex labelMutex; diff --git a/Engine/KnobTypes.cpp b/Engine/KnobTypes.cpp index 199725f71..54c0ea0a1 100644 --- a/Engine/KnobTypes.cpp +++ b/Engine/KnobTypes.cpp @@ -976,7 +976,7 @@ bool BothAreSpaces(char lhs, char rhs) { return (lhs == rhs) && (lhs == ' '); } // 5- paren/bracket-insensitive match (for WriteFFmpeg's format and codecs) // 6- if the choice ends with " 1" try to match exactly everything before that (for formats with PAR=1, where the PAR was removed) // returns index if choice was matched, -1 if not matched -#pragma message WARN("choiceMatch() should be moved into filterKnobChoiceOptionCompat().") +//#pragma message WARN("choiceMatch() should be moved into filterKnobChoiceOptionCompat().") // TODO: choiceMatch() should be moved into filterKnobChoiceOptionCompat() // TODO: filterKnobChoiceOptionCompat() should be used everywhere instead of choiceMatch() int diff --git a/Engine/NodeMain.cpp b/Engine/NodeMain.cpp index 36feb9b5e..fb03e30fb 100644 --- a/Engine/NodeMain.cpp +++ b/Engine/NodeMain.cpp @@ -621,7 +621,7 @@ Node::Implementation::restoreUserKnobsRecursive(const std::list_choiceString; // first, try to get the id the easy way ( see choiceMatch() ) int id = isChoice->choiceRestorationId(choiceSerialized, optionID); -#pragma message WARN("TODO: choice id filters") +//#pragma message WARN("TODO: choice id filters") //if (id < 0) { // // no luck, try the filters // filterKnobChoiceOptionCompat(getPluginID(), serialization.getPluginMajorVersion(), serialization.getPluginMinorVersion(), projectInfos.vMajor, projectInfos.vMinor, projectInfos.vRev, serializedName, &optionID); diff --git a/Engine/OfxEffectInstance.cpp b/Engine/OfxEffectInstance.cpp index 22eff8304..a9836ebdd 100644 --- a/Engine/OfxEffectInstance.cpp +++ b/Engine/OfxEffectInstance.cpp @@ -756,7 +756,7 @@ OfxEffectInstance::tryInitializeOverlayInteracts() OFX::Host::Interact::Descriptor &interactDesc = paramToKnob->getInteractDesc(); interactDesc.getProperties().addProperties(interactDescProps); interactDesc.setEntryPoint(interactEntryPoint); -#pragma message WARN("FIXME: bitdepth and hasalpha are probably wrong") +//#pragma message WARN("FIXME: bitdepth and hasalpha are probably wrong") interactDesc.describe(/*bitdepthPerComponent=*/ 8, /*hasAlpha=*/ false); OfxParamOverlayInteractPtr overlayInteract( new OfxParamOverlayInteract( knob.get(), interactDesc, effectInstance()->getHandle()) ); knob->setCustomInteract(overlayInteract); @@ -1863,7 +1863,7 @@ OfxEffectInstance::isIdentity(double time, stat = _imp->effect->isIdentityAction(inputTimeOfx, field, ofxRoI, scale, identityView, identityPlane, inputclip); } if (identityView != view || identityPlane != kFnOfxImagePlaneColour) { -#pragma message WARN("can Natron RB2-multiplane2 handle isIdentity across views and planes?") +//#pragma message WARN("can Natron RB2-multiplane2 handle isIdentity across views and planes?") // Natron 2 cannot handle isIdentity across planes stat = kOfxStatOK; } diff --git a/Engine/OfxParamInstance.cpp b/Engine/OfxParamInstance.cpp index 90bcad94e..91facaf65 100644 --- a/Engine/OfxParamInstance.cpp +++ b/Engine/OfxParamInstance.cpp @@ -4831,7 +4831,7 @@ OfxParametricInstance::addControlPoint(int curveIndex, KeyframeTypeEnum interpolation = eKeyframeTypeSmooth; // a reasonable default // The initial curve for some plugins may be better with a specific interpolation. Unfortunately, the kOfxParametricSuiteV1 doesn't offer different interpolation methods #ifdef DEBUG -#pragma message WARN("This is a hack, we should extend the parametric suite to add derivatives infos") +//#pragma message WARN("This is a hack, we should extend the parametric suite to add derivatives infos") #endif if (effect) { if ( (effect->getPluginID() == PLUGINID_OFX_COLORCORRECT) || (effect->getPluginID() == PLUGINID_OFX_TIMEDISSOLVE) ) { diff --git a/Engine/ParallelRenderArgs.cpp b/Engine/ParallelRenderArgs.cpp index fbeab27a9..b489eb31f 100644 --- a/Engine/ParallelRenderArgs.cpp +++ b/Engine/ParallelRenderArgs.cpp @@ -414,7 +414,7 @@ EffectInstance::getInputsRoIsFunctor(bool useTransforms, ///Concatenate transforms if needed if (useTransforms) { fvRequest->globalData.transforms = std::make_shared(); -#pragma message WARN("TODO: can set draftRender properly here?") +//#pragma message WARN("TODO: can set draftRender properly here?") effect->tryConcatenateTransforms( time, /*draftRender=*/false, view, nodeRequest->mappedScale, fvRequest->globalData.transforms.get() ); } diff --git a/Engine/Project.cpp b/Engine/Project.cpp index b7a880ca4..4b30403bc 100644 --- a/Engine/Project.cpp +++ b/Engine/Project.cpp @@ -1190,7 +1190,7 @@ Project::getProjectDefaultFormat(Format *f) const ChoiceOption formatSpec = _imp->formatKnob->getActiveEntry(); // use the label here, because the id does not contain the format specifications. // see ProjectPrivate::generateStringFromFormat() -#pragma message WARN("TODO: can't we store the format somewhere instead of parsing the label???") +//#pragma message WARN("TODO: can't we store the format somewhere instead of parsing the label???") if ( !formatSpec.label.empty() ) { ProjectPrivate::generateFormatFromString(QString::fromUtf8( formatSpec.label.c_str() ), f); } else { diff --git a/Engine/ProjectPrivate.cpp b/Engine/ProjectPrivate.cpp index 462a32e17..03932084a 100644 --- a/Engine/ProjectPrivate.cpp +++ b/Engine/ProjectPrivate.cpp @@ -168,7 +168,7 @@ ProjectPrivate::restoreFromSerialization(const ProjectSerialization & obj, std::string optionID = choiceData->_choiceString; // first, try to get the id the easy way ( see choiceMatch() ) int id = isChoice->choiceRestorationId(choiceSerialized, optionID); -#pragma message WARN("TODO: choice id filters") +//#pragma message WARN("TODO: choice id filters") //if (id < 0) { // // no luck, try the filters // filterKnobChoiceOptionCompat(getPluginID(), serialization.getPluginMajorVersion(), serialization.getPluginMinorVersion(), projectInfos.vMajor, projectInfos.vMinor, projectInfos.vRev, serializedName, &optionID); diff --git a/Engine/ReadNode.cpp b/Engine/ReadNode.cpp index 7e1d247f1..4f86bb8f4 100644 --- a/Engine/ReadNode.cpp +++ b/Engine/ReadNode.cpp @@ -418,7 +418,7 @@ ReadNodePrivate::cloneGenericKnobs() std::string optionID = choiceData->_choiceString; // first, try to get the id the easy way ( see choiceMatch() ) int id = isChoice->choiceRestorationId(choiceSerialized, optionID); -#pragma message WARN("TODO: choice id filters") +//#pragma message WARN("TODO: choice id filters") //if (id < 0) { // // no luck, try the filters // filterKnobChoiceOptionCompat(getPluginID(), serialization.getPluginMajorVersion(), serialization.getPluginMinorVersion(), projectInfos.vMajor, projectInfos.vMinor, projectInfos.vRev, serializedName, &optionID); @@ -552,7 +552,7 @@ ReadNodePrivate::destroyReadNode() //This will remove the GUI of non generic parameters _publicInterface->recreateKnobs(true); -#pragma message WARN("TODO: if Gui, refresh pluginID, version, help tooltip in DockablePanel to reflect embedded node change") +//#pragma message WARN("TODO: if Gui, refresh pluginID, version, help tooltip in DockablePanel to reflect embedded node change") QMutexLocker k(&embeddedPluginMutex); if (embeddedPlugin) { @@ -793,7 +793,7 @@ ReadNodePrivate::createReadNode(bool throwErrors, //This will refresh the GUI with this Reader specific parameters _publicInterface->recreateKnobs(true); -#pragma message WARN("TODO: if Gui, refresh pluginID, version, help tooltip in DockablePanel to reflect embedded node change") +//#pragma message WARN("TODO: if Gui, refresh pluginID, version, help tooltip in DockablePanel to reflect embedded node change") KnobIPtr knob = node ? node->getKnobByName(kOfxImageEffectFileParamName) : _publicInterface->getKnobByName(kOfxImageEffectFileParamName); if (knob) { diff --git a/Engine/RotoContextPrivate.h b/Engine/RotoContextPrivate.h index 2c3751c52..aad27495e 100644 --- a/Engine/RotoContextPrivate.h +++ b/Engine/RotoContextPrivate.h @@ -1138,7 +1138,7 @@ struct RotoDrawableItemPrivate int defVal = 0; { std::vector choices; -#pragma message WARN("TODO: better sync with OFX filter param") +//#pragma message WARN("TODO: better sync with OFX filter param") // must be kept in sync with ofxsFilter.h choices.push_back(ChoiceOption("impulse", kFilterImpulse, tr(kFilterImpulseHint).toStdString())); choices.push_back(ChoiceOption("box", kFilterBox, tr(kFilterBoxHint).toStdString())); @@ -2081,7 +2081,7 @@ struct RotoContextPrivate shutterType->setDefaultValue(0); { std::vector options; -#pragma message WARN("TODO: sync with ofxsShutter") +//#pragma message WARN("TODO: sync with ofxsShutter") options.push_back(ChoiceOption("centered", "Centered", tr(kRotoShutterOffsetCenteredHint).toStdString())); options.push_back(ChoiceOption("start", "Start", tr(kRotoShutterOffsetStartHint).toStdString())); options.push_back(ChoiceOption("end", "End", tr(kRotoShutterOffsetEndHint).toStdString())); @@ -2139,7 +2139,7 @@ struct RotoContextPrivate globalShutterType->setHintToolTip( tr(kRotoShutterOffsetTypeParamHint) ); globalShutterType->setDefaultValue(0); { -#pragma message WARN("TODO: sync with ofxsShutter") +//#pragma message WARN("TODO: sync with ofxsShutter") std::vector options, helps; options.push_back("Centered"); helps.push_back(kRotoShutterOffsetCenteredHint); diff --git a/Engine/TrackerFrameAccessor.cpp b/Engine/TrackerFrameAccessor.cpp index c07f03670..708668f82 100644 --- a/Engine/TrackerFrameAccessor.cpp +++ b/Engine/TrackerFrameAccessor.cpp @@ -494,7 +494,7 @@ TrackerFrameAccessor::GetMaskForTrack(int clip, // https://developer.blender.org/rBb0015686e2e48a384a0b2a03a75f6daaad7271c0 // -#pragma message WARN("TODO: implement TrackerFrameAccessor::GetMaskForTrack") +//#pragma message WARN("TODO: implement TrackerFrameAccessor::GetMaskForTrack") return NULL; } diff --git a/Engine/ViewerInstance.cpp b/Engine/ViewerInstance.cpp index 9bb0d6566..5043a181b 100644 --- a/Engine/ViewerInstance.cpp +++ b/Engine/ViewerInstance.cpp @@ -962,7 +962,7 @@ ViewerInstance::getRegionsOfInterest(double /*time*/, ViewIdx /*view*/, RoIMap* ret) { -#pragma message WARN("2.2: fix this and only add RoI for thread local input") +//#pragma message WARN("2.2: fix this and only add RoI for thread local input") for (int i = 0; i < getNInputs(); ++i) { EffectInstancePtr input = getInput(i); if (input) { @@ -1503,7 +1503,7 @@ ViewerInstance::renderViewer_internal(ViewIdx view, stats->setGlobalRenderInfosForNode(getNode(), inArgs.params->rod, inArgs.params->srcPremult, channelsRendered, true, true, inArgs.params->mipMapLevel); } -#pragma message WARN("Implement Viewer so it accepts OpenGL Textures in input") +//#pragma message WARN("Implement Viewer so it accepts OpenGL Textures in input") BufferableObjectPtrList partialUpdateObjects; for (std::size_t rectIndex = 0; rectIndex < splitRoi.size(); ++rectIndex) { //AlphaImage will only be set when displaying the Matte overlay diff --git a/Engine/WriteNode.cpp b/Engine/WriteNode.cpp index ff5d790e8..47834783b 100644 --- a/Engine/WriteNode.cpp +++ b/Engine/WriteNode.cpp @@ -381,7 +381,7 @@ WriteNodePrivate::cloneGenericKnobs() std::string optionID = choiceData->_choiceString; // first, try to get the id the easy way ( see choiceMatch() ) int id = isChoice->choiceRestorationId(choiceSerialized, optionID); -#pragma message WARN("TODO: choice id filters") +//#pragma message WARN("TODO: choice id filters") //if (id < 0) { // // no luck, try the filters // filterKnobChoiceOptionCompat(getPluginID(), serialization.getPluginMajorVersion(), serialization.getPluginMinorVersion(), projectInfos.vMajor, projectInfos.vMinor, projectInfos.vRev, serializedName, &optionID); @@ -513,7 +513,7 @@ WriteNodePrivate::destroyWriteNode() //This will remove the GUI of non generic parameters _publicInterface->recreateKnobs(true); -#pragma message WARN("TODO: if Gui, refresh pluginID, version, help tooltip in DockablePanel to reflect embedded node change") +//#pragma message WARN("TODO: if Gui, refresh pluginID, version, help tooltip in DockablePanel to reflect embedded node change") if (embeddedNode) { embeddedNode->destroyNode(true, false); @@ -878,7 +878,7 @@ WriteNodePrivate::createWriteNode(bool throwErrors, //This will refresh the GUI with this Reader specific parameters _publicInterface->recreateKnobs(true); -#pragma message WARN("TODO: if Gui, refresh pluginID, version, help tooltip in DockablePanel to reflect embedded node change") +//#pragma message WARN("TODO: if Gui, refresh pluginID, version, help tooltip in DockablePanel to reflect embedded node change") KnobIPtr knob = writeNode ? writeNode->getKnobByName(kOfxImageEffectFileParamName) : _publicInterface->getKnobByName(kOfxImageEffectFileParamName); if (knob) { diff --git a/Gui/DocumentationManager.cpp b/Gui/DocumentationManager.cpp index c8ccaa4a7..ef0f42994 100644 --- a/Gui/DocumentationManager.cpp +++ b/Gui/DocumentationManager.cpp @@ -345,7 +345,7 @@ DocumentationManager::handler(QHttpRequest *req, html = parser(html, docDir); body = html.toUtf8(); } else if ( page == QString::fromUtf8("_group.html") ) { -#pragma message WARN("TODO: produce HTML from file templates") +//#pragma message WARN("TODO: produce HTML from file templates") // TODO: we should really read and parse _group.html or _groupChannel.html and just replace the relevant sections QString html; QString group; diff --git a/Gui/DopeSheetView.cpp b/Gui/DopeSheetView.cpp index 6ed9d80b6..ba3e34393 100644 --- a/Gui/DopeSheetView.cpp +++ b/Gui/DopeSheetView.cpp @@ -1984,7 +1984,7 @@ DopeSheetViewPrivate::computeRetimeRange(DSNode *retimer) FrameRange range; #ifdef DEBUG -#pragma message WARN("only considering first view") +//#pragma message WARN("only considering first view") #endif { const FrameRangesMap& rangeFirst = framesFirst[0]; diff --git a/Gui/Histogram.cpp b/Gui/Histogram.cpp index cbc4e9ce6..a4271f25c 100644 --- a/Gui/Histogram.cpp +++ b/Gui/Histogram.cpp @@ -1013,7 +1013,7 @@ HistogramPrivate::computeHistogram(Histogram::DisplayModeEnum channel) GLenum attachment = colorAttachmentFromDisplayMode(channel); #ifdef DEBUG -#pragma message WARN("TODO: ave currently bound VA, Buffer, and bound texture") +//#pragma message WARN("TODO: ave currently bound VA, Buffer, and bound texture") #endif /*binding the VAO holding managing the VBO*/ glBindVertexArray(vaoID); diff --git a/Gui/NodeGraph10.cpp b/Gui/NodeGraph10.cpp index 6d38c6200..0decd50bb 100644 --- a/Gui/NodeGraph10.cpp +++ b/Gui/NodeGraph10.cpp @@ -273,7 +273,7 @@ NodeGraph::mousePressEvent(QMouseEvent* e) if ( ( (nearbyItemCode == eNearbyItemNode) || (nearbyItemCode == eNearbyItemBackdropFrame) ) && groupEdited ) { assert(nearbyNode); -#pragma message WARN("TODO: if control is held, select all the nodes above, see https://github.com/NatronGitHub/Natron/issues/97") +//#pragma message WARN("TODO: if control is held, select all the nodes above, see https://github.com/NatronGitHub/Natron/issues/97") NodeGuiPtr selectedNode = nearbyNode->shared_from_this(); didSomething = true; diff --git a/Gui/ViewerGL.cpp b/Gui/ViewerGL.cpp index ebc5a30ab..399411480 100644 --- a/Gui/ViewerGL.cpp +++ b/Gui/ViewerGL.cpp @@ -3794,7 +3794,7 @@ ViewerGL::pickColorInternal(double x, bool /*pickInput*/) { -#pragma message WARN("Todo: use pickInput") +//#pragma message WARN("Todo: use pickInput") float r, g, b, a; QPointF imgPos; {