Skip to main content
qwerwqer
Known Participant
September 12, 2017
Question

Query armed state of selected track in multitrack?

  • September 12, 2017
  • 1 reply
  • 1376 views

On my continuing quest to buld the perfect CEP Audition Punch & Roll extension, I've got a question.


I've got a full, non-destructible extension working for Punch & Roll on Audition now, which I'm planning to release on the marketplace for free. -

Adobe Audition Punch & Roll Extension - Non-Destructive - YouTube

It's a significant upgrade over my previous destructive, waveform-only version, and infinitely more reliable.

Right now, however, I have to enforce an 'only record on track 1' limitation for the extension.
The reason for this is that I have no other way to guarantee that the SELECTED track is the same track that the recording is taking place on, so trimming clips doesn't work properly if you have a different track selected than the one that is armed to record.

I currently work around this by 'shifting to previous track' multiple times before starting a punch (i.e. ensuring that track 1 is always the selected track.)
This is pretty silly, and curtails some of the more advanced use cases that folks are asking for.

So, my question(s) are relatively simple -
1) Is there a way to query whether recording is armed on the SELECTED track? I can query whether recording is enabled, but that doesn't take into account track selection - it just returns true if ANY track is armed. If I can query this, and the current selected track is not armed, I can pop a dialog saying 'nope, please select an armed track, sorry!' and prevent mishaps.

2) Can I force your track selection TO an armed track? If I can do that, I can force your track selection to the first armed track in sequence, and that similarly solves the problem.


Thanks for any help!
Travis

This topic has been closed for replies.

1 reply

Participating Frequently
September 12, 2017

Hi,

There is currently no support to request the "armed" state of a track. Unfortunately I can't offer a workaround here.

The selection of a track can be accessed via the read/write property "selected" at the AudioTrack object.

mfg,

patrick

qwerwqer
qwerwqerAuthor
Known Participant
September 12, 2017

So, if that's the case, I can probably set up something so that you can set the desired punch track in the extension dialog, and it can ensure that it is properly selected for a punch (if you want to choose track 3 or whatever)


However, I'm having trouble sussing out the proper syntax to actually get an AudioTrack to operate on, and can't find any samples anywhere.
Also, the script dictionary doesn't show a 'selected' property for the AudioTrack object. (I see one for a Clip though, for instance) -

Is there any chance you can direct me to how I'd access the selected property on a track, to query and set it, or where I'd find documentation on doing so?

Thanks!

csGlobalInterface.evalScript('app.activeDocument.audioTracks.getAudioTrack(1).selected=1', function(result)

{

alert( result );

});

qwerwqer
qwerwqerAuthor
Known Participant
September 13, 2017

Just a little bump on this - would love to try and implement something based on selected track, but am having trouble finding information supporting the read/wright selected state -