Timeline handlng with python

Hello everyone,
I have two questions about getting information about segments using python.

  1. Can I somehow get information if the segment is hidden?
  2. Can I get information if the segment is connected and if it is, can I get information which seqences it is connected to?

Any help would be appreciated :smiley:

Cheers,
Lukas

  1. The PySegment has the β€œhidden” attribute to get/set this, do not forget to use get_value() if you are storing the Bool inside a variable.
  2. The PySegment has a connect_segments function which has a scoping argument that can be all reels, sequences reels, current reel, or current sequence (the default is all reels). You can then use the parent properties to find the sequences.
for connected_seg in segment.connected_segments():
    # parents are Track > Version > Sequence
    connected_sequence = connected_seg.parent.parent.parent

You can take a look at Help and Help for more information about the PySegment properties, functions, and attributes.

1 Like