Trying to include a "filename" attribute in a file output string, syntax problem?

   2318   3   1
User Avatar
Member
14 posts
Joined: Oct. 2017
Offline
Hello, everyone.

I have an HDA that takes an FBX, does some poly reduce and uv stuff, and exports a new FBX.

I am using the “gamedev extract filename” sop to get a filename as a detail attribute, but when I try to use it in the output FBX rop, it is not working.

This is what I am using in the Output File field:
$HIP/Assets/Optimized/Geo/`details(“../CD_diva_optimize1/get_filename”,“filename”)`_optimized.fbx

Can anyone help me with the syntax?
Tks in advance
Emanuel “Manoo” Raimundo
3D generalist, going procedural!
www.artstation.com/manoo
User Avatar
Member
731 posts
Joined: Dec. 2006
Offline
Try “detail” instead of “details”. You also need the index:

detail(“../CD_diva_optimize1/get_filename”,“filename”,0)
Sean Lewkiw
CG Supervisor
Machine FX - Cinesite MTL
User Avatar
Member
14 posts
Joined: Oct. 2017
Offline
Thanks, mrCatfish, but I researched and that one is for attributes with float values, in my case it's a string (a filename).
Strangely, I opened the project on my other pc and it worked as is! Go figure…
Edited by animanoo - Jan. 11, 2019 17:38:03
Emanuel “Manoo” Raimundo
3D generalist, going procedural!
www.artstation.com/manoo
User Avatar
Member
17 posts
Joined: Feb. 2019
Offline
As I see it you were doing the right thing so that's why it worked. There is a lot of confusion here as there are two different expression functions "detail" and "details". The last one works with strings and have a different syntax (no index value).
  • Quick Links