ZBrushCentral

Adding a (camera) key via Script ?

Hi,

I am trying to set up a simple camera bookmark system that doesn’t need me clicking into the timeline each time I save a camera position (I have it hidden most of the time).
I played around with scripts and macros but setting a key frame in the timeline doesn’t seem to be recorded. What’s the command line for

a) setting a key at a specific time
b) setting the “current time” slider to a specific time (guess I could use the arrow keys instead but if there’s another way …)

Thanks,
Jens

It’s not currently possible to set a Timeline keyframe through zscript. What you can do is record your model’s position using the [TransformGet or [MTransformGet commands. You could then have zscript buttons that store/restore the positions of your model. (This is essentially the method used by the ZAppLink Views buttons.)

You might find a use for ModelVues8, a little plugin that lets you store and retrieve 8 model views. The downloadable zip file includes the .txt ZScript which shows exactly how it works so you can adapt the script to your own purposes.

ModelVues8 - save camera views

Sven

hey that’s great thanks. Violating your script right now to make it into the desired one key to save view - one key to load view script. This is an excellent starting point.

thanks