# Latest

**URL:** https://discourse.vtk.org/latest.md?page=108

[Latest](https://discourse.vtk.org/latest.md) · [Categories](https://discourse.vtk.org/categories.md) · [Tags](https://discourse.vtk.org/tags.md)

**Page:** 109

---

## [vtkGradientFilter on vtkUnstructuredGrid created by custom reader:](https://discourse.vtk.org/t/vtkgradientfilter-on-vtkunstructuredgrid-created-by-custom-reader/10028)

<div class="topic-metadata">

**Author:** [@ramen\_newdals](https://discourse.vtk.org/u/ramen_newdals)\
**Replies:** 2\
**Last updated:** [December 2, 2022, 7:19pm UTC](https://discourse.vtk.org/t/vtkgradientfilter-on-vtkunstructuredgrid-created-by-custom-reader/10028 "2022-12-02T19:19:54Z")

</div>

Hello All, I have a reader that constructs a vtkUnstructuredGrid object that consists of VTK\_TETRA cells. I assign an array at each of the nodes in the vtkUnstructuredGrid object. I would like to use vtkGradientFilter t…

---

## [vtkCompositeDataSet::ShallowCopy and vtkCompositeDataSet::RecursiveShallowCopy](https://discourse.vtk.org/t/vtkcompositedataset-shallowcopy-and-vtkcompositedataset-recursiveshallowcopy/9338)

<div class="topic-metadata">

**Author:** [@mwestphal](https://discourse.vtk.org/u/mwestphal)\
**Replies:** 13\
**Last updated:** [December 2, 2022, 4:05pm UTC](https://discourse.vtk.org/t/vtkcompositedataset-shallowcopy-and-vtkcompositedataset-recursiveshallowcopy/9338 "2022-12-02T16:05:55Z")

</div>

In vtkCompositeDataSet, there is two shallow copy methods, ShallowCopy and RecursiveShallowCopy. ShallowCopy only shallow copy the structure of the composite but do not shallow copy the dataset in the leafs, it actually…

---

## [vtkImageDifference does not detect image differences](https://discourse.vtk.org/t/vtkimagedifference-does-not-detect-image-differences/9726)

<div class="topic-metadata">

**Author:** [@andreasbuykx](https://discourse.vtk.org/u/andreasbuykx)\
**Replies:** 10\
**Last updated:** [December 2, 2022, 3:59pm UTC](https://discourse.vtk.org/t/vtkimagedifference-does-not-detect-image-differences/9726 "2022-12-02T15:59:41Z")

</div>

vtkImageDifference seems to detect zero or much less differences than VTK 9.1. I ran into this issue while working on migrating from VTK9.1 to VTK 9.2: all image tests seemed to succeed except for one that expected diffe…

---

## [Wrong label positions with vtkLabelPlacementMapper](https://discourse.vtk.org/t/wrong-label-positions-with-vtklabelplacementmapper/10043)

<div class="topic-metadata">

**Author:** [@Peter](https://discourse.vtk.org/u/Peter)\
**Replies:** 1\
**Last updated:** [December 2, 2022, 2:39pm UTC](https://discourse.vtk.org/t/wrong-label-positions-with-vtklabelplacementmapper/10043 "2022-12-02T14:39:14Z")

</div>

Hello! I am using VTK 9.1.0 and Qt 5.15.3 and encountered the following problem with vtkLabelPlacementMapper: Without setting a render strategy the labels are corrected: vtkLabelPlacementMapper added to vtkRenderer wi…

---

## [Traces - Multiple Screenshots for Animation](https://discourse.vtk.org/t/traces-multiple-screenshots-for-animation/9986)

<div class="topic-metadata">

**Author:** [@anon64829896](https://discourse.vtk.org/u/anon64829896)\
**Replies:** 10\
**Last updated:** [December 2, 2022, 2:18pm UTC](https://discourse.vtk.org/t/traces-multiple-screenshots-for-animation/9986 "2022-12-02T14:18:41Z")

</div>

Hey! I am currently trying to build an animation out of multiple screenshots from VTK. However, when doing X screenshots in an iteration with moving actors on a transparent background, I receive some kind of “traces” o…

---

## [vtkSelectVisiblePoints doesn't work in QtQuick](https://discourse.vtk.org/t/vtkselectvisiblepoints-doesnt-work-in-qtquick/10006)

<div class="topic-metadata">

**Author:** [@claude](https://discourse.vtk.org/u/claude)\
**Replies:** 5\
**Last updated:** [December 2, 2022, 8:20am UTC](https://discourse.vtk.org/t/vtkselectvisiblepoints-doesnt-work-in-qtquick/10006 "2022-12-02T08:20:28Z")

</div>

Hi everyone, I get a problem that vtkSelectVisiblePoints doesn’t work in QQuickVTKRenderItem+QQuickVTKRenderWindow. I refer to following link: https://kitware.github.io/vtk-examples/site/Cxx/PolyData/SelectVisiblePoints…

---

## [I found a bug in the function vtkArcSource::RequestData.](https://discourse.vtk.org/t/i-found-a-bug-in-the-function-vtkarcsource-requestdata/10026)

<div class="topic-metadata">

**Author:** [@MincheolKim](https://discourse.vtk.org/u/MincheolKim)\
**Replies:** 1\
**Last updated:** [December 2, 2022, 7:47am UTC](https://discourse.vtk.org/t/i-found-a-bug-in-the-function-vtkarcsource-requestdata/10026 "2022-12-02T07:47:37Z")

</div>

Hi all, I used vtkArcSource. I found a bug which is radius change to be 1. You can see below in the function vtkArcSource::RequestData in the vtkArcSource.cpp file. // Calculate radius radius = vtkMath::Normalize(v1…

---

## [Bug in documentation figure on wedge node ordering](https://discourse.vtk.org/t/bug-in-documentation-figure-on-wedge-node-ordering/9946)

<div class="topic-metadata">

**Author:** [@philippeVerney](https://discourse.vtk.org/u/philippeVerney)\
**Replies:** 4\
**Last updated:** [December 2, 2022, 4:30am UTC](https://discourse.vtk.org/t/bug-in-documentation-figure-on-wedge-node-ordering/9946 "2022-12-02T04:30:30Z")

</div>

Hi all, Following this Paraview question, I think there is a bug on the wedge node ordering on this figure in the VTK documentation. Indeed, on this figure, the first face 012 points inwards using right hand rule. How…

---

## [How can I display special .nii file (with timeline) in sequence](https://discourse.vtk.org/t/how-can-i-display-special-nii-file-with-timeline-in-sequence/10038)

<div class="topic-metadata">

**Author:** [@Sterben\_01](https://discourse.vtk.org/u/Sterben_01)\
**Replies:** 0\
**Last updated:** [December 2, 2022, 3:19am UTC](https://discourse.vtk.org/t/how-can-i-display-special-nii-file-with-timeline-in-sequence/10038 "2022-12-02T03:19:57Z")

</div>

Hi. I’m a beginner for VTK. Right now I have an special .nii file which is 2D but has timeline. I had tried use vtkNIFTIImageReader + vtkImageActor + vtkRender + vtkRenderWindow to display this file as an image sequence…

---

## [VTK reads the whole file instead of the selected array.](https://discourse.vtk.org/t/vtk-reads-the-whole-file-instead-of-the-selected-array/6203)

<div class="topic-metadata">

**Author:** [@acdemiralp](https://discourse.vtk.org/u/acdemiralp)\
**Replies:** 0\
**Last updated:** [July 18, 2021, 7:52am UTC](https://discourse.vtk.org/t/vtk-reads-the-whole-file-instead-of-the-selected-array/6203 "2021-07-18T07:52:59Z")

</div>

The following code requests the “Q” scalar field to be read only, but VTK nevertheless attempts to read the whole thing, saturating 256GB of memory, and crashing. Is there something I am doing wrong? #include \<cstdint\> …

---

## [How to import a transfer function exported from ParaView into VTK?](https://discourse.vtk.org/t/how-to-import-a-transfer-function-exported-from-paraview-into-vtk/5217)

<div class="topic-metadata">

**Author:** [@acdemiralp](https://discourse.vtk.org/u/acdemiralp)\
**Replies:** 0\
**Last updated:** [February 19, 2021, 8:24am UTC](https://discourse.vtk.org/t/how-to-import-a-transfer-function-exported-from-paraview-into-vtk/5217 "2021-02-19T08:24:51Z")

</div>

Dear all, here is how I import a ParaView exported transfer function into VTK: class transfer\_function { public: explicit transfer\_function (const std::string& filepath) { std::ifstream file\_stream(filepath)…

---

## [How to make the VTK 9.2 installation routine aware of Qt 5 installed on AlmaLinux 9?](https://discourse.vtk.org/t/how-to-make-the-vtk-9-2-installation-routine-aware-of-qt-5-installed-on-almalinux-9/10036)

<div class="topic-metadata">

**Author:** [@KLB](https://discourse.vtk.org/u/KLB)\
**Replies:** 0\
**Last updated:** [December 1, 2022, 3:27pm UTC](https://discourse.vtk.org/t/how-to-make-the-vtk-9-2-installation-routine-aware-of-qt-5-installed-on-almalinux-9/10036 "2022-12-01T15:27:31Z")

</div>

VTK with Qt is a dependency for a FEA meshing software I want to install. Qt5 is already installed, python 3 also, the latter would be a nice-to-have. How/Where should I make a setting to compile VTK with Qt? I followe…

---

## [Implementing some meshlab function using VTK \[Repair non Manifold Edges by splitting vertices\]](https://discourse.vtk.org/t/implementing-some-meshlab-function-using-vtk-repair-non-manifold-edges-by-splitting-vertices/10034)

<div class="topic-metadata">

**Author:** [@hye00525](https://discourse.vtk.org/u/hye00525)\
**Replies:** 0\
**Last updated:** [December 1, 2022, 2:20pm UTC](https://discourse.vtk.org/t/implementing-some-meshlab-function-using-vtk-repair-non-manifold-edges-by-splitting-vertices/10034 "2022-12-01T14:20:55Z")

</div>

Hello. I want to implement function “Repair non Manifold Edges by splitting vertices” of meshlab with VTK. Are there any related example codes or vtkFilters? Thank you.

---

## [Clarification about quad node ordering](https://discourse.vtk.org/t/clarification-about-quad-node-ordering/10023)

<div class="topic-metadata">

**Author:** [@philippeVerney](https://discourse.vtk.org/u/philippeVerney)\
**Replies:** 4\
**Last updated:** [December 1, 2022, 12:19pm UTC](https://discourse.vtk.org/t/clarification-about-quad-node-ordering/10023 "2022-12-01T12:19:58Z")

</div>

Hi all, Looking at the vtkQuad documentation, I can read: vtkQuad is defined by the four points (0,1,2,3) in counterclockwise order I am wondering what “in counterclockwise order” formally/rigorously means. Indeed,…

---

## [Clipping a pointset with labels with vtkBoxWidget](https://discourse.vtk.org/t/clipping-a-pointset-with-labels-with-vtkboxwidget/10031)

<div class="topic-metadata">

**Author:** [@CharInt0](https://discourse.vtk.org/u/CharInt0)\
**Replies:** 0\
**Last updated:** [December 1, 2022, 11:30am UTC](https://discourse.vtk.org/t/clipping-a-pointset-with-labels-with-vtkboxwidget/10031 "2022-12-01T11:30:34Z")

</div>

Hello, I am using a vtkBoxWidget to clip actors in the 3D scene. I simply get the planes from the vtkBoxWidget and pass them to the mapper: actor-\>GetMapper()-\>SetClippingPlanes(planes); this works smooth. However w…

---

## [vtkImclicitModeler in conjunction with vtkPiecewiseFunction --\> vtkOpenGLVolumeOpacityTable Error on Apple M1 Chip](https://discourse.vtk.org/t/vtkimclicitmodeler-in-conjunction-with-vtkpiecewisefunction-vtkopenglvolumeopacitytable-error-on-apple-m1-chip/9892)

<div class="topic-metadata">

**Author:** [@aschrempf](https://discourse.vtk.org/u/aschrempf)\
**Replies:** 3\
**Last updated:** [December 1, 2022, 10:07am UTC](https://discourse.vtk.org/t/vtkimclicitmodeler-in-conjunction-with-vtkpiecewisefunction-vtkopenglvolumeopacitytable-error-on-apple-m1-chip/9892 "2022-12-01T10:07:59Z")

</div>

First of all thanks to VTK team for the great library! BACKGROUND Our research group is developing surgical simulators, where with one of these we use a simple vtk-pipeline to generate “x-ray-like” images from STL-file…

---

## [Efficient mesh data writer](https://discourse.vtk.org/t/efficient-mesh-data-writer/10012)

<div class="topic-metadata">

**Author:** [@Zqinghaohh](https://discourse.vtk.org/u/Zqinghaohh)\
**Replies:** 1\
**Last updated:** [November 30, 2022, 10:45pm UTC](https://discourse.vtk.org/t/efficient-mesh-data-writer/10012 "2022-11-30T22:45:01Z")

</div>

Hi, I would like to write heavy mesh data (GBs) with VTK and view it in ParaView. Could I have some recommendations on what data structure I should use in VTK to manipulate the data? I have tried unstructured grid, but …

---

## [Unnecessary VTK API change](https://discourse.vtk.org/t/unnecessary-vtk-api-change/9929)

<div class="topic-metadata">

**Author:** [@lassoan](https://discourse.vtk.org/u/lassoan)\
**Replies:** 22\
**Last updated:** [November 30, 2022, 1:37pm UTC](https://discourse.vtk.org/t/unnecessary-vtk-api-change/9929 "2022-11-30T13:37:05Z")

</div>

There have been some breaking changes in vtkThreshold API that did not bring any value to VTK users. This is annoying, because discovering and fixing issues costs us time and there is zero benefit. It makes things even w…

---

## [Failed to use discretizable ColorTransferFunction to set alpha for specific value](https://discourse.vtk.org/t/failed-to-use-discretizable-colortransferfunction-to-set-alpha-for-specific-value/9998)

<div class="topic-metadata">

**Author:** [@lizemin2016](https://discourse.vtk.org/u/lizemin2016)\
**Replies:** 1\
**Last updated:** [November 30, 2022, 12:23pm UTC](https://discourse.vtk.org/t/failed-to-use-discretizable-colortransferfunction-to-set-alpha-for-specific-value/9998 "2022-11-30T12:23:17Z")

</div>

As the title describe, I want to set the cell with zero field data to total opactity, but It doesn’t work, here is the simple code I have tried, can anybody help me, thanks! void simpleVtk() { vtkNew\<vtkPoints\> points;…

---

## [(VTK.js) How to add multiple polylines in vtkPolyData](https://discourse.vtk.org/t/vtk-js-how-to-add-multiple-polylines-in-vtkpolydata/9956)

<div class="topic-metadata">

**Author:** [@rodrigobasilio2022](https://discourse.vtk.org/u/rodrigobasilio2022)\
**Replies:** 2\
**Last updated:** [November 30, 2022, 12:07pm UTC](https://discourse.vtk.org/t/vtk-js-how-to-add-multiple-polylines-in-vtkpolydata/9956 "2022-11-30T12:07:13Z")

</div>

I have multiple lines that defines an object and I need to present them in VTK. I figured out how to do that in VTK.js and vtkPolyData, by adding all points of all lines and defining the lines. The problem is that the la…

---

## [Slow rendering when adding points to glyph](https://discourse.vtk.org/t/slow-rendering-when-adding-points-to-glyph/10018)

<div class="topic-metadata">

**Author:** [@kevinA](https://discourse.vtk.org/u/kevinA)\
**Replies:** 0\
**Last updated:** [November 30, 2022, 11:13am UTC](https://discourse.vtk.org/t/slow-rendering-when-adding-points-to-glyph/10018 "2022-11-30T11:13:04Z")

</div>

Hello, We are building an application where we need to trace paths by placing spheres along said path. The spheres are added to a single vtkGlyph3D, i.e. using a single actor. Here is a quick GIF of the process, to sho…

---

## [About casting from vtkImageData\* to vtkDataObject\*](https://discourse.vtk.org/t/about-casting-from-vtkimagedata-to-vtkdataobject/10014)

<div class="topic-metadata">

**Author:** [@Sterben\_01](https://discourse.vtk.org/u/Sterben_01)\
**Replies:** 6\
**Last updated:** [November 30, 2022, 8:43am UTC](https://discourse.vtk.org/t/about-casting-from-vtkimagedata-to-vtkdataobject/10014 "2022-11-30T08:43:02Z")

</div>

Hi. I’m trying to write an simple example of vtk. I want to read nii file and directly write it to another file. My code: vtkSmartPointer \< vtkNIFTIImageReader \> NiftReader = vtkSmartPointer \< vtkNIFTIImageReader \> ::…

---

## [I have some colors corresponding to points. How to render point clouds and set colors for each point](https://discourse.vtk.org/t/i-have-some-colors-corresponding-to-points-how-to-render-point-clouds-and-set-colors-for-each-point/9848)

<div class="topic-metadata">

**Author:** [@zhangzhi93](https://discourse.vtk.org/u/zhangzhi93)\
**Replies:** 13\
**Last updated:** [November 30, 2022, 8:42am UTC](https://discourse.vtk.org/t/i-have-some-colors-corresponding-to-points-how-to-render-point-clouds-and-set-colors-for-each-point/9848 "2022-11-30T08:42:09Z")

</div>

I have some colors corresponding to points. How to render point clouds and set colors for each point

---

## [vtkCellLocator::IntersectWithLine is unreliable in 2D](https://discourse.vtk.org/t/vtkcelllocator-intersectwithline-is-unreliable-in-2d/9838)

<div class="topic-metadata">

**Author:** [@andreasbuykx](https://discourse.vtk.org/u/andreasbuykx)\
**Replies:** 4\
**Last updated:** [November 29, 2022, 9:47pm UTC](https://discourse.vtk.org/t/vtkcelllocator-intersectwithline-is-unreliable-in-2d/9838 "2022-11-29T21:47:45Z")

</div>

I want to find the intersection point on a surface of a line, where the line and the surface are both in the Z=0 plane. I would hope/expect that vtkCellLocator::IntersectWithLine always finds a point on the edge of the s…

---

## [Bug in vtkAxisActor2D::SetTitle()?](https://discourse.vtk.org/t/bug-in-vtkaxisactor2d-settitle/9869)

<div class="topic-metadata">

**Author:** [@Tomasso](https://discourse.vtk.org/u/Tomasso)\
**Replies:** 9\
**Last updated:** [November 29, 2022, 5:59pm UTC](https://discourse.vtk.org/t/bug-in-vtkaxisactor2d-settitle/9869 "2022-11-29T17:59:26Z")

</div>

I’m running VTK-9.2 for C++. My code creates a vtkCubeAxesActor2D, and sets data range and title for x, y, and z axes. The ranges are displayed properly, but titles display as ‘X’, ‘Y’, and ‘Z’ (defaults?) instead of ‘L…

---

## [vtkIntersectionPolyDataFilter do not work](https://discourse.vtk.org/t/vtkintersectionpolydatafilter-do-not-work/9861)

<div class="topic-metadata">

**Author:** [@zhang-qiang-github](https://discourse.vtk.org/u/zhang-qiang-github)\
**Replies:** 5\
**Last updated:** [November 29, 2022, 5:54pm UTC](https://discourse.vtk.org/t/vtkintersectionpolydatafilter-do-not-work/9861 "2022-11-29T17:54:58Z")

</div>

The code to reproduce my problem is: vtkSmartPointer\<vtkLineSource\> lineSource = vtkSmartPointer\<vtkLineSource\>::New(); lineSource-\>SetPoint1(0, 0, 0); lineSource-\>SetPoint2(10, 0, 0); vtkSmartPointer\<vtkTubeFilter\>…

---

## [Windows third party libraries are static and not dll](https://discourse.vtk.org/t/windows-third-party-libraries-are-static-and-not-dll/10008)

<div class="topic-metadata">

**Author:** [@Gilthalas](https://discourse.vtk.org/u/Gilthalas)\
**Replies:** 0\
**Last updated:** [November 29, 2022, 5:15pm UTC](https://discourse.vtk.org/t/windows-third-party-libraries-are-static-and-not-dll/10008 "2022-11-29T17:15:55Z")

</div>

With 9.2 (it seems, since in 9.1 this did not happen), the third party libraries VTK uses are built as .lib files (static libraries) instead of .dlls. I have BUILD\_SHARED\_LIBS set to true. I need them to build as DLLs s…

---

## [How to convert Gmsh into Explicit Structured (or VTI) with VTK?](https://discourse.vtk.org/t/how-to-convert-gmsh-into-explicit-structured-or-vti-with-vtk/9992)

<div class="topic-metadata">

**Author:** [@edgar](https://discourse.vtk.org/u/edgar)\
**Replies:** 1\
**Last updated:** [November 29, 2022, 4:02pm UTC](https://discourse.vtk.org/t/how-to-convert-gmsh-into-explicit-structured-or-vti-with-vtk/9992 "2022-11-29T16:02:04Z")

</div>

Hello, I am trying to convert a Gmsh (unstructured) mesh into a structured grid (VTI). Below is a part of a question that I asked on the PyVista slack forum (before I was granted access to VTK’s discourse forum). The c…

---

## [How to add a Colormap to a vtkPolyData](https://discourse.vtk.org/t/how-to-add-a-colormap-to-a-vtkpolydata/9979)

<div class="topic-metadata">

**Author:** [@Hamid\_Fsian](https://discourse.vtk.org/u/Hamid_Fsian)\
**Replies:** 8\
**Last updated:** [November 29, 2022, 12:37pm UTC](https://discourse.vtk.org/t/how-to-add-a-colormap-to-a-vtkpolydata/9979 "2022-11-29T12:37:47Z")

</div>

Dear Community, I am trying to color a vtkPolyData by looping through the z-axis, and then see if the width of a slice(i) is \< or \> to a certain value. And then color the slice (over the z-axis) according to this thresh…

---

## [VTK Select Poly data doesn't work](https://discourse.vtk.org/t/vtk-select-poly-data-doesnt-work/9968)

<div class="topic-metadata">

**Author:** [@AndreAhmed](https://discourse.vtk.org/u/AndreAhmed)\
**Replies:** 2\
**Last updated:** [November 29, 2022, 3:39am UTC](https://discourse.vtk.org/t/vtk-select-poly-data-doesnt-work/9968 "2022-11-29T03:39:13Z")

</div>

Hello, I have a curve in 3D and I’m trying to select the polydata that intersect with, the problem is I’m getting very bad output, and meshes are thrown and flying in the 3D space vtkNew selectionPoints; for (int i…

[Previous page](https://discourse.vtk.org/latest.md?page=107)

[Next page](https://discourse.vtk.org/latest.md?page=109)
