✊🏿 Black Lives Matter. Please consider donating to Black Girls Code today.
⚡️ Concerned about the grid? Kyle Baranko teaches how to predicting peak loads using XGBoost. Register for the August webinar!

"Slice" Rendering Polydata dash_vtk


I am using dash_vtk to display some data (more info here : Export and hover with dash_vtk).

I am able to display a geological surface (as in this demo) and i would like to sort of “cut” this surface (i.e. : I want to display only the part where the x are greater than 10 for example).

I tried to use the slice rendering demo but I’m stuck at the conversion of my Polydata into an ImageData (which seems to be what’s needed for the slice representation).

Here is an example of a surface I display :

Thanks for your time !

1 Like

What you are looking for is Clipping your data by a plane to keep 1 side of your data.

The slice rendering is meant for Volume not Mesh.

Hello Sebastien,

Thank you for your reply and sorry for the time I took to answer, do dash_vtk have any examples of that ? I saw an example here : VTK - vtkClipPolyData Example | weiy.
But I am wondering how to apply this to Dash.

Thanks agin !

The way it apply to dash-vtk is that you can easily take any mesh out of any vtk pipeline and ask dash-vtk to render it. Your example you picked is using a widget which is not really supported with dash-vtk right now. But other than that, the processing pipeline can live on the server and then serve the resulting mesh to dash-vtk.