Hi Python community.

I know the question has surely be asked before but I can't find information about this...

I've read the documentation there:

http://docs.thefoundry.co.uk/nuke/63/pythondevguide/metadata.html#createmetadatcam

The given example create a camera animated (baked) using metadatas.

This in interesting so I've tried to use expression to set camera position directly from metadatas without bake them, just "on the fly".

I've created a lttle sequence of frame with a "exr/pos" calue wich is the frame number. So test.0001.exr has "exr/pos" value of 1, test.0002.exr has "exr/pos" value of 2, etc...

There is my camera translateX expression:

ret=float(nuke.toNode("Read1").metadata()["exr/pos"])
print ret, nuke.frame()

The problem is the "ret" value isn't always the value it should be. Manytime, my expresion print: 3.0 4 or even 3.0 5

And once a bad value has been setted, I suppose this value is stored in a cache because my expression is not evaluated again when I change frame... :(

So I ask you guys, is there a way to make expressions work?

Thanks in advance for any suggestion.

Regards,

Dorian
_______________________________________________
Nuke-python mailing list
[email protected], http://forums.thefoundry.co.uk/
http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-python

Reply via email to