Commit 15cebf0c authored by Jan Möbius's avatar Jan Möbius

More cppcheck warnings

parent cfcc6b50
......@@ -59,7 +59,7 @@ echo "CPPCHECK Summary"
echo "=============================================================================="
echo -e "${NC}"
MAX_ERROR=171
MAX_ERROR=143
if [ $COUNT -gt $MAX_ERROR ]; then
echo -e ${WARNING}
......
......@@ -81,7 +81,7 @@ UpdateType::UpdateType(const UpdateType& _type)
}
UpdateType::UpdateType(UpdateTypeSet _set)
UpdateType::UpdateType(const UpdateTypeSet& _set)
: type_(_set)
{
......@@ -140,7 +140,7 @@ class UpdateTypeInfo {
public:
UpdateTypeInfo(UpdateType _type, QString _name, bool _needsScenegraphReset ) :
UpdateTypeInfo(const UpdateType& _type, QString _name, bool _needsScenegraphReset ) :
type(_type),
name(_name),
resetNeeded(_needsScenegraphReset)
......
......@@ -73,7 +73,7 @@ class DLLEXPORT UpdateType {
UpdateType(const UpdateType& _type);
UpdateType(UpdateTypeSet _set);
UpdateType(const UpdateTypeSet& _set);
/// Exact compare operator
bool operator==(const UpdateType& _type) const;
......
......@@ -120,33 +120,35 @@ public:
unsigned int slices, stacks;
// Constructor
explicit Primitive(GlutPrimitiveType _t)
{
// Set the type
type = _t;
explicit Primitive(GlutPrimitiveType _t) :
// default axis is negative z
axis = Vec3d(0,0,1);
// set default resolution
size = 1.0;
innersize = 1.0;
slices = 20;
stacks = 20;
// default axis is negative z
axis(Vec3d(0,0,1)),
// Set the type
type(_t),
// set default resolution
size(1.0),
innersize(1.0),
slices(20),
stacks(20)
{
}
Primitive(GlutPrimitiveType _t, Vec3d _p, Vec3d _a, ACG::Vec4f _c)
Primitive(GlutPrimitiveType _t, Vec3d _p, Vec3d _a, ACG::Vec4f _c) :
position(_p),
axis(_a),
type(_t),
color(_c),
// set default resolution
size(1.0),
innersize(1.0),
slices(20),
stacks(20)
{
type = _t;
position = _p;
axis = _a;
color = _c;
// set default resolution
size = 1.0;
innersize = 1.0;
slices = 20;
stacks = 20;
}
// Copy Constructor
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment