I have a CSV where each row represent a point and a velocity vector, so 6 columns: x, y, z, and v_x, v_y, v_z. I use a “Table to Points” filter followed by a “Merge Vector Components” which allow me to visualize the vectors properly:
However, when using a “StreamTracer” using the vectors that are properly rendered, I don’t find a way to generate the streamlines on this vector field. I tried using the sphere and the line with different resolutions and changing all the parameters, nothing works. I tried extracting points from the PointSet and using the “StreamTracer with Source”, but also didn’t work. I don’t know if it has to be with the fact that the TableToPoints filter interprets the object as a “Polygonal Mesh”, but I also tried to generate a Structured volume with the filters, but I loose the vectors I already have.
I tried the ResampleToImage with the default resolution of 100x100x100 and a finer one, and the respective vectors in the dataset are not resampled/interpolated.
I also tried before the “Point Volume Interpolator” with the default VoronoiKernel, and it creates a structured volume with some content in the “cells”, but I don’t get why I get vectors with non-zero values in areas that I didn’t have any point with values in empty regions.
Any suggestion to keep the same vectors I have in my PointSet but just mapping them in the structured volume with a basic interpolator?
The Voronoi kernel fills each point in the sample grid with the values from the nearest point in the point cloud. That means you don’t have to worry about the sampling distance for points in the cloud, but it also means that those in the parts at the edges may be filled with data that is far away. (That is, the nearest cloud point might be quite far away.)
If you don’t like that behavior, you could change the kernel type to something like Gaussian. When using the Gaussian kernel, you have to specify a radius that indicates the sphere of influence each cloud point has. This has the advantage that parts of the sampling grid that are not close to any cloud points are zero. But it has the disadvantage that you have to get the radius right. If the radius is too small, there will be holes in the middle of the grid. If the radius is too big, then data from points will blend together, effectively blurring your data.
I believe what you wan’t can’t be done. I tried the following with 5.11.1.
Read in the dataset. It read in as a vtk unstructured mesh, as it should. I saw all of your points as … um … points. Thus, as it isn’t a .csv file, I didn’t need to run table to points.
This appears to read in correctly. Use the Spreadsheet View to see this. As Mathieu states, you have to have a solid mesh for streamlines.
Resample to Image filter.
Spreadsheet view. There is basically no data here. See vector and v_x, v_y, v_z. My guess is that the Resample to Image filter doesn’t put point data into a structured mesh of cells. Thus, this will fail.
So, what will work? Glyph filter is all I can think of. Glyph by Arrow or Line (as you are already doing).