How to Outline Perimeter

Hi,

I have a VTK file with unstructured grid data (they are data points), as shown here:

When I use the Outline feature in ParaView, it generates a rectangular outline around the data points, like this:

However, I’m looking to create an outline that follows the actual shape of the data points, like this hand-drawn example:

I’ve tried using Feature Edges and Delaunay2D, but they don’t give me the result I’m looking for. Does anyone know how to achieve an outline that matches the exact perimeter of the irregular data points?

Thanks in advance!

You probably want FeatureEdges filter. Could you share your data ?

Sure, here it is:
data_grav_misfit_final.vtk (2.3 MB)

It is a file that has the following headers in csv format:
X,Y,Z,Value

Your file seems incorrectly encodded:

# vtk DataFile Version 3.0
Tomofast-x
BINARY
DATASET UNSTRUCTURED_GRID

POINTS    49695 FLOAT 
HG?^@I:?^@<#?
HG?^@I:?^@<#?
HG?^@I:?^@<#?
HG?^@I:?^@<#?
HH^@^@I:?^@<#?
HH^Y^@I:?^@<#?

Apologies, I’m still a beginner with ParaView and VTK visualization. Does this mean that my VTK file should be in ASCII format instead of binary? If possible, could you share a resource or guide on how to properly convert it to the correct format?

Additionally, could you provide a VTK file with points that I can use with the Feature Edges filter? I’d like to share it with the developer of the Tomofast-x software so they can consider implementing it in a future update.

Thank you for your help!

I was able to load your data into ParaView.

The challenge of your data is that it what we sometimes call a “point cloud” or “mesh-less data”. Your data does not define a mesh of cells connecting points and defining the area of space it covers. That means that ParaView does not immediately know the area that is supposed to be covered.

There are some tricks to impose a mesh on a point cloud. I think the one that will work best in your case is to use the Delaunay 2D filter. This filter will connect together the points in your data with triangles.

One problem you will see at first with the Delaunay 2D filter is that it will form a convex hull of the points, which means those cut out areas will get filled in. The Delaunay 2D filter has an optional parameter named Alpha that is used to remove stretched out triangles that tend to cover those spaces we want to see empty. You have to play with that parameter a bit, but I found that setting it to 100 gives a reasonable coverage.

To see the outline, just change the representation to Feature Edges.

There is also a filter named Feature Edges that will extract the geometry of this outline if you need it.

1 Like

Indeed, not sure what happened earlier on my side.

Thank you so much, Kenneth! It worked perfectly for my needs. I’ll inform the Tomofast-x developers about this issue with the data and see if they can address it in a future pull request.

1 Like