Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

About distance2mesh #59

Closed
LogWell opened this issue Oct 4, 2019 · 1 comment
Closed

About distance2mesh #59

LogWell opened this issue Oct 4, 2019 · 1 comment

Comments

@LogWell
Copy link

LogWell commented Oct 4, 2019

Is this a problem of meshes?

data

from vtkplotter import *
s1 = load('BWom0317-HD2-O02P01-S-1.obj')
s2 = load('rp_alexandra_rigged_004_yup_t-1.obj', alpha=0.4)
#s1 = load('1_n.obj')
#s2 = load('2_n.obj', alpha=0.4)
s1.distanceToMesh(s2, signed=True, negate=False)
s1.addScalarBar(title='Signed\nDistance', c='black')

show([s1, [s1, s2]], N=2, bg='white')
@marcomusy marcomusy added the bug label Oct 4, 2019
@marcomusy
Copy link
Owner

it seems that it picks the celldata for coloring instead of pointdata.. try:

from vtkplotter import *
s1 = load('BWom0317-HD2-O02P01-S-1.obj')
s2 = load('rp_alexandra_rigged_004_yup_t-1.obj', c='grey', alpha=0.4)
#s1 = load('1_n.obj')
#s2 = load('2_n.obj', alpha=0.4).scale(1.1)
s1.distanceToMesh(s2, signed=False, negate=False)
s1.addScalarBar(title='Signed\nDistance', c='black')
s1.mapper.SetScalarModeToUsePointData() #############
show(s1, s2, bg='white')

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants