attribfrommap and file node questions

   4705   7   2
User Avatar
Member
6 posts
Joined: Dec. 2013
Offline
Hi,

I'm doing mesh reduction on multiple objects using Houdini. I was hoping someone could help me get unstuck

Question 1:

I'm using an attribfrommap node that converts my grayscale map to weight values. This works great but I have not found a way to reload the texture. I have an absolute path to my Texture in the Texture path area but if I make a change to the texture on disk, I cant seem to get the updated texture into the attribfrommap node. Its like Houdini has the texture cached and doesn't reload it. (I also get old data if I switch to a new texture and then back to the old one)

Does anyone see what I am doing wrong?

Question 2:

I have a file node that is my geometry, I want to take the geometry file path from my input node, change it (changing the extension for example) and then apply it to another file node that writes the file out.

Ideally I want my network to iterate through all the file nodes in the scene amd go through the same polyreduce node and write out the files with a new name.

-Gisli
User Avatar
Member
4189 posts
Joined: June 2012
Offline
1. Does Update Textures in the Render menu work

2. Do you have a simple file as an example what you want to achieve.
User Avatar
Member
6 posts
Joined: Dec. 2013
Offline
Thanks for the reply, I hope this makes it clear what I am attempting. I've also attached a scene that is setup the way that I am trying to do it.





https://www.dropbox.com/s/i77zk8gado8728j/PolyReduceHelpRequestScene.7z [dropbox.com]


*edit

no, update textures from the render menu did not work
User Avatar
Member
99 posts
Joined: July 2007
Offline
Hi,
1) in textport type:
glcache -c
it should help

more info - here [sidefx.com]

2) take a look into the attached scene

Attachments:
PolyReduceHelpRequestScene.zip (356.8 KB)

User Avatar
Member
6 posts
Joined: Dec. 2013
Offline
Hi,

Thanks for your reply. I looked at the file that you attached and it has given me an idea on how to proceed

The glcache command did not work, I have tried all methods of clearing cache in the software without luck. The only way I have found refreshing the input texture is to restart the software.
User Avatar
Member
99 posts
Joined: July 2007
Offline
Yeah, seems it onlu works for shaders

only other workaround i've found so far is:
You can load image in COP's and reference it with “op:” syntax, file cop can reload images, its not ideal, but better than reloading Houdini

Attachments:
vopsMapRefresh.hip (172.9 KB)

User Avatar
Member
387 posts
Joined: Nov. 2008
Offline
For texture refresh you need flush texture cache and recook VopSop that reads image color data.

Look at example.

It would be nice to have that Force Update button with python script by default at least (until this update bug is fixed).

hou.hscript('texcache -c');hou.node('./calculate_point_attribute').cook(force=True)

Attachments:
forceImageUpdate.zip (49.6 KB)

User Avatar
Member
6 posts
Joined: Dec. 2013
Offline
Thanks a lot,

Clearing the cache and then force cooking the “calculate_point_attribute” works. Now I can make changes to my file on disk and re-load them via script.

Is there a way for me to force cook a node through the UI (right click menu or something like that) It would be nice if I'm making changes inside a network and I want to guarantee that there is no cached data still hanging around.

-Gisli
  • Quick Links