Skip to content

Commit

Permalink
Lint: Suppress or fix cpplint2 warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
ptheywood committed Nov 21, 2024
1 parent dab83d0 commit 4092fcb
Show file tree
Hide file tree
Showing 36 changed files with 94 additions and 4 deletions.
2 changes: 1 addition & 1 deletion CPPLINT.cfg
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
set noparent
linelength=240
filter=-legal/copyright,-readability/todo,-runtime/references,-build/c++11
filter=-legal/copyright,-readability/todo,-runtime/references,-build/c++11,-build/c++17,-whitespace/indent_namespace,-whitespace/newline
extensions=c++,hpp,cxx,cpp,cuh,hh,h++,h,hxx,cu,cc,c,inl
headers=hpp,cuh,hh,h,h++,hxx,inl
1 change: 1 addition & 0 deletions include/flamegpu/visualiser/config/AgentStateConfig.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

#include <string>
#include <cstring>
#include <cstdio>
#include <map>

#include "TexBufferConfig.h"
Expand Down
1 change: 1 addition & 0 deletions include/flamegpu/visualiser/config/ModelConfig.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
#include <list>
#include <map>
#include <memory>
#include <cstdio>

#include "LineConfig.h"
#include "PanelConfig.h"
Expand Down
2 changes: 2 additions & 0 deletions src/flamegpu/visualiser/Draw.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
#include "Draw.h"

#include <stdexcept>
#include <utility>
#include <string>

#include "flamegpu/visualiser/util/StringUtils.h"

Expand Down
3 changes: 3 additions & 0 deletions src/flamegpu/visualiser/Entity.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@
#include <locale>
#include <string>
#include <cstring>
#include <cstdio>
#include <vector>
#include <memory>

#include <glm/gtx/component_wise.hpp>
#include <glm/gtc/matrix_transform.hpp>
Expand Down
2 changes: 2 additions & 0 deletions src/flamegpu/visualiser/FLAMEGPU_Visualisation.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
#include "flamegpu/visualiser/FLAMEGPU_Visualisation.h"

#include <mutex>
#include <map>
#include <string>

#include "Visualiser.h"

Expand Down
3 changes: 3 additions & 0 deletions src/flamegpu/visualiser/HUD.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
#include "HUD.h"

#include <memory>
#include <list>

#include "flamegpu/visualiser/util/warnings.h"

DISABLE_WARNING_PUSH
Expand Down
5 changes: 5 additions & 0 deletions src/flamegpu/visualiser/Visualiser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@
#include <iomanip>
#include <sstream>
#include <algorithm>
#include <map>
#include <utility>
#include <memory>
#include <cstdio>
#include <string>

#include <glm/gtc/matrix_transform.hpp>

Expand Down
4 changes: 4 additions & 0 deletions src/flamegpu/visualiser/model/Material.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
#include "flamegpu/visualiser/model/Material.h"

#include <cstdio>
#include <vector>

#include "flamegpu/visualiser/texture/Texture2D.h"

namespace flamegpu {
Expand Down
4 changes: 4 additions & 0 deletions src/flamegpu/visualiser/multipass/BackBuffer.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
#include "flamegpu/visualiser/multipass/BackBuffer.h"

#include <memory>
#include <cstdio>

#include <glm/gtx/component_wise.hpp>

namespace flamegpu {
Expand Down
3 changes: 3 additions & 0 deletions src/flamegpu/visualiser/multipass/FrameBuffer.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
#include "flamegpu/visualiser/multipass/FrameBuffer.h"

#include <cstdio>
#include <memory>

#include "flamegpu/visualiser/texture/Texture2D.h"
#include "flamegpu/visualiser/texture/Texture2D_Multisample.h"
#include "flamegpu/visualiser/multipass/RenderBuffer.h"
Expand Down
2 changes: 2 additions & 0 deletions src/flamegpu/visualiser/multipass/RenderBuffer.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#include "flamegpu/visualiser/multipass/RenderBuffer.h"

#include <memory>

namespace flamegpu {
namespace visualiser {

Expand Down
2 changes: 2 additions & 0 deletions src/flamegpu/visualiser/shader/DirectionFunction.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#include "flamegpu/visualiser/shader/DirectionFunction.h"

#include <map>
#include <string>
#include <sstream>


Expand Down
3 changes: 2 additions & 1 deletion src/flamegpu/visualiser/shader/PositionFunction.cpp
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
#include "flamegpu/visualiser/shader/PositionFunction.h"

#include <map>
#include <string>
#include <sstream>


namespace flamegpu {
namespace visualiser {

Expand Down
2 changes: 2 additions & 0 deletions src/flamegpu/visualiser/shader/ScaleFunction.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#include "flamegpu/visualiser/shader/ScaleFunction.h"

#include <map>
#include <string>
#include <sstream>

namespace flamegpu {
Expand Down
6 changes: 6 additions & 0 deletions src/flamegpu/visualiser/shader/ShaderCore.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,13 @@
#include "flamegpu/visualiser/shader/ShaderCore.h"
#include <cstdlib> // < _splitpath() Windows only, need to rewrite linux ver
#include <cstdio>
#include <regex>
#include <sstream>
#include <list>
#include <map>
#include <utility>
#include <string>
#include <vector>
#include "flamegpu/visualiser/util/warnings.h"
DISABLE_WARNING_PUSH
#include <glm/gtc/type_ptr.hpp>
Expand Down
3 changes: 3 additions & 0 deletions src/flamegpu/visualiser/shader/Shaders.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@
#include <cstdlib>
#include <utility>
#include <stdexcept>
#include <vector>
#include <list>
#include <string>

#include "flamegpu/visualiser/util/warnings.h"

Expand Down
3 changes: 2 additions & 1 deletion src/flamegpu/visualiser/shader/VertexFunction.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
#include "flamegpu/visualiser/shader/VertexFunction.h"

#include <sstream>

#include <map>
#include <string>

namespace flamegpu {
namespace visualiser {
Expand Down
1 change: 1 addition & 0 deletions src/flamegpu/visualiser/shader/buffer/BufferCore.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#include "flamegpu/visualiser/shader/buffer/BufferCore.h"

#include <cstdio>
#include <memory>

#include "flamegpu/visualiser/util/GLcheck.h"
Expand Down
2 changes: 2 additions & 0 deletions src/flamegpu/visualiser/shader/buffer/ShaderStorageBuffer.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#include "flamegpu/visualiser/shader/buffer/ShaderStorageBuffer.h"

#include <set>

#include "flamegpu/visualiser/util/GLcheck.h"

namespace flamegpu {
Expand Down
1 change: 1 addition & 0 deletions src/flamegpu/visualiser/shader/buffer/UniformBuffer.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include "flamegpu/visualiser/shader/buffer/UniformBuffer.h"

#include <memory>
#include <set>

#include "flamegpu/visualiser/util/GLcheck.h"

Expand Down
2 changes: 2 additions & 0 deletions src/flamegpu/visualiser/shader/lights/LightsBuffer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

#include <memory>
#include <stdexcept>
#include <set>
#include <cstdio>

#include "flamegpu/visualiser/shader/lights/PointLight.h"
#include "flamegpu/visualiser/shader/lights/SpotLight.h"
Expand Down
4 changes: 4 additions & 0 deletions src/flamegpu/visualiser/texture/Texture.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@
#include <SDL_surface.h>

#include <algorithm>
#include <cstdio>
#include <map>
#include <memory>
#include <string>

#include "flamegpu/visualiser/util/StringUtils.h"
#include "flamegpu/visualiser/util/Resources.h"
Expand Down
4 changes: 4 additions & 0 deletions src/flamegpu/visualiser/texture/Texture2D.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
#include "flamegpu/visualiser/texture/Texture2D.h"
#include <cassert>
#include <filesystem>
#include <unordered_map>
#include <memory>
#include <string>
#include <cstdio>

#include <glm/gtx/component_wise.hpp>
#include <SDL_surface.h>
Expand Down
1 change: 1 addition & 0 deletions src/flamegpu/visualiser/texture/Texture2D.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
#include <locale>
#include <string>
#include <algorithm>
#include <cstdio>

#include <glm/vec2.hpp>

Expand Down
3 changes: 3 additions & 0 deletions src/flamegpu/visualiser/texture/Texture2D_Multisample.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
#include "flamegpu/visualiser/texture/Texture2D_Multisample.h"

#include <cstdio>
#include <memory>

namespace flamegpu {
namespace visualiser {

Expand Down
3 changes: 3 additions & 0 deletions src/flamegpu/visualiser/texture/TextureBuffer.cu.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
#include "flamegpu/visualiser/texture/TextureBuffer.h"

#include <cstdio>
#include <memory>

namespace flamegpu {
namespace visualiser {

Expand Down
6 changes: 6 additions & 0 deletions src/flamegpu/visualiser/texture/TextureCubeMap.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
#include "flamegpu/visualiser/texture/TextureCubeMap.h"

#include <cstdio>
#include <memory>
#include <unordered_map>
#include <string>

#include <glm/gtx/component_wise.hpp>

namespace flamegpu {
Expand Down
2 changes: 2 additions & 0 deletions src/flamegpu/visualiser/ui/Overlay.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#include "Overlay.h"

#include <memory>

#include "flamegpu/visualiser/util/warnings.h"
DISABLE_WARNING_PUSH
#include <glm/gtc/type_ptr.hpp>
Expand Down
3 changes: 3 additions & 0 deletions src/flamegpu/visualiser/ui/SplashScreen.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
#include "flamegpu/visualiser/ui/SplashScreen.h"

#include <cstdio>
#include <memory>
#include <string>
#include <vector>

#include "flamegpu/visualiser/ui/Sprite2D.h"
#include "flamegpu/visualiser/ui/Text.h"
Expand Down
3 changes: 3 additions & 0 deletions src/flamegpu/visualiser/ui/Sprite2D.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#include "Sprite2D.h"

#include <memory>

#include "flamegpu/visualiser/shader/Shaders.h"

namespace flamegpu {
Expand Down
4 changes: 3 additions & 1 deletion src/flamegpu/visualiser/ui/Text.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@

#include <freetype/ftglyph.h>

#include <vector>
#include <cstdarg>
#include <cstdio>
#include <string>
#include <vector>

#include "flamegpu/visualiser/util/warnings.h"
#include "flamegpu/visualiser/util/fonts.h"
Expand Down
3 changes: 3 additions & 0 deletions src/flamegpu/visualiser/util/Resources.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
#include "flamegpu/visualiser/util/Resources.h"
#include "VisException.h"

#include <cstdio>
#include <filesystem>
#include <string>

#include <cmrc/cmrc.hpp>
#include <SDL.h>
Expand Down
1 change: 1 addition & 0 deletions src/flamegpu/visualiser/util/VisException.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

#include <cstdio>
#include <cstring>
#include <string>
#include <sstream>
#include <limits>

Expand Down
1 change: 1 addition & 0 deletions src/flamegpu/visualiser/util/cuda.cu
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
#include <device_launch_parameters.h>

#include <cstring>
#include <cstdio>
#include <typeinfo> // operator typeid
#include <stdexcept>

Expand Down
3 changes: 3 additions & 0 deletions src/flamegpu/visualiser/util/fonts.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

#include <stdio.h>
#include <fontconfig/fontconfig.h>
#include <string>

namespace flamegpu {
namespace visualiser {
Expand Down Expand Up @@ -130,6 +131,8 @@ std::string findFont(std::initializer_list<const char *> fontNames, const Generi
// https://docs.microsoft.com/en-us/windows/win32/api/dwrite/nn-dwrite-idwritefontcollection
#include <dwrite.h>

#include <string>

namespace flamegpu {
namespace visualiser {
namespace fonts {
Expand Down

0 comments on commit 4092fcb

Please sign in to comment.