tkeskita / BVtkNodes

Create and execute VTK pipelines in Blender Node Editor
GNU General Public License v3.0
117 stars 20 forks source link

VTK to Blender Mesh Auto Update #72

Closed Silverwing747 closed 1 year ago

Silverwing747 commented 2 years ago

Hello,

I am wondering what happens to the auto-update option in the VTK to Blender Mesh node? This option existed in the tutorial screenshots, but now it's gone. Currently, for every time frame, I have to manually update the VTK node, which is very inconvient.

Currently, I am using VTK 9.1.0 with Blender 2.93.

Figure1: current VTK to Blender Mesh node image

Figure2: VTK to Blender Mesh node in the tutorial image

tkeskita commented 2 years ago

Hi,

the node update system has been rewritten. Update behavior is now controlled via Update Mode property located in the Inspect Panel. There are also other changes you may want to check.

BR, Tuomo

Silverwing747 commented 2 years ago

Hi Tuomo,

Thank you for this quick reply. Also thank you for writing this amazing add-on :)

I checked the inspect panel, however, it seems to be empty. image

I also take a look at the code. I found that if I comment out line 277 for def on_frame_change in the init.py file, the vtk object will automatically update with time. So I am a little curious. Am I not doing things properly, or those lines are supposed to be commented out? Screen Shot 2022-01-18 at 10 34 37

tkeskita commented 2 years ago

Hi,

Inspect Panel showing as empty suggests you are not maybe using latest version of BVTKNodes? Can you try to update according to instructions in docs?

Next, try to load Tree Panel -> Examples -> cubeflow_cut_plane and see if that works for you, with Update Mode changed to Update All Automatically?

Code seems correct, it's supposed to run update on line 300.

Silverwing747 commented 2 years ago

Hi Tuomo,

I am using the latest version (0.8) along with vtk9.1.0 and blender 2.93.7. I tested on both windows and Mac. While other panel is consistent with the document, I don’t see anything under inspect panel. Could tell what’s the version you are using?

tkeskita commented 2 years ago

I'm on Linux with Ubuntu 20.04, BVTKNodes latest commit acfbb7dcea916330eded035d7a40713525f36e47 (=0.8) and Blender 2.93.6, and tested previously also with Blender 3.0.0. I can make a test on Windows in a few days.

Please check that the add-on version number and path to add-on is what you expect in Blender -> Preferences -> Add-ons -> BVTKNodes

If you start Blender from command line, does it show any error messages?

Silverwing747 commented 2 years ago

I checked the add-on version and path in Blender. It indeed shows version 0.8.

Also, there is no error at all when I start blender from the command line.

I will try both Blender 2.93.6 and Blender 3.0.0

Screen Shot 2022-01-19 at 10 42 50
tkeskita commented 2 years ago

Can you try to disable the addon, rename the folder in that path from BVtkNodes-master to BVtkNodes, then enable the addon?

Silverwing747 commented 2 years ago

It works! Thank you so much for the help. Do you know what's the potential reason behind it?

image

tkeskita commented 2 years ago

OK good to know that it works! Looks like Python has trouble finding module BVtkNodes when doing from BVtkNodes import ... if the root folder is not named exactly like so. I consider this is a bug, I'll find a way to fix it or implement a workaround, thanks!