mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-02-21 20:39:08 -06:00
Cleanup of code regarding ANSI C standard (mostly adding newlines at the end of files)
Updating SGCT and Ghoul references
This commit is contained in:
Submodule ext/ghoul updated: 36294ad9f4...c660815ff5
2
ext/sgct
2
ext/sgct
Submodule ext/sgct updated: 0a2d0241f4...70cde82e33
@@ -42,7 +42,7 @@ public:
|
||||
bool windowHasResized() const override;
|
||||
|
||||
double averageDeltaTime() const override;
|
||||
double deltaTime() const override;
|
||||
double deltaTime() const override;
|
||||
glm::vec2 mousePosition() const override;
|
||||
uint32_t mouseButtons(int maxNumber) const override;
|
||||
glm::ivec2 currentWindowSize() const override;
|
||||
|
||||
@@ -50,4 +50,4 @@ protected:
|
||||
} // namespace interaction
|
||||
} // namespace openspace
|
||||
|
||||
#endif // __CONTROLLER_H__
|
||||
#endif // __CONTROLLER_H__
|
||||
|
||||
@@ -52,4 +52,4 @@ private:
|
||||
|
||||
} // namespace openspace
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@@ -26,4 +26,4 @@ protected:
|
||||
|
||||
} // namespace openspace
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@@ -162,4 +162,4 @@ namespace openspace{
|
||||
|
||||
} // namespace openspace
|
||||
|
||||
#endif // __MESSAGESTRUCTURES_H__
|
||||
#endif // __MESSAGESTRUCTURES_H__
|
||||
|
||||
@@ -75,4 +75,4 @@ private:
|
||||
|
||||
} // namespace openspace
|
||||
|
||||
#endif // __NETWORKENGINE_H__
|
||||
#endif // __NETWORKENGINE_H__
|
||||
|
||||
@@ -205,4 +205,4 @@ namespace openspace{
|
||||
|
||||
} // namespace openspace
|
||||
|
||||
#endif // __OSPARALLELCONNECTION_H__
|
||||
#endif // __OSPARALLELCONNECTION_H__
|
||||
|
||||
@@ -125,4 +125,4 @@ private:
|
||||
} // namespace properties
|
||||
} // namespace openspace
|
||||
|
||||
#endif // __STRINGPROPERTY_H__
|
||||
#endif // __STRINGPROPERTY_H__
|
||||
|
||||
@@ -79,4 +79,4 @@ bool PropertyDelegate<TemplateProperty<std::vector<int>>>::toString(std::string&
|
||||
} // namespace properties
|
||||
} // namespace openspace
|
||||
|
||||
#endif // __SELECTIONPROPERTY_H__
|
||||
#endif // __SELECTIONPROPERTY_H__
|
||||
|
||||
@@ -35,4 +35,4 @@ REGISTER_TEMPLATEPROPERTY_HEADER(StringProperty, std::string);
|
||||
} // namespace properties
|
||||
} // namespace openspace
|
||||
|
||||
#endif // __STRINGPROPERTY_H__
|
||||
#endif // __STRINGPROPERTY_H__
|
||||
|
||||
@@ -48,4 +48,4 @@ std::vector<properties::Property*> allProperties();
|
||||
|
||||
} // namespace
|
||||
|
||||
#endif // __QUERY_H__
|
||||
#endif // __QUERY_H__
|
||||
|
||||
@@ -68,15 +68,15 @@ public:
|
||||
Post
|
||||
};
|
||||
|
||||
enum class FrametimeType {
|
||||
DtTimeAvg = 0,
|
||||
FPS,
|
||||
FPSAvg
|
||||
};
|
||||
enum class FrametimeType {
|
||||
DtTimeAvg = 0,
|
||||
FPS,
|
||||
FPSAvg
|
||||
};
|
||||
|
||||
static const std::string KeyFontMono;
|
||||
static const std::string KeyFontLight;
|
||||
static const std::vector<FrametimeType> FrametimeTypes;
|
||||
static const std::vector<FrametimeType> FrametimeTypes;
|
||||
|
||||
RenderEngine();
|
||||
~RenderEngine();
|
||||
@@ -104,7 +104,7 @@ public:
|
||||
|
||||
void takeScreenshot();
|
||||
void toggleInfoText(bool b);
|
||||
void toggleFrametimeType(int t);
|
||||
void toggleFrametimeType(int t);
|
||||
|
||||
// Performance measurements
|
||||
void setPerformanceMeasurements(bool performanceMeasurements);
|
||||
|
||||
@@ -214,4 +214,4 @@ namespace openspace {
|
||||
};
|
||||
} // namespace openspace
|
||||
|
||||
#endif // __CAMERA_H__
|
||||
#endif // __CAMERA_H__
|
||||
|
||||
@@ -116,4 +116,4 @@ private:
|
||||
|
||||
} // namespace openspace
|
||||
|
||||
#endif // SYNCBUFFER_H
|
||||
#endif // SYNCBUFFER_H
|
||||
|
||||
@@ -216,4 +216,4 @@ private:
|
||||
|
||||
} // namespace openspace
|
||||
|
||||
#endif // __RENDERABLEPLANET_H__
|
||||
#endif // __RENDERABLEPLANET_H__
|
||||
|
||||
@@ -28,6 +28,7 @@
|
||||
#include <openspace/engine/wrapper/windowwrapper.h>
|
||||
#include <openspace/rendering/renderengine.h>
|
||||
|
||||
#include <ghoul/opengl/programobject.h>
|
||||
#include <ghoul/io/texture/texturereader.h>
|
||||
#include <ghoul/filesystem/filesystem>
|
||||
|
||||
|
||||
@@ -32,9 +32,7 @@ in vec4 vs_position;
|
||||
#include "fragment.glsl"
|
||||
#include "PowerScaling/powerScaling_fs.hglsl"
|
||||
|
||||
|
||||
|
||||
Fragment getFragment(){
|
||||
Fragment getFragment() {
|
||||
Fragment frag;
|
||||
|
||||
// power scale coordinates for depth. w value is set to 1.0.
|
||||
@@ -44,6 +42,7 @@ Fragment getFragment(){
|
||||
if(frag.color.a == 0.0f){
|
||||
discard;
|
||||
}
|
||||
|
||||
frag.depth = denormalizeFloat(depth);
|
||||
|
||||
return frag;
|
||||
|
||||
@@ -36,6 +36,6 @@ out vec4 vs_position;
|
||||
|
||||
void main(){
|
||||
vs_st = in_st;
|
||||
vs_position = ViewProjectionMatrix*ModelTransform*in_position;
|
||||
vs_position = ViewProjectionMatrix * ModelTransform * in_position;
|
||||
gl_Position = vec4(vs_position);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -42,6 +42,7 @@
|
||||
|
||||
#include <modules/globebrowsing/chunk/chunknode.h>
|
||||
|
||||
#include <ghoul/opengl/textureunit.h>
|
||||
|
||||
|
||||
namespace ghoul {
|
||||
|
||||
@@ -96,4 +96,4 @@ namespace openspace {
|
||||
|
||||
} // namespace openspace
|
||||
|
||||
#endif // __AABB_H__
|
||||
#endif // __AABB_H__
|
||||
|
||||
@@ -71,4 +71,4 @@ protected:
|
||||
const int _ySegments;
|
||||
};
|
||||
} // namespace openspace
|
||||
#endif // __GRIDGEOMETRY_H__
|
||||
#endif // __GRIDGEOMETRY_H__
|
||||
|
||||
@@ -175,4 +175,4 @@ void TriangleSoup::drawUsingActiveProgram() {
|
||||
glBindVertexArray(0);
|
||||
}
|
||||
|
||||
} // namespace openspace
|
||||
} // namespace openspace
|
||||
|
||||
@@ -100,4 +100,4 @@ private:
|
||||
|
||||
} // namespace openspace
|
||||
|
||||
#endif // __TRIANGLESOUP_H__
|
||||
#endif // __TRIANGLESOUP_H__
|
||||
|
||||
@@ -21,9 +21,11 @@
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE *
|
||||
* OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. *
|
||||
****************************************************************************************/
|
||||
|
||||
#include <modules/iswa/rendering/textureplane.h>
|
||||
#include <openspace/engine/openspaceengine.h>
|
||||
#include <ghoul/opengl/texture.h>
|
||||
#include <ghoul/opengl/textureunit.h>
|
||||
|
||||
namespace {
|
||||
const std::string _loggerCat = "TexturePlane";
|
||||
|
||||
@@ -76,4 +76,5 @@ protected:
|
||||
};
|
||||
|
||||
} // namespace openspace
|
||||
#endif //__DATAPROCESSOR_H__
|
||||
|
||||
#endif //__DATAPROCESSOR_H__
|
||||
|
||||
@@ -75,4 +75,4 @@ private:
|
||||
};
|
||||
|
||||
}
|
||||
#endif //__HONGKANGPARSER_H__
|
||||
#endif //__HONGKANGPARSER_H__
|
||||
|
||||
@@ -73,4 +73,4 @@ std::vector<std::string> InstrumentDecoder::getTranslation(){
|
||||
return _spiceIDs;
|
||||
}
|
||||
|
||||
} // namespace openspace
|
||||
} // namespace openspace
|
||||
|
||||
@@ -75,4 +75,4 @@ private:
|
||||
bool _badDecoding;
|
||||
};
|
||||
}
|
||||
#endif //__LABELPARSER_H__
|
||||
#endif //__LABELPARSER_H__
|
||||
|
||||
@@ -50,4 +50,4 @@ void ScannerDecoder::setStopCommand(std::string stopCommand){
|
||||
_abort = stopCommand;
|
||||
}
|
||||
|
||||
} // namespace openspace
|
||||
} // namespace openspace
|
||||
|
||||
@@ -48,4 +48,4 @@ std::vector<std::string> TargetDecoder::getTranslation(){
|
||||
return _names;
|
||||
}
|
||||
|
||||
} // namespace openspace
|
||||
} // namespace openspace
|
||||
|
||||
@@ -63,7 +63,7 @@ double SGCTWindowWrapper::averageDeltaTime() const {
|
||||
}
|
||||
|
||||
double SGCTWindowWrapper::deltaTime() const {
|
||||
return sgct::Engine::instance()->getDt();
|
||||
return sgct::Engine::instance()->getDt();
|
||||
}
|
||||
|
||||
glm::vec2 SGCTWindowWrapper::mousePosition() const {
|
||||
|
||||
@@ -107,9 +107,9 @@ namespace openspace {
|
||||
const std::string RenderEngine::KeyFontMono = "Mono";
|
||||
const std::string RenderEngine::KeyFontLight = "Light";
|
||||
const std::vector<RenderEngine::FrametimeType> RenderEngine::FrametimeTypes({
|
||||
RenderEngine::FrametimeType::DtTimeAvg,
|
||||
RenderEngine::FrametimeType::FPS,
|
||||
RenderEngine::FrametimeType::FPSAvg
|
||||
RenderEngine::FrametimeType::DtTimeAvg,
|
||||
RenderEngine::FrametimeType::FPS,
|
||||
RenderEngine::FrametimeType::FPSAvg
|
||||
});
|
||||
|
||||
RenderEngine::RenderEngine()
|
||||
@@ -734,12 +734,12 @@ scripting::LuaLibrary RenderEngine::luaLibrary() {
|
||||
"bool",
|
||||
"Toggles the showing of render information on-screen text"
|
||||
},
|
||||
{
|
||||
"toggleFrametimeType",
|
||||
&luascriptfunctions::toggleFrametimeType,
|
||||
"int",
|
||||
"Toggle showing FPS or Average Frametime in heads up info"
|
||||
},
|
||||
{
|
||||
"toggleFrametimeType",
|
||||
&luascriptfunctions::toggleFrametimeType,
|
||||
"int",
|
||||
"Toggle showing FPS or Average Frametime in heads up info"
|
||||
},
|
||||
{
|
||||
"setPerformanceMeasurement",
|
||||
&luascriptfunctions::setPerformanceMeasurement,
|
||||
|
||||
@@ -64,4 +64,4 @@ bool Ephemeris::initialize() {
|
||||
|
||||
void Ephemeris::update(const UpdateData& data) {}
|
||||
|
||||
} // namespace openspace
|
||||
} // namespace openspace
|
||||
|
||||
@@ -55,4 +55,4 @@ void ProgressBar::print(int current) {
|
||||
_previous = iprogress;
|
||||
};
|
||||
|
||||
} // namespace openspace
|
||||
} // namespace openspace
|
||||
|
||||
@@ -65,4 +65,4 @@ const std::vector<ScreenLog::LogEntry>& ScreenLog::entries() const {
|
||||
return _entries;
|
||||
}
|
||||
|
||||
} // namespace openspace
|
||||
} // namespace openspace
|
||||
|
||||
@@ -68,7 +68,12 @@ function (set_compile_settings project)
|
||||
set_property(TARGET ${project} PROPERTY CXX_STANDARD_REQUIRED On)
|
||||
|
||||
if (MSVC)
|
||||
target_compile_options(${project} PUBLIC "/MP" "/ZI" "/wd4201" "/wd4127")
|
||||
target_compile_options(${project} PUBLIC
|
||||
"/MP" # Multi-threading support
|
||||
"/ZI" # Edit and continue support
|
||||
"/wd4201" # Disable nameless struct warning
|
||||
"/wd4127" # Disable conditional expression is constant warning
|
||||
)
|
||||
if (OPENSPACE_WARNINGS_AS_ERRORS)
|
||||
target_compile_options(${project} PUBLIC "/WX")
|
||||
endif ()
|
||||
|
||||
Reference in New Issue
Block a user