Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
Main Repositories
otb
Commits
544cb182
Commit
544cb182
authored
Mar 30, 2020
by
Cédric Traizet
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'fix_warnings' into 'develop'
Fix warnings Closes
#2015
See merge request
!696
parents
3b6edf74
cc952a40
Pipeline
#4090
passed with stages
in 89 minutes and 29 seconds
Changes
21
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
21 changed files
with
89 additions
and
73 deletions
+89
-73
Examples/Simulation/LAIAndPROSAILToSensorResponse.cxx
Examples/Simulation/LAIAndPROSAILToSensorResponse.cxx
+2
-2
Modules/Adapters/GdalAdapters/include/otbOGRDriversInit.h
Modules/Adapters/GdalAdapters/include/otbOGRDriversInit.h
+6
-3
Modules/Adapters/GdalAdapters/include/otbSpatialReference.h
Modules/Adapters/GdalAdapters/include/otbSpatialReference.h
+4
-1
Modules/Adapters/GdalAdapters/src/otbCoordinateTransformation.cxx
...Adapters/GdalAdapters/src/otbCoordinateTransformation.cxx
+7
-0
Modules/Adapters/GdalAdapters/src/otbOGRGeometryWrapper.cxx
Modules/Adapters/GdalAdapters/src/otbOGRGeometryWrapper.cxx
+9
-0
Modules/Adapters/GdalAdapters/src/otbSpatialReference.cxx
Modules/Adapters/GdalAdapters/src/otbSpatialReference.cxx
+1
-1
Modules/Adapters/GdalAdapters/test/otbOGRDataSourceWrapperNew.cxx
...Adapters/GdalAdapters/test/otbOGRDataSourceWrapperNew.cxx
+1
-0
Modules/Core/Functor/include/otbVariadicInputsImageFilter.h
Modules/Core/Functor/include/otbVariadicInputsImageFilter.h
+3
-1
Modules/Filtering/Projection/test/otbSensorModel.cxx
Modules/Filtering/Projection/test/otbSensorModel.cxx
+3
-1
Modules/IO/IOGDAL/test/otbGDALImageIOTestWriteMetadata.cxx
Modules/IO/IOGDAL/test/otbGDALImageIOTestWriteMetadata.cxx
+11
-0
Modules/IO/IOGDAL/test/otbGDALReadPxlComplex.cxx
Modules/IO/IOGDAL/test/otbGDALReadPxlComplex.cxx
+9
-0
Modules/IO/ImageIO/include/otbMultiImageFileWriter.hxx
Modules/IO/ImageIO/include/otbMultiImageFileWriter.hxx
+2
-1
Modules/Remote/diapotb.remote.cmake
Modules/Remote/diapotb.remote.cmake
+1
-1
Modules/Remote/otbGRM.remote.cmake
Modules/Remote/otbGRM.remote.cmake
+1
-1
Modules/ThirdParty/OssimPlugins/test/ossimStringUtilitiesTest.cpp
...ThirdParty/OssimPlugins/test/ossimStringUtilitiesTest.cpp
+1
-1
Modules/ThirdParty/OssimPlugins/test/ossimTimeUtilitiesTest.cpp
...s/ThirdParty/OssimPlugins/test/ossimTimeUtilitiesTest.cpp
+1
-1
Modules/Visualization/Ice/include/otbGlError.h
Modules/Visualization/Ice/include/otbGlError.h
+22
-1
Modules/Visualization/Ice/src/CMakeLists.txt
Modules/Visualization/Ice/src/CMakeLists.txt
+0
-1
Modules/Visualization/Ice/src/otbGlError.cxx
Modules/Visualization/Ice/src/otbGlError.cxx
+0
-52
Modules/Visualization/Ice/src/otbGlMesh.cxx
Modules/Visualization/Ice/src/otbGlMesh.cxx
+2
-2
Modules/Visualization/MonteverdiGui/src/mvdImageViewWidget.cxx
...es/Visualization/MonteverdiGui/src/mvdImageViewWidget.cxx
+3
-3
No files found.
Examples/Simulation/LAIAndPROSAILToSensorResponse.cxx
View file @
544cb182
...
...
@@ -168,8 +168,8 @@ public:
using
AcquistionParameterType
=
TAcquistionParameter
;
using
SatRSRType
=
TSatRSR
;
using
SatRSRPointerType
=
typename
SatRSRType
::
Pointer
;
using
ProspectType
=
typename
otb
::
ProspectModel
;
using
SailType
=
typename
otb
::
SailModel
;
using
ProspectType
=
otb
::
ProspectModel
;
using
SailType
=
otb
::
SailModel
;
using
PrecisionType
=
double
;
using
PairType
=
std
::
pair
<
PrecisionType
,
PrecisionType
>
;
...
...
Modules/Adapters/GdalAdapters/include/otbOGRDriversInit.h
View file @
544cb182
...
...
@@ -21,8 +21,6 @@
#ifndef otbOGRDriversInit_h
#define otbOGRDriversInit_h
#include <boost/noncopyable.hpp>
#include "OTBGdalAdaptersExport.h"
namespace
otb
...
...
@@ -45,7 +43,7 @@ namespace ogr
* VC++)
* - Non-copyable
*/
class
OTBGdalAdapters_EXPORT
Drivers
:
private
boost
::
noncopyable
class
OTBGdalAdapters_EXPORT
Drivers
{
/** \name Singleton related functions */
//@{
...
...
@@ -59,6 +57,11 @@ private:
Drivers
();
/** Destructor. */
~
Drivers
()
=
default
;
/** Non copyable class */
Drivers
(
const
Drivers
&
)
=
delete
;
Drivers
&
operator
=
(
const
Drivers
&
)
=
delete
;
//@}
};
}
...
...
Modules/Adapters/GdalAdapters/include/otbSpatialReference.h
View file @
544cb182
...
...
@@ -21,7 +21,6 @@
#define otbSpatialReference_h
#include "OTBGdalAdaptersExport.h"
#include "ogr_spatialref.h"
#include <memory>
#include <string>
...
...
@@ -34,6 +33,10 @@
// to have dll-interface to be used by clients of class 'otb::SpatialReference'
// As long as otb::SpatialReference::m_SR is private no need to export this type.
#endif
// causes warning C4251 on Windows
#include "ogr_spatialref.h"
class
OGRSpatialReference
;
namespace
otb
...
...
Modules/Adapters/GdalAdapters/src/otbCoordinateTransformation.cxx
View file @
544cb182
...
...
@@ -20,7 +20,14 @@
#include "otbCoordinateTransformation.h"
#ifdef _MSC_VER
#pragma warning(push)
#pragma warning(disable : 4251)
#include "ogr_spatialref.h"
#pragma warning(pop)
#else
#include "ogr_spatialref.h"
#endif
#include <sstream>
#include <stdexcept>
...
...
Modules/Adapters/GdalAdapters/src/otbOGRGeometryWrapper.cxx
View file @
544cb182
...
...
@@ -23,7 +23,16 @@
/*===============================[ Includes ]================================*/
/*===========================================================================*/
#include "otbOGRGeometryWrapper.h"
#ifdef _MSC_VER
#pragma warning(push)
#pragma warning(disable : 4251)
#include "ogr_geometry.h"
#pragma warning(pop)
#else
#include "ogr_geometry.h"
#endif
#ifdef _MSC_VER
// warning conversion int -> bool
...
...
Modules/Adapters/GdalAdapters/src/otbSpatialReference.cxx
View file @
544cb182
...
...
@@ -20,7 +20,7 @@
#include "otbSpatialReference.h"
#include "ogr_spatialref.h"
#include "cpl_conv.h"
#ifdef __clang__
#pragma clang diagnostic ignored "-Wunused-local-typedefs"
...
...
Modules/Adapters/GdalAdapters/test/otbOGRDataSourceWrapperNew.cxx
View file @
544cb182
...
...
@@ -27,6 +27,7 @@
#if defined(__GNUC__) || defined(__clang__)
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wunused-parameter"
#pragma GCC diagnostic ignored "-Woverloaded-virtual"
#include <boost/test/unit_test.hpp>
#pragma GCC diagnostic pop
#else
...
...
Modules/Core/Functor/include/otbVariadicInputsImageFilter.h
View file @
544cb182
...
...
@@ -145,7 +145,9 @@ private:
template
<
class
Tuple
,
size_t
...
Is
>
void
SetInputsImpl
(
Tuple
&
t
,
std
::
index_sequence
<
Is
...
>
)
{
std
::
initializer_list
<
int
>
{(
this
->
template
SetInput
<
Is
>(
std
::
get
<
Is
>
(
t
)),
0
)...};
// Will be easier to write in c++17 with fold expressions
// (this->template SetInput<Is>(std::get<Is>(t)),...);
(
void
)
std
::
initializer_list
<
int
>
{(
this
->
template
SetInput
<
Is
>(
std
::
get
<
Is
>
(
t
)),
0
)...};
}
template
<
size_t
...
Is
>
...
...
Modules/Filtering/Projection/test/otbSensorModel.cxx
View file @
544cb182
...
...
@@ -39,13 +39,15 @@
#if defined(__GNUC__) || defined(__clang__)
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wunused-parameter"
#pragma GCC diagnostic ignored "-Woverloaded-virtual"
#include "ossim/projection/ossimProjection.h"
#include "ossim/projection/ossimSensorModelFactory.h"
#pragma GCC diagnostic pop
#else
#include "ossim/projection/ossimProjection.h"
#include "ossim/projection/ossimSensorModelFactory.h"
#endif
#include "ossim/projection/ossimSensorModelFactory.h"
#include "ossim/ossimPluginProjectionFactory.h"
...
...
Modules/IO/IOGDAL/test/otbGDALImageIOTestWriteMetadata.cxx
View file @
544cb182
...
...
@@ -23,9 +23,20 @@
#include <fstream>
#include <sstream>
#ifdef _MSC_VER
#pragma warning(push)
#pragma warning(disable : 4251)
#include "gdal_priv.h"
#include "cpl_string.h"
#include "ogr_spatialref.h"
#pragma warning(pop)
#else
#include "gdal_priv.h"
#include "cpl_string.h"
#include "ogr_spatialref.h"
#endif
#include "itkMacro.h"
// Class to store ProjRef, GEOTransform and GCP info
...
...
Modules/IO/IOGDAL/test/otbGDALReadPxlComplex.cxx
View file @
544cb182
...
...
@@ -19,8 +19,17 @@
*/
#ifdef _MSC_VER
#pragma warning(push)
#pragma warning(disable : 4251)
#include "gdal_priv.h"
#include "ogr_core.h"
#pragma warning(pop)
#else
#include "gdal_priv.h"
#include "ogr_core.h"
#endif
#include <iostream>
#include <complex>
...
...
Modules/IO/ImageIO/include/otbMultiImageFileWriter.hxx
View file @
544cb182
...
...
@@ -91,7 +91,8 @@ MultiImageFileWriter::Sink<TImage>::GetRegionToWrite() const
throw
e
;
}
typename
itk
::
ImageRegion
<
2
>::
IndexType
start
{{
boxVector
[
0
],
boxVector
[
1
]}};
// indices are signed, sizes are unsigned
typename
itk
::
ImageRegion
<
2
>::
IndexType
start
{{
static_cast
<
int
>
(
boxVector
[
0
]),
static_cast
<
int
>
(
boxVector
[
1
])}};
typename
itk
::
ImageRegion
<
2
>::
SizeType
size
{{
boxVector
[
2
],
boxVector
[
3
]}};
itk
::
ImageRegion
<
2
>
regionToWrite
{
start
,
size
};
regionToWrite
.
Crop
(
m_InputImage
->
GetLargestPossibleRegion
());
...
...
Modules/Remote/diapotb.remote.cmake
View file @
544cb182
...
...
@@ -22,5 +22,5 @@
otb_fetch_module
(
DiapOTBModule
"OTB module for SAR processing in Diapason."
GIT_REPOSITORY https://gitlab.orfeo-toolbox.org/remote_modules/diapotb.git
GIT_TAG
79f48869d2a50d588c35560df5ee9dac646418a8
GIT_TAG
f84b85352abb75ff3eefafdf0480fcde7fa06173
)
Modules/Remote/otbGRM.remote.cmake
View file @
544cb182
...
...
@@ -32,5 +32,5 @@ A more detailed description can be found on the project website:
http://tully.ups-tlse.fr/lassallep/grm
"
GIT_REPOSITORY https://github.com/orfeotoolbox/GRM
GIT_TAG
d8baf51a70207e5e39adb74be1698a27784df10b
GIT_TAG
459943a6fde517cc0dd601dfaca3400e3f1788de
)
Modules/ThirdParty/OssimPlugins/test/ossimStringUtilitiesTest.cpp
View file @
544cb182
...
...
@@ -25,7 +25,7 @@
#if defined(__GNUC__) || defined(__clang__)
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wunused-parameter"
//
#pragma GCC diagnostic ignored "-Woverloaded-virtual"
#pragma GCC diagnostic ignored "-Woverloaded-virtual"
#pragma GCC diagnostic ignored "-Wshadow"
#endif
...
...
Modules/ThirdParty/OssimPlugins/test/ossimTimeUtilitiesTest.cpp
View file @
544cb182
...
...
@@ -25,7 +25,7 @@
#if defined(__GNUC__) || defined(__clang__)
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wunused-parameter"
//
#pragma GCC diagnostic ignored "-Woverloaded-virtual"
#pragma GCC diagnostic ignored "-Woverloaded-virtual"
#pragma GCC diagnostic ignored "-Wshadow"
#endif
...
...
Modules/Visualization/Ice/include/otbGlError.h
View file @
544cb182
...
...
@@ -34,6 +34,13 @@
#include <iostream>
#include <stdexcept>
#include <sstream>
#ifdef _MSC_VER
#pragma warning(push)
#pragma warning(disable: 4275) // warning C4275: non-DLL-interface std::runtime_error used as base for DLL-interface Error
#endif
namespace
otb
{
namespace
gl
{
...
...
@@ -44,7 +51,17 @@ struct OTBIce_EXPORT Error : public std::runtime_error
{
/** Construct an OpenGL exception related to the OpenGL error code.
*/
Error
(
GLenum
code
);
Error
(
GLenum
code
)
:
std
::
runtime_error
(
[
code
]()
{
std
::
ostringstream
oss
;
oss
<<
"OpenGL error #"
<<
code
<<
": '"
<<
gluErrorString
(
code
)
<<
"'"
;
return
oss
.
str
();
}()
)
{}
};
// End class GlError
...
...
@@ -93,4 +110,8 @@ CheckError()
}
// End namespace otb.
#ifdef _MSC_VER
#pragma warning(pop)
#endif
#endif // otb_GlError_h
Modules/Visualization/Ice/src/CMakeLists.txt
View file @
544cb182
...
...
@@ -21,7 +21,6 @@
set
(
OTBICE_SRCS
otbGeoInterface.cxx
otbGlActor.cxx
otbGlError.cxx
otbGlImageActor.cxx
otbGlMesh.cxx
otbGlROIActor.cxx
...
...
Modules/Visualization/Ice/src/otbGlError.cxx
deleted
100644 → 0
View file @
3b6edf74
/*
* Copyright (C) 2005-2019 Centre National d'Etudes Spatiales (CNES)
*
* This file is part of Orfeo Toolbox
*
* https://www.orfeo-toolbox.org/
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include "otbGlError.h"
#include <sstream>
// This
namespace
otb
{
namespace
gl
{
Error
::
Error
(
GLenum
code
)
:
std
::
runtime_error
(
[
code
]()
{
std
::
ostringstream
oss
;
oss
<<
"OpenGL error #"
<<
code
<<
": '"
<<
gluErrorString
(
code
)
<<
"'"
;
return
oss
.
str
();
}()
)
{
}
}
// End namespace 'gl'.
}
// End namespace 'otb'.
Modules/Visualization/Ice/src/otbGlMesh.cxx
View file @
544cb182
...
...
@@ -112,10 +112,10 @@ Mesh
glVertexAttribPointer
(
id
,
components
,
static_cast
<
GLint
>
(
components
)
,
m_VBO
.
GlType
(),
GL_FALSE
,
m_VBO
.
Stride
(
components
),
static_cast
<
GLsizei
>
(
m_VBO
.
Stride
(
components
)
),
reinterpret_cast
<
GLvoid
const
*
>
(
first
*
m_VBO
.
Size
()
)
);
...
...
Modules/Visualization/MonteverdiGui/src/mvdImageViewWidget.cxx
View file @
544cb182
...
...
@@ -701,15 +701,15 @@ void ImageViewWidget::ListGlVersions() const
switch
(
format
().
profile
()
)
{
case
Q
GL
Format
::
NoProfile
:
case
Q
Surface
Format
::
NoProfile
:
qWarning
()
<<
"QGLFormat::NoProfile"
;
break
;
case
Q
GL
Format
::
CoreProfile
:
case
Q
Surface
Format
::
CoreProfile
:
qWarning
()
<<
"QGLFormat::CoreProfile"
;
break
;
case
Q
GL
Format
::
CompatibilityProfile
:
case
Q
Surface
Format
::
CompatibilityProfile
:
qWarning
()
<<
"QGLFormat::CompatibilityProfile"
;
break
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment