-
Notifications
You must be signed in to change notification settings - Fork 1
/
MarkerQueueIT.jsx
41 lines (31 loc) · 1.28 KB
/
MarkerQueueIT.jsx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
// Name: MarkerQueueIT Version: 0.2
// Author: Keerah.com
// Description: This script enqueues/renders all composition marker areas
//
// Change the variables in lines 10 - 12 to your output preferences
// Uncomment the app.project.renderQueue.render() command to immediately render the queued items
if (app.project.activeItem != null && app.project.activeItem instanceof CompItem) {
var sPath = "D:\\MYPROJECTS\\autorender\\"; // the path for output files
var sRStem = "Best Settings"; // render settings template name
var sOMtem = "Lossless"; // output module template
var myComp = app.project.activeItem;
var markerProp = myComp.markerProperty;
var mNum = markerProp.numKeys;
app.beginUndoGroup("Queue composition markers'areas");
for (i=1;i<=mNum;i++) {
curMarker = markerProp.keyValue(i);
curRQItem = app.project.renderQueue.items.add(myComp);
curRQItem.outputModule(1).applyTemplate(sOMtem);
curRQItem.applyTemplate(sRStem);
curOM = curRQItem.outputModule(1);
curRQItem.timeSpanStart = markerProp.keyTime(i);
curRQItem.timeSpanDuration = curMarker.duration;
fileOut = curOM.file;
fileOutStr = curMarker.comment;
curOM.file = new File(sPath + fileOutStr);
}
app.endUndoGroup();
//app.project.renderQueue.render()
} else {
alert("Select a composition");
}