Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
OpenWalnut
OpenWalnut Core
Commits
d4e4a61e
Commit
d4e4a61e
authored
Sep 14, 2010
by
ledig
Browse files
[FIX] compiles in MSVC again (removed numCores for targed too)
parent
31ca72a3
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
22 additions
and
16 deletions
+22
-16
src/CMakeLists.txt
src/CMakeLists.txt
+7
-5
src/common/datastructures/WColoredVertices.h
src/common/datastructures/WColoredVertices.h
+3
-1
src/common/math/WMath.h
src/common/math/WMath.h
+7
-5
src/common/math/WPlane.h
src/common/math/WPlane.h
+2
-2
src/graphicsEngine/WGEGeodeUtils.h
src/graphicsEngine/WGEGeodeUtils.h
+1
-1
src/graphicsEngine/WTriangleMesh2.h
src/graphicsEngine/WTriangleMesh2.h
+2
-2
No files found.
src/CMakeLists.txt
View file @
d4e4a61e
...
...
@@ -87,7 +87,7 @@ ELSE()
IF
(
NOT VERSION LESS 2.6.3
)
SET
(
CMAKE_PREFIX_PATH
"$ENV{ProgramFiles}/OpenSceneGraph"
)
ENDIF
()
FIND_PACKAGE
(
OpenSceneGraph
${
MIN_OSG_VERSION
}
REQUIRED osgUtil osgDB osgViewer osgText osgGA osgSim
)
FIND_PACKAGE
(
OpenSceneGraph
${
MIN_OSG_VERSION
}
REQUIRED osgUtil osgDB osgViewer osgText osgGA osgSim
osgWidget
)
INCLUDE_DIRECTORIES
(
${
OPENSCENEGRAPH_INCLUDE_DIRS
}
)
ENDIF
()
...
...
@@ -267,15 +267,17 @@ ADD_CUSTOM_TARGET( tags DEPENDS ctags DEPENDS cscope )
#-------------------------------------------------------------------------------------------------------------
# Determines the number of cores available on this machine
SET
(
NUM_CORES_SOURCE_DIR
${
PROJECT_SOURCE_DIR
}
/../tools/numCores
)
SET
(
NUM_CORES_BINARY_DIR
${
PROJECT_BINARY_DIR
}
/numCores
)
SET
(
NUM_CORES_BINARY
${
NUM_CORES_BINARY_DIR
}
/numCores
)
ADD_CUSTOM_TARGET
(
numCores
IF
(
NOT CMAKE_GENERATOR MATCHES
"Visual Studio"
)
SET
(
NUM_CORES_SOURCE_DIR
${
PROJECT_SOURCE_DIR
}
/../tools/numCores
)
SET
(
NUM_CORES_BINARY_DIR
${
PROJECT_BINARY_DIR
}
/numCores
)
SET
(
NUM_CORES_BINARY
${
NUM_CORES_BINARY_DIR
}
/numCores
)
ADD_CUSTOM_TARGET
(
numCores
COMMAND
${
CMAKE_COMMAND
}
-E make_directory
${
NUM_CORES_BINARY_DIR
}
COMMAND cd
${
NUM_CORES_BINARY_DIR
}
&&
${
CMAKE_COMMAND
}
${
NUM_CORES_SOURCE_DIR
}
> /dev/null
COMMAND $
(
MAKE
)
-C
${
NUM_CORES_BINARY_DIR
}
> /dev/null
COMMENT
"Determines the number of cores available on this machine"
)
ENDIF
()
#-------------------------------------------------------------------------------------------------------------
# Checks style guide lines via the BrainLint tool against all source code files
...
...
src/common/datastructures/WColoredVertices.h
View file @
d4e4a61e
...
...
@@ -31,10 +31,12 @@
#include "../WTransferable.h"
#include "../WColor.h"
#include "../WExportCommon.h"
/**
* Represents a std::map where for each vertex ID a color is stored.
*/
class
WColoredVertices
:
public
WTransferable
class
OWCOMMON_EXPORT
WColoredVertices
:
public
WTransferable
// NOLINT
{
public:
/**
...
...
src/common/math/WMath.h
View file @
d4e4a61e
...
...
@@ -38,6 +38,8 @@
#include "WPlane.h"
#include "WLine.h"
#include "../WExportCommon.h"
/**
* Classes and functions of math module of OpenWalnut.
*/
...
...
@@ -77,7 +79,7 @@ namespace wmath
*
* \return True if both intersects otherwise false.
*/
bool
testIntersectTriangle
(
const
wmath
::
WPosition
&
p1
,
const
wmath
::
WPosition
&
p2
,
const
wmath
::
WPosition
&
p3
,
const
WPlane
&
p
);
bool
OWCOMMON_EXPORT
testIntersectTriangle
(
const
wmath
::
WPosition
&
p1
,
const
wmath
::
WPosition
&
p2
,
const
wmath
::
WPosition
&
p3
,
const
WPlane
&
p
);
/**
* Checks if the given segment intersects with the plane or not. Even if
...
...
@@ -93,7 +95,7 @@ namespace wmath
*
* \return True if an intersection was detected, false otherwise.
*/
bool
intersectPlaneSegment
(
const
WPlane
&
p
,
bool
OWCOMMON_EXPORT
intersectPlaneSegment
(
const
WPlane
&
p
,
const
wmath
::
WPosition
&
p1
,
const
wmath
::
WPosition
&
p2
,
boost
::
shared_ptr
<
wmath
::
WPosition
>
pointOfIntersection
);
...
...
@@ -109,7 +111,7 @@ namespace wmath
*
* \return True if an intersection was detected, false otherwise.
*/
bool
intersectPlaneLineNearCP
(
const
WPlane
&
p
,
const
wmath
::
WLine
&
l
,
boost
::
shared_ptr
<
wmath
::
WPosition
>
cutPoint
);
bool
OWCOMMON_EXPORT
intersectPlaneLineNearCP
(
const
WPlane
&
p
,
const
wmath
::
WLine
&
l
,
boost
::
shared_ptr
<
wmath
::
WPosition
>
cutPoint
);
/**
* Computes the signum for the given value.
...
...
@@ -125,7 +127,7 @@ namespace wmath
* Calculates the odd factorial. This means 1*3*5* ... * border if border is odd, or 1*3*5* ... * (border-1) if border is even.
* \param border the threshold for the factorial calculation.
*/
inline
unsigned
int
oddFactorial
(
unsigned
int
border
)
inline
unsigned
int
OWCOMMON_EXPORT
oddFactorial
(
unsigned
int
border
)
{
unsigned
int
result
=
1
;
for
(
unsigned
int
i
=
3
;
i
<=
border
;
i
+=
2
)
...
...
@@ -137,7 +139,7 @@ namespace wmath
* Calculates the even factorial. This means 2*4*6 ... * \param border if border is even, or 2*4*6* ... * ( \param border - 1 ) if border is odd.
* \param border the threshold for the factorial calculation.
*/
inline
unsigned
int
evenFactorial
(
unsigned
int
border
)
inline
unsigned
int
OWCOMMON_EXPORT
evenFactorial
(
unsigned
int
border
)
{
unsigned
int
result
=
1
;
for
(
unsigned
int
i
=
2
;
i
<=
border
;
i
+=
2
)
...
...
src/common/math/WPlane.h
View file @
d4e4a61e
...
...
@@ -30,14 +30,14 @@
#include <boost/shared_ptr.hpp>
#include "../../dataHandler/WGridRegular3D.h"
#include "../../dataHandler/WExportDataHandler.h"
#include "WPosition.h"
#include "WVector3D.h"
#include "../WExportCommon.h"
/**
* Represents a plane with a normal vector and a position in space.
*/
class
OW
DATAHANDLER
_EXPORT
WPlane
// NOLINT
class
OW
COMMON
_EXPORT
WPlane
// NOLINT
{
public:
/**
...
...
src/graphicsEngine/WGEGeodeUtils.h
View file @
d4e4a61e
...
...
@@ -155,7 +155,7 @@ namespace wge
*
* \return Geode with as many cubes as points in the container where each cube is around a certain position.
*/
template
<
class
Container
>
osg
::
ref_ptr
<
osg
::
Geode
>
WGE_EXPORT
genPointBlobs
(
boost
::
shared_ptr
<
Container
>
points
,
template
<
class
Container
>
osg
::
ref_ptr
<
osg
::
Geode
>
genPointBlobs
(
boost
::
shared_ptr
<
Container
>
points
,
double
size
,
const
WColor
&
color
=
WColor
(
1
,
0
,
0
)
);
}
// end of namespace wge
...
...
src/graphicsEngine/WTriangleMesh2.h
View file @
d4e4a61e
...
...
@@ -571,7 +571,7 @@ namespace tm_utils
*
* \return List of components where each of them is a WTriangleMesh again.
*/
boost
::
shared_ptr
<
std
::
list
<
boost
::
shared_ptr
<
WTriangleMesh2
>
>
>
componentDecomposition
(
const
WTriangleMesh2
&
mesh
);
WGE_EXPORT
boost
::
shared_ptr
<
std
::
list
<
boost
::
shared_ptr
<
WTriangleMesh2
>
>
>
componentDecomposition
(
const
WTriangleMesh2
&
mesh
);
/**
* Prints for each mesh \#vertices and \#triangles, as well as each triangle with its positions. No point IDs are printed.
...
...
@@ -581,7 +581,7 @@ namespace tm_utils
*
* \return The output stream again for further usage.
*/
std
::
ostream
&
operator
<<
(
std
::
ostream
&
os
,
const
WTriangleMesh2
&
rhs
);
WGE_EXPORT
std
::
ostream
&
operator
<<
(
std
::
ostream
&
os
,
const
WTriangleMesh2
&
rhs
);
}
inline
bool
WTriangleMesh2
::
operator
==
(
const
WTriangleMesh2
&
rhs
)
const
...
...
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