How can I return the playhead frame number position, in the VSE, to a variable in script?
I'm not sure where in the API to look.
Blender Stack Exchange is a question and answer site for people who use Blender to create 3D graphics, animations, or games. It only takes a minute to sign up.Sign up to join this community
The VSE current frame is the same as the current frame for the rest of blender, which is a property of the current scene.
It can be accessed with
bpy.context.scene.frame_current and set with
The best way to figure out the Python code for a specific property is to find it in the interface and hover your cursor over it, which will reveal the python code. In this case you can hover your cursor over the frame values in a Timeline editor.