need to get primvar values (focalLength) of a camera lop inside a sopmodify/sopcreate. Fetching the packed usd primitive is straightforward but I cant figure out how to read specific primvars from it. the usd_primvar vex function just always returns 0. seems simple but I'm pretty stuck here. that's the primwrangle code I'm using inside a sopmodify (which imports the camera primitive)
so I thought I was working with primvars when in reality it was usd attributes. with a wrangle LOP I can now copy usd attribs/primvars from the camera to a target prim. When unpacking it in the sopmodify there's an option to import usd attributes/primvars, and I get the copied attribute as a primitive attribute in sops.
is there a more straightforward way to import a primvar as a detail attribute tho? i suspect the usd_attrib function doesnt work in a SOP wrangle because theres no stage handle available? then again theres a 90% chance its user error... ^^