Hey I'm trying to export a flattened stage file with materials that have texture files linked to them.
In the source HIP file those textures appear as relative paths.
I export a USD file with Use Relative Paths.
I import this USD file into a new HIP file.
Some assets have relative paths @../../../myfile.png@
Some have absolute paths baked in @V:/_library/tree.png@. The assets that used to be relative now are absolute.
I can't figure out why. They're all on the same drive (deeply nested far from each other).
Relative paths not working for some assets
462 2 1-
- alexmajewski
- Member
- 130 posts
- Joined: 8月 2017
- オフライン
-
- mtucker
- スタッフ
- 4589 posts
- Joined: 7月 2005
- オフライン
When doing the conversion to relative paths, if you have to ".." your way all the way to the root of the drive before diving back down again, we throw away all the ".."s and just put in an absolute path. The "relativeness" of these paths is basically useless at this point and just makes it hard to see how to get from one file to another. That was the thinking anyway. Perhaps that's what is going on here?
If this is the problem, and you don't like this behavior, the "relativepaths" output processor is very easy to change so that it generates relative paths even in this case. Just change the `allow_relative_path_from_root` parameter from False to True in the call to `relpath`.
If this is the problem, and you don't like this behavior, the "relativepaths" output processor is very easy to change so that it generates relative paths even in this case. Just change the `allow_relative_path_from_root` parameter from False to True in the call to `relpath`.
-
- alexmajewski
- Member
- 130 posts
- Joined: 8月 2017
- オフライン
I see. This default behavior has been incompatible with one cloud render farm that I've been using. It breaks their automated upload of assets to the cloud.
Can you tell me where exactly can I change that? Should I edit houdini source code in
?
Can you tell me where exactly can I change that? Should I edit houdini source code in
$HFS/houdini/husdplugins/outputprocessors/simplerelativepaths.pyand change the return value of:def processReferencePath( ... return hou.text.relpath(asset_path, referencing_layer_path, allow_relative_path_from_root = False)
-
- Quick Links

