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
Andrew Bauer
VTK
Commits
f2422678
Commit
f2422678
authored
Mar 08, 1995
by
Will Schroeder
Browse files
ENH: Implicit function changes.
parent
e36145bc
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/SampleF.cc
View file @
f2422678
...
...
@@ -13,8 +13,8 @@ without the express written consent of the authors.
Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen 1993, 1994
=========================================================================*/
#include <math.h>
#include "SampleF.hh"
#include "vlMath.hh"
#include "FScalars.hh"
#include "FNormals.hh"
...
...
@@ -86,6 +86,7 @@ void vlSampleFunction::Execute()
vlFloatNormals
*
newNormals
=
NULL
;
int
numPts
;
float
*
p
,
s
;
vlMath
math
;
vlDebugMacro
(
<<
"Sampling implicit function"
);
//
...
...
@@ -130,7 +131,8 @@ void vlSampleFunction::Execute()
for
(
ptId
=
0
;
ptId
<
numPts
;
ptId
++
)
{
p
=
this
->
GetPoint
(
ptId
);
this
->
ImplicitFunction
->
EvaluateNormal
(
p
[
0
],
p
[
1
],
p
[
2
],
n
);
this
->
ImplicitFunction
->
EvaluateGradient
(
p
[
0
],
p
[
1
],
p
[
2
],
n
);
math
.
Normalize
(
n
);
newNormals
->
SetNormal
(
ptId
,
n
);
}
}
...
...
Write
Preview
Supports
Markdown
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