Copy link to clipboard
Copied
Hey, I am working on a Premiere Pro plugin and wanted to know if it is possible to add a "Track Matte Key" effect using CEP or do I have to use the C++ framework? Kinda lost here.
This is possible, but it requires using the QE Dom which is not offically supported by Adobe:
app.enableQE();
var clip = qe.project.getActiveSequence().getVideoTrackAt(0).getItemAt(0);
var effect = qe.project.getVideoEffectByName("Track Matte Key");
clip.addVideoEffect(effect);
Copy link to clipboard
Copied
There is no method for applying effects in PPro's supported ExtendScript API.
Copy link to clipboard
Copied
This is possible, but it requires using the QE Dom which is not offically supported by Adobe:
app.enableQE();
var clip = qe.project.getActiveSequence().getVideoTrackAt(0).getItemAt(0);
var effect = qe.project.getVideoEffectByName("Track Matte Key");
clip.addVideoEffect(effect);
Copy link to clipboard
Copied
Hey Justin,
that's awesome! Will implement this in our plugin. Any idea how to set the video channel of the matte?
kind regards, andi
Copy link to clipboard
Copied
Sure, just find the property and set the value with the number of the video track you want to set the matte to.
var clip = app.project.activeSequence.videoTracks[0].clips[0];
var effect;
for (var i = 0; i < clip.components.length; i++) {
var component = clip.components[i];
if (component.displayName == "Track Matte Key") {
effect = component;
}
}
if (component) {
var prop = effect.properties[0];
prop.setValue(4);
}