clear_automation
Remove automation envelopes from a Session clip. Preview what would be cleared with a dry run, then confirm to delete specific or all parameter envelopes.
Instructions
Delete automation envelopes on a Session clip. Requires confirm=True.
With confirm=False it changes nothing and reports the envelope it would remove: its
range, where the low and the high point sit, and how densely it was sampled to find
them. That report covers one named parameter; with all_envelopes it says only whether
the clip is automated at all, because has_envelopes is one flag for the whole clip. To
see which parameters those envelopes belong to, read clip.automation_envelopes with
lom_get and then each automation_envelopes[i].parameter.name.
Returns:
Dictionary reporting the clearance, or the envelopes that would go.
Note:
A cleared envelope is gone, and the parameter falls back to whatever value it holds
outside the clip rather than to the first breakpoint. Sample it with read_automation
first if the shape might be wanted back, since nothing here restores it.
The dry run samples the curve rather than reading its breakpoints, so a feature
narrower than the reported sampling step can still sit between two samples. Where
the exact shape matters, read it with read_automation at a resolution you choose, or
read the breakpoints out of the saved file with als_read.
To change a curve rather than remove it, write_automation with ``clear_first=True``
replaces it in one call and needs no clearing first.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | LOM path to a Session clip, song.tracks[N].clip_slots[M] with or without a trailing .clip, as an alternative to track and slot. A song.tracks[N].arrangement_clips[i] path is refused with code region_not_addressable. | |
| slot | No | Clip slot index in track.clip_slots, counted from 0, which is the scene the clip sits in. Give track and slot, or give path instead. These are Session coordinates; an Arrangement clip has none. | |
| track | No | Session track index in song.tracks, counted from 0. Give track and slot, or give path instead. These are Session coordinates; an Arrangement clip has none. | |
| confirm | No | True carries the removal out. False changes nothing and returns a report of what the call would remove, which is how to look before committing to it. | |
| parameter | No | LOM path to the one DeviceParameter whose envelope should go, e.g. 'song.tracks[0].mixer_device.volume'. Leave empty only when all_envelopes is true. | |
| all_envelopes | No | True clears every envelope on the clip, ignoring ``parameter``. One of this or ``parameter`` has to be given; neither is refused rather than treated as clear everything. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||