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
d356fd65
Commit
d356fd65
authored
Feb 16, 2011
by
schurade
Browse files
[CHANGE] removed the half voxel offset
parent
384e4ce5
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
6 deletions
+6
-6
src/graphicsEngine/algorithms/WMarchingLegoAlgorithm.cpp
src/graphicsEngine/algorithms/WMarchingLegoAlgorithm.cpp
+3
-3
src/graphicsEngine/algorithms/WMarchingLegoAlgorithm.h
src/graphicsEngine/algorithms/WMarchingLegoAlgorithm.h
+3
-3
No files found.
src/graphicsEngine/algorithms/WMarchingLegoAlgorithm.cpp
View file @
d356fd65
...
...
@@ -399,9 +399,9 @@ boost::shared_ptr<WTriangleMesh> WMarchingLegoAlgorithm::genSurfaceOneValue( siz
resultPos4D
[
3
]
=
m_matrix
(
3
,
0
)
*
pos
[
0
]
+
m_matrix
(
3
,
1
)
*
pos
[
1
]
+
m_matrix
(
3
,
2
)
*
pos
[
2
]
+
m_matrix
(
3
,
3
)
*
1
;
(
*
mapIterator
).
second
.
newID
=
nextID
;
triMesh
->
addVertex
(
resultPos4D
[
0
]
/
resultPos4D
[
3
]
-
0.5
,
resultPos4D
[
1
]
/
resultPos4D
[
3
]
-
0.5
,
resultPos4D
[
2
]
/
resultPos4D
[
3
]
-
0.5
);
triMesh
->
addVertex
(
resultPos4D
[
0
]
/
resultPos4D
[
3
],
resultPos4D
[
1
]
/
resultPos4D
[
3
],
resultPos4D
[
2
]
/
resultPos4D
[
3
]
);
triMesh
->
addTextureCoordinate
(
texCoord
);
nextID
++
;
mapIterator
++
;
...
...
src/graphicsEngine/algorithms/WMarchingLegoAlgorithm.h
View file @
d356fd65
...
...
@@ -253,9 +253,9 @@ template<typename T> boost::shared_ptr<WTriangleMesh> WMarchingLegoAlgorithm::ge
resultPos4D
[
3
]
=
m_matrix
(
3
,
0
)
*
pos
[
0
]
+
m_matrix
(
3
,
1
)
*
pos
[
1
]
+
m_matrix
(
3
,
2
)
*
pos
[
2
]
+
m_matrix
(
3
,
3
)
*
1
;
(
*
mapIterator
).
second
.
newID
=
nextID
;
triMesh
->
addVertex
(
resultPos4D
[
0
]
/
resultPos4D
[
3
]
-
0.5
,
resultPos4D
[
1
]
/
resultPos4D
[
3
]
-
0.5
,
resultPos4D
[
2
]
/
resultPos4D
[
3
]
-
0.5
);
triMesh
->
addVertex
(
resultPos4D
[
0
]
/
resultPos4D
[
3
],
resultPos4D
[
1
]
/
resultPos4D
[
3
],
resultPos4D
[
2
]
/
resultPos4D
[
3
]
);
triMesh
->
addTextureCoordinate
(
texCoord
);
nextID
++
;
mapIterator
++
;
...
...
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