GCC warnings (#1725)

This commit is contained in:
Alexander Bock
2021-08-21 11:42:44 +02:00
committed by GitHub
parent 2f32ddaf28
commit db472030de
42 changed files with 67 additions and 97 deletions

View File

@@ -338,7 +338,6 @@ void RenderableTrail::internalRender(bool renderLines, bool renderPoints,
_programObject->setUniform(_uniformCache.nVertices, nVertices);
#if !defined(__APPLE__)
glm::ivec2 resolution = global::renderEngine->renderingResolution();
GLint viewport[4];
global::renderEngine->openglStateCache().viewport(viewport);
_programObject->setUniform(

View File

@@ -170,7 +170,7 @@ int renderCameraPath(lua_State* L) {
addDirectionLine(pointIdentifier(0), poses.front());
}
for (int i = 1; i < poses.size(); i++) {
for (int i = 1; i < static_cast<int>(poses.size()); i++) {
addPoint(pointIdentifier(i), poses[i].position);
addLineBetweenPoints(pointIdentifier(i), pointIdentifier(i - 1), PathColor, 4.f);

View File

@@ -200,13 +200,13 @@ std::string ExoplanetsModule::exoplanetsDataPath() const {
return absPath(
fmt::format("{}/{}", _exoplanetsDataFolder.value(), ExoplanetsDataFileName)
).string();
};
}
std::string ExoplanetsModule::lookUpTablePath() const {
return absPath(
fmt::format("{}/{}", _exoplanetsDataFolder, LookupTableFileName)
).string();
};
}
std::string ExoplanetsModule::bvColormapPath() const {
return _bvColorMapPath;

View File

@@ -370,8 +370,8 @@ void TimeQuantizer::setResolution(const std::string& resolutionString) {
}
void TimeQuantizer::verifyStartTimeRestrictions() {
//If monthly time resolution then restrict to 28 days so every month is consistent
unsigned int dayUpperLimit;
// If monthly time resolution then restrict to 28 days so every month is consistent
int dayUpperLimit;
std::string helpfulDescription = "the selected month";
if (_resolutionUnit == 'M') {
dayUpperLimit = 28;
@@ -631,7 +631,6 @@ std::vector<std::string> TimeQuantizer::quantized(Time& start, Time& end) {
const double startSeconds = s.J2000();
const double endSeconds = e.J2000();
const double delta = endSeconds - startSeconds;
ghoul_assert(
static_cast<int>(delta) % static_cast<int>(_resolution) == 0,
"Quantization error"

View File

@@ -134,8 +134,7 @@ RenderableSmallBody::RenderableSmallBody(const ghoul::Dictionary& dictionary)
}
if (dictionary.hasValue<bool>(ContiguousModeInfo.identifier)) {
_contiguousMode = static_cast<bool>(
dictionary.value<bool>(ContiguousModeInfo.identifier));
_contiguousMode = dictionary.value<bool>(ContiguousModeInfo.identifier);
}
else {
_contiguousMode = false;

View File

@@ -52,4 +52,4 @@ private:
} // namespace openspace
#endif __OPENSPACE_MODULE_STATEMACHINE___STATE___H__
#endif // __OPENSPACE_MODULE_STATEMACHINE___STATE___H__

View File

@@ -68,4 +68,4 @@ private:
} // namespace openspace
#endif __OPENSPACE_MODULE_STATEMACHINE___STATEMACHINE___H__
#endif // __OPENSPACE_MODULE_STATEMACHINE___STATEMACHINE___H__

View File

@@ -51,4 +51,4 @@ private:
} // namespace openspace
#endif __OPENSPACE_MODULE_STATEMACHINE___TRANSITION___H__
#endif // __OPENSPACE_MODULE_STATEMACHINE___TRANSITION___H__

View File

@@ -70,4 +70,4 @@ private:
} // namespace openspace
#endif __OPENSPACE_MODULE_STATEMACHINE___STATEMACHINEMODULE___H__
#endif // __OPENSPACE_MODULE_STATEMACHINE___STATEMACHINEMODULE___H__