Cannot get Sphere VTK example to work.

Hi All!!

So, I am new to VTK. I want to use VTK to visualize and volume render MRI DICOM images.

I have been trying to make the sphere example work (https://vtk.org/Wiki/VTK/Examples/Cxx/GeometricObjects/Sphere). But with no luck!

I was first trying to make it work on windows. I am using the latest VTK and Cmake versions. I follow the configuration and build steps on the VTK website.

I don’t understand what is happening. I configured and generated the VTK correctly (I think). I checked the VTK_examples.

Could someone help me please :)?

Best regards,
Khalil

Did you build VTK? I see the ccmake but did you build VTK afterward?

Otherwise, your commands look correct. It works for me…

Bill

1 Like

You need to build VTK. I just tried building Sphere against a VTK that has been configured but not built. I get the same bad results you get.

1 Like

Hi Bill!

Thank you for your reply!

I actually start building the VTK, but I am getting an error that I dont understand:

There is a problem with the current VTK build. If you are using cmake-gui you need to configure VTK as shown here:

Once you do this the build will work.

Also please use: Sphere the link you mentioned has been superseded by the new VTK Examples site.

1 Like

The problem with ADIOS2 seems to have been fixed now. So you can set the above value back to DEFAULT.

1 Like

Thank you guys for the help, really!

I got the Sphere example to work now I can move on with my project.

That’s good news. Do keep in mind the VTK Examples for inspiration and ideas.

1 Like