Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Gepetto
OpenSceneGraph
Commits
e0d5e4b0
Commit
e0d5e4b0
authored
Aug 26, 2020
by
Robert Osfield
Browse files
Fixed warnings reported by gcc-9.3.0
parent
50de0c25
Changes
12
Hide whitespace changes
Inline
Side-by-side
include/osg/BoundingSphere
View file @
e0d5e4b0
...
...
@@ -63,6 +63,13 @@ class BoundingSphereImpl
* otherwise. */
inline
bool
valid
()
const
{
return
_radius
>=
0.0
;
}
inline
BoundingSphereImpl
&
operator
=
(
const
BoundingSphereImpl
&
rhs
)
{
_center
=
rhs
.
_center
;
_radius
=
rhs
.
_radius
;
return
*
this
;
}
inline
bool
operator
==
(
const
BoundingSphereImpl
&
rhs
)
const
{
return
_center
==
rhs
.
_center
&&
_radius
==
rhs
.
_radius
;
}
inline
bool
operator
!=
(
const
BoundingSphereImpl
&
rhs
)
const
{
return
_center
!=
rhs
.
_center
||
_radius
!=
rhs
.
_radius
;
}
...
...
include/osg/GLExtensions
View file @
e0d5e4b0
...
...
@@ -166,6 +166,15 @@ class VertexAttribAlias
_osgName
(
osgName
),
_declaration
(
declaration
)
{}
VertexAttribAlias
&
operator
=
(
const
VertexAttribAlias
&
rhs
)
{
_location
=
rhs
.
_location
;
_glName
=
rhs
.
_glName
;
_osgName
=
rhs
.
_osgName
;
_declaration
=
rhs
.
_declaration
;
return
*
this
;
}
GLuint
_location
;
std
::
string
_glName
;
std
::
string
_osgName
;
...
...
include/osg/MatrixTemplate
View file @
e0d5e4b0
...
...
@@ -115,6 +115,13 @@ class Matrix2Template : public TemplateMatrix<T, 2, 2>
}
~
Matrix2Template
()
{}
Matrix2Template
&
operator
=
(
const
Matrix2Template
&
rhs
)
{
if
(
&
rhs
==
this
)
return
*
this
;
set
(
rhs
.
ptr
());
return
*
this
;
}
using
base_class
::
set
;
void
set
(
value_type
a00
,
value_type
a01
,
...
...
@@ -150,6 +157,13 @@ class Matrix2x3Template : public TemplateMatrix<T, 2, 3>
}
~
Matrix2x3Template
()
{}
Matrix2x3Template
&
operator
=
(
const
Matrix2x3Template
&
rhs
)
{
if
(
&
rhs
==
this
)
return
*
this
;
set
(
rhs
.
ptr
());
return
*
this
;
}
using
base_class
::
set
;
void
set
(
value_type
a00
,
value_type
a01
,
value_type
a02
,
...
...
@@ -179,6 +193,13 @@ class Matrix2x4Template : public TemplateMatrix<T, 2, 4>
}
~
Matrix2x4Template
()
{}
Matrix2x4Template
&
operator
=
(
const
Matrix2x4Template
&
rhs
)
{
if
(
&
rhs
==
this
)
return
*
this
;
set
(
rhs
.
ptr
());
return
*
this
;
}
using
base_class
::
set
;
void
set
(
value_type
a00
,
value_type
a01
,
value_type
a02
,
value_type
a03
,
...
...
@@ -209,6 +230,13 @@ class Matrix3x2Template : public TemplateMatrix<T, 3, 2>
}
~
Matrix3x2Template
()
{}
Matrix3x2Template
&
operator
=
(
const
Matrix3x2Template
&
rhs
)
{
if
(
&
rhs
==
this
)
return
*
this
;
set
(
rhs
.
ptr
());
return
*
this
;
}
using
base_class
::
set
;
void
set
(
value_type
a00
,
value_type
a01
,
...
...
@@ -241,6 +269,13 @@ class Matrix3Template : public TemplateMatrix<T, 3, 3>
}
~
Matrix3Template
()
{}
Matrix3Template
&
operator
=
(
const
Matrix3Template
&
rhs
)
{
if
(
&
rhs
==
this
)
return
*
this
;
set
(
rhs
.
ptr
());
return
*
this
;
}
using
base_class
::
set
;
void
set
(
value_type
a00
,
value_type
a01
,
value_type
a02
,
...
...
@@ -280,6 +315,13 @@ class Matrix3x4Template : public TemplateMatrix<T, 3, 4>
}
~
Matrix3x4Template
()
{}
Matrix3x4Template
&
operator
=
(
const
Matrix3x4Template
&
rhs
)
{
if
(
&
rhs
==
this
)
return
*
this
;
set
(
rhs
.
ptr
());
return
*
this
;
}
using
base_class
::
set
;
void
set
(
value_type
a00
,
value_type
a01
,
value_type
a02
,
value_type
a03
,
...
...
@@ -314,6 +356,13 @@ class Matrix4x2Template : public TemplateMatrix<T, 4, 2>
}
~
Matrix4x2Template
()
{}
Matrix4x2Template
&
operator
=
(
const
Matrix4x2Template
&
rhs
)
{
if
(
&
rhs
==
this
)
return
*
this
;
set
(
rhs
.
ptr
());
return
*
this
;
}
using
base_class
::
set
;
void
set
(
value_type
a00
,
value_type
a01
,
...
...
@@ -350,6 +399,13 @@ class Matrix4x3Template : public TemplateMatrix<T, 4, 3>
}
~
Matrix4x3Template
()
{}
Matrix4x3Template
&
operator
=
(
const
Matrix4x3Template
&
rhs
)
{
if
(
&
rhs
==
this
)
return
*
this
;
set
(
rhs
.
ptr
());
return
*
this
;
}
using
base_class
::
set
;
void
set
(
value_type
a00
,
value_type
a01
,
value_type
a02
,
...
...
include/osg/Quat
View file @
e0d5e4b0
...
...
@@ -53,6 +53,14 @@ class OSG_EXPORT Quat
_v
[
3
]
=
w
;
}
inline
Quat
(
const
Quat
&
rhs
)
{
_v
[
0
]
=
rhs
.
_v
[
0
];
_v
[
1
]
=
rhs
.
_v
[
1
];
_v
[
2
]
=
rhs
.
_v
[
2
];
_v
[
3
]
=
rhs
.
_v
[
3
];
}
inline
Quat
(
const
Vec4f
&
v
)
{
_v
[
0
]
=
v
.
x
();
...
...
src/osg/glu/libtess/tess.cpp
View file @
e0d5e4b0
...
...
@@ -213,7 +213,7 @@ osg::gluTessProperty( GLUtesselator *tess, GLenum which, GLdouble value )
tess
->
windingRule
=
windingRule
;
return
;
default:
b
re
ak
;
re
turn
;
}
case
GLU_TESS_BOUNDARY_ONLY
:
...
...
src/osgPlugins/dds/ReaderWriterDDS.cpp
View file @
e0d5e4b0
...
...
@@ -1078,15 +1078,12 @@ bool WriteDDSFile(const osg::Image *img, std::ostream& fout, bool autoFlipDDSWri
// Initialize ddsd structure and its members
DDSURFACEDESC2
ddsd
;
memset
(
&
ddsd
,
0
,
sizeof
(
ddsd
)
);
DDPIXELFORMAT
ddpf
;
memset
(
&
ddpf
,
0
,
sizeof
(
ddpf
)
);
//DDCOLORKEY ddckCKDestOverlay;
//DDCOLORKEY ddckCKDestBlt;
//DDCOLORKEY ddckCKSrcOverlay;
//DDCOLORKEY ddckCKSrcBlt;
DDSCAPS2
ddsCaps
;
memset
(
&
ddsCaps
,
0
,
sizeof
(
ddsCaps
)
);
ddsd
.
dwSize
=
sizeof
(
ddsd
);
ddpf
.
dwSize
=
sizeof
(
ddpf
);
...
...
src/osgPlugins/gles/IndexMeshVisitor.cpp
View file @
e0d5e4b0
...
...
@@ -55,7 +55,6 @@ void IndexMeshVisitor::process(osg::Geometry& geom) {
new_primitives
.
reserve
(
primitives
.
size
());
// compute duplicate vertices
typedef
std
::
vector
<
unsigned
int
>
IndexList
;
unsigned
int
numVertices
=
geom
.
getVertexArray
()
->
getNumElements
();
IndexList
indices
(
numVertices
);
unsigned
int
i
,
j
;
...
...
src/osgPlugins/gles/glesUtil
View file @
e0d5e4b0
...
...
@@ -222,9 +222,6 @@ namespace glesUtil {
virtual
void
apply
(
osg
::
Vec2ubArray
&
array
)
{
remap
(
array
);
}
virtual
void
apply
(
osg
::
MatrixfArray
&
array
)
{
remap
(
array
);
}
protected:
RemapArray
&
operator
=
(
const
RemapArray
&
)
{
return
*
this
;
}
};
...
...
@@ -252,9 +249,6 @@ namespace glesUtil {
}
return
0
;
}
protected:
VertexAttribComparitor
&
operator
=
(
const
VertexAttribComparitor
&
)
{
return
*
this
;
}
};
// Move the values in an array to new positions, based on the
...
...
src/osgPlugins/ive/DataInputStream.cpp
View file @
e0d5e4b0
...
...
@@ -287,7 +287,7 @@ bool DataInputStream::uncompress(std::istream& fin, std::string& destination) co
return
ret
==
Z_STREAM_END
?
true
:
false
;
}
#else
bool
DataInputStream
::
uncompress
(
std
::
istream
&
fin
,
std
::
string
&
destination
)
const
bool
DataInputStream
::
uncompress
(
std
::
istream
&
/*
fin
*/
,
std
::
string
&
/*
destination
*/
)
const
{
return
false
;
}
...
...
src/osgPlugins/ive/DataOutputStream.cpp
View file @
e0d5e4b0
...
...
@@ -320,7 +320,7 @@ bool DataOutputStream::compress(std::ostream& fout, const std::string& source) c
return
true
;
}
#else
bool
DataOutputStream
::
compress
(
std
::
ostream
&
fout
,
const
std
::
string
&
source
)
const
bool
DataOutputStream
::
compress
(
std
::
ostream
&
/*
fout
*/
,
const
std
::
string
&
/*
source
*/
)
const
{
return
false
;
}
...
...
src/osgPlugins/osc/OscReceivingDevice.cpp
View file @
e0d5e4b0
...
...
@@ -309,7 +309,7 @@ public:
return
true
;
}
catch
(
osc
::
Exception
e
)
{
catch
(
osc
::
Exception
&
e
)
{
handleException
(
e
);
}
...
...
@@ -342,7 +342,7 @@ public:
return
true
;
}
catch
(
osc
::
Exception
e
)
{
catch
(
osc
::
Exception
&
e
)
{
handleException
(
e
);
}
...
...
@@ -378,7 +378,7 @@ public:
return
true
;
}
catch
(
osc
::
Exception
e
)
{
catch
(
osc
::
Exception
&
e
)
{
handleException
(
e
);
}
...
...
@@ -413,7 +413,7 @@ public:
return
true
;
}
catch
(
osc
::
Exception
e
)
{
catch
(
osc
::
Exception
&
e
)
{
handleException
(
e
);
}
...
...
@@ -449,7 +449,7 @@ public:
return
true
;
}
catch
(
osc
::
Exception
e
)
{
catch
(
osc
::
Exception
&
e
)
{
handleException
(
e
);
}
return
false
;
...
...
@@ -491,7 +491,7 @@ public:
return
true
;
}
catch
(
osc
::
Exception
e
)
{
catch
(
osc
::
Exception
&
e
)
{
handleException
(
e
);
}
return
false
;
...
...
@@ -529,7 +529,7 @@ public:
return
true
;
}
catch
(
osc
::
Exception
e
)
{
catch
(
osc
::
Exception
&
e
)
{
handleException
(
e
);
}
return
false
;
...
...
@@ -588,7 +588,7 @@ public:
return
true
;
}
catch
(
osc
::
Exception
e
)
{
catch
(
osc
::
Exception
&
e
)
{
handleException
(
e
);
}
return
false
;
...
...
@@ -630,7 +630,7 @@ public:
return
true
;
}
catch
(
osc
::
Exception
e
)
{
catch
(
osc
::
Exception
&
e
)
{
handleException
(
e
);
}
return
false
;
...
...
@@ -662,7 +662,7 @@ public:
return
true
;
}
catch
(
osc
::
Exception
e
)
{
catch
(
osc
::
Exception
&
e
)
{
handleException
(
e
);
}
return
false
;
...
...
@@ -695,7 +695,7 @@ public:
return
true
;
}
catch
(
osc
::
Exception
e
)
{
catch
(
osc
::
Exception
&
e
)
{
handleException
(
e
);
}
return
false
;
...
...
src/osgUtil/MeshOptimizers.cpp
View file @
e0d5e4b0
...
...
@@ -109,6 +109,11 @@ struct VertexAttribComparitor : public GeometryArrayGatherer
{
}
VertexAttribComparitor
(
const
VertexAttribComparitor
&
rhs
)
:
GeometryArrayGatherer
(
rhs
)
{
}
bool
operator
()
(
unsigned
int
lhs
,
unsigned
int
rhs
)
const
{
for
(
ArrayList
::
const_iterator
itr
=
_arrayList
.
begin
();
...
...
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