started tracking repo

main
Jorge Vásquez Pérez 1 month ago
commit 288f85b3a3

@ -0,0 +1,56 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<ExtensionManifest xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" ExtensionBundleId="com.yorchnet.yToolBox" ExtensionBundleVersion="1.0" Version="12.0"> <!-- MAJOR-VERSION-UPDATE-MARKER -->
<ExtensionList>
<Extension Id="com.yorchnet.yToolBox.Panel1" Version="12.0.0"/>
</ExtensionList>
<ExecutionEnvironment>
<HostList>
<Host Name="AEFT" Version="13.0"/>
</HostList>
<LocaleList>
<Locale Code="All"/>
</LocaleList>
<RequiredRuntimeList>
<RequiredRuntime Name="CSXS" Version="12.0"/> <!-- MAJOR-VERSION-UPDATE-MARKER -->
</RequiredRuntimeList>
</ExecutionEnvironment>
<DispatchInfoList>
<Extension Id="com.yorchnet.yToolBox.Panel1">
<DispatchInfo>
<Resources>
<MainPath>./client/index.html</MainPath>
<ScriptPath>./host/functions.jsx</ScriptPath>
<CEFCommandLine>
</CEFCommandLine>
</Resources>
<Lifecycle>
<AutoVisible>true</AutoVisible>
</Lifecycle>
<UI>
<Type>Panel</Type>
<Menu>yToolBox</Menu>
<Geometry>
<Size>
<Height>580</Height>
<Width>1020</Width>
</Size>
<MaxSize>
<Height>800</Height>
<Width>1200</Width>
</MaxSize>
<MinSize>
<Height>400</Height>
<Width>600</Width>
</MinSize>
</Geometry>
<Icons>
<Icon Type="Normal">./client/img/TeEx_HTML_TEST_23x23_N.png</Icon>
<Icon Type="RollOver">./client/img/TeEx_HTML_TEST_23x23_R.png</Icon>
<Icon Type="DarkNormal">./client/img/TeEx_HTML_TEST_23x23_DN.png</Icon>
<Icon Type="DarkRollOver">./client/img/TeEx_HTML_TEST_23x23_DR.png</Icon>
</Icons>
</UI>
</DispatchInfo>
</Extension>
</DispatchInfoList>
</ExtensionManifest>

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

After

Width:  |  Height:  |  Size: 93 KiB

File diff suppressed because it is too large Load Diff

After

Width:  |  Height:  |  Size: 96 KiB

@ -0,0 +1,43 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<link href="./style.css" type="text/css" rel="stylesheet">
<!-- <script src="./index.js"></script> -->
</head>
<body>
<div class="container">
<div class="col">
<h1>yToolBox</h1>
<div class="row">
<button id="plus1BTN">+1</button>
<button id="minus1BTN">-1</button>
<button id="tagWipBTN">WIP</button>
<button id="tagDoneBTN">Done</button>
<button id="collectBTN" >Collect</button>
</div>
<button id="ySetStrBTN" class="fill-width">ySetStructure</button>
<button onclick="document.location.href ='./yCompHearder.html'" class="fill-width">yCompHerder</button>
<button id="yFlatBTN" class="fill-width">yFlatten</button>
<button class="fill-width">yRenderToProjectPath</button>
<button class="fill-width">yRenderMarkers</button>
<button class="fill-width">yColorProbe</button>
<button class="fill-width">yBindBetween2</button>
<button class="fill-width">yBindBetween2</button>
<button class="fill-width">yCornerPinOffset</button>
<button class="fill-width">yPuppetRig</button>
<button class="fill-width">yStopMotionLayer</button>
</div>
</div>
<div class="anchorBottomRight"><p>v1.1</p></div>
</body>
<script src="./CSInterface.js"></script>
<script src="./index.js"></script>
</html>

@ -0,0 +1,53 @@
// load interface
var CSI = new CSInterface();
/*
// Example: Saving a variable to a file
var settings = { "theme": "dark", "lastFolder": "/path" };
path="./settings.json"
window.cep.fs.writeFile(path, JSON.stringify(settings));
*/
//define buttons
var plus1BTN = document.querySelector("#plus1BTN");
var tagWipBTN = document.querySelector("#tagWipBTN");
var collectBTN = document.querySelector("#collectBTN");
var tagDoneBTN = document.querySelector("#tagDoneBTN");
var yFlatBTN = document.querySelector("#yFlatBTN");
//add listeners
minus1BTN.addEventListener("click", minus1);
plus1BTN.addEventListener("click", plus1);
tagWipBTN.addEventListener("click", tagWip);
collectBTN.addEventListener("click", collect);
tagDoneBTN.addEventListener("click", tagDone);
ySetStrBTN.addEventListener("click", ySetStr);
yFlatBTN.addEventListener("click", yFlat);
//jsx wrappers
function minus1() {
CSI.evalScript("minus1()");
}
function plus1() {
CSI.evalScript("plus1()");
}
function tagWip() {
CSI.evalScript("tagWip()");
}
function collect() {
CSI.evalScript("collect()");
}
function tagDone() {
CSI.evalScript("tagDone()");
}
function ySetStr() {
CSI.evalScript("ySetProject()");
}
function yFlat() {
CSI.evalScript("yFlattenSelectedFolderContents()");
}

@ -0,0 +1,112 @@
:root {
--ae-dark-gray:#151515;
--ae-light-gray:#999 ;
--my-orange:#ff7300;
--my-pink:#ff007a;
--my-ease: cubic-bezier(0.99,0.01,0.01,0.99);
}
html{
background-color: var(--my-pink);
}
body {
background-image: url('img/SkullButton_Transp.svg') ;
background-size:1000px; /* Optional */
background-repeat:no-repeat;
background-position-x: -500px;
background-position-y: 50%;
background-attachment:scroll;
}
html, body{
height: 100%;
width: 100%;
margin: 0;
padding: 0;
}
p{
font-size: 14px;
}
h1{
font-size: 22px;
}
.pink{
color: var(--my-pink);
}
body {
color: white;
font-size: 5em;
padding: 0px;
overflow: hidden;
}
div{
justify-content: center;
align-items: center;
display:flex;
flex-direction:row;
transition: opacity 0.5s;
transition-timing-function: var(--my-ease);
}
button, input[type=text]{
background-color: var(--ae-dark-gray);
color: var(--ae-light-gray);
/*color: white;*/
padding: .5em;
border-radius: .75em;
margin: .33em;
font-size: 12px;
transition: padding 1s, background-color 0.5s, color 1s;
transition-timing-function: var(--my-ease);
}
button:hover,#tagWipBTN:hover,#tagDoneBTN:hover{
background-color: var(--my-pink)*.25;
padding: 1em;
color: white;
}
.fill-width{
width: 100%;
}
.anchorBottomRight {
position: absolute; /* Positions relative to the .parent */
bottom: 5px;
right: 15px;
}
.anchorTopLeft {
position: absolute; /* Positions relative to the .parent */
top: 5px;
left: 15px;
}
.container{
height:100%;
width:100%;
}
.col{
display: flex;
flex-direction: column;
}
.row{
display: flex;
flex-direction: row;
}
input[type=text]{
box-sizing:content-box;
border-radius: .5em;
background-color: #151515;
}
.subContainer{
border-width: 2px;
border-radius: 30px;
border-style: solid;
border-color: var(--ae-light-gray);
padding: 30px;
}
.hidden{
display: none;
}
.shown{
display: block;
}
.fortyFive{
width: 45%;
}

@ -0,0 +1,52 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<link href="./style.css" type="text/css" rel="stylesheet">
<!-- <script src="./index.js"></script> -->
</head>
<body>
<div class="container">
<div class="col">
<div class="row">
<button onclick="srSub.classList.toggle('hidden')">Search & Replace</button>
<button onclick="spSub.classList.toggle('hidden')">Suffix / Prefix</button>
<button onclick="reSub.classList.toggle('hidden')">Rename</button>
</div>
<div id="srSub" class="col subContainer fill-width" id="s&r">
<input width="100%" class="fill-width" type="text" placeholder="SEARCH FOR TEXT">
<input width="100%" class="fill-width" type="text" placeholder="REPLACE WITH TEXT">
<button>Search & Replace</button>
</div>
<div id="spSub" class="col subContainer fill-width hidden" id="s&r">
<div class="row fill-width">
<input class="fill-width" type="text" placeholder="SUFFIX"><button class="fortyFive">Add Suffix</button>
</div>
<div class="row fill-width">
<input class="fill-width" type="text" placeholder="PREFIX"><button class="fortyFive">Add Preffix</button>
</div>
</div>
<div id="reSub" class="col subContainer fill-width hidden " id="s&r">
<div class="row fill-width">
<input class="fill-width" type="text" placeholder="Rename"><button class="fortyFive">Rename</button>
</div>
</div>
</div>
</div>
<div class="anchorBottomRight"><p>v1.1</p></div>
<div class="anchorTopLeft"><button onclick="document.location.href ='./index.html'"> < </button></div>
</body>
<script>
srSub = document.getElementById("srSub");
spSub = document.getElementById("spSub");
reSub = document.getElementById("reSub");
</script>
<script src="./CSInterface.js"></script>
<script src="./index.js"></script>
</html>

@ -0,0 +1,261 @@
/* TO-DO : flatten deletes stuff outside of the selected comp too. :S*/
function pad(n,i){ //pad n with ceroes up to i places.
if (String(n).length>=i){
return String(n)
}else{
dif = i- (String(n)).length;
padding = "";
for (p=0;p<dif;p++){
padding = padding+"0"
}
return padding+String(n)
}
}
function getSelectedProjectItems(){
var items = [];
var p = app.project;
for ( var i = 1 ; i <= p.numItems ; i ++ ){
var item = p.item(i);
if ( (item.selected) && ((item.typeName == "Composition")||(item.typeName == "Folder")) ){
//alert(item.typeName);
items.push(item);
}
}
return items;
}
function prSlCmps(){
//save a reference of the original file's path.
ogFile = app.project.file;
//alert(ogFile);
//request a folder to dump these.
dumpFolder = Folder.selectDialog("Choose a folder to DUMP all these ");
//alert(dumpFolder.absoluteURI);
sl = getSelectedProjectItems();
ln = sl.length;
ids = [];
for (var i =0; i < ln ; i++ ){
ids.push(sl[i].id);
}
for (var i =0; i < ln ; i++ ){
//alert(sl);
itemID = ids[i];
workComp = app.project.itemByID(itemID);
//workComp.comment = "COLLECTED";
projFile = new File( dumpFolder.absoluteURI+"\\"+workComp.name+".aep" );
//alert( projFile );
//save a new file per selected comp, named as the comp itself. in the previously given folder and save a reference of its filepath
app.project.save(projFile);
//open each of the given file paths, reduce them and save them.
app.open(projFile);
workComp = app.project.itemByID(itemID);
//alert(workComp);
//workComp.comment = "COLLECTED";
app.project.reduceProject([workComp]);
app.project.save(projFile);
app.executeCommand(app.findMenuCommandId("Collect Files..."));
app.open(ogFile);
}
for (var i =0; i < ln ; i++ ){
itemID = ids[i];
workComp = app.project.itemByID(itemID);
workComp.comment = "collected";
app.project.save();
}
}
function incVer( amt ){
app.beginUndoGroup("Invcrementing Versions");
sl = getSelectedProjectItems();
for ( var i = 0; i < sl.length ; i ++){
var item = sl[i];
var ogName = item.name;
var ver = ogName.match("[vV|rR][0-9]{1,999}")[0];
var verDenom = ver.substring(0,1);
var verN = parseInt(ver.substring(1,ver.length));
var newName = ogName.substring(0,ogName.search(ver));
item.comment = ""; //remove the "collected" comment
item.name = newName+verDenom+pad((verN+amt),ver.length-1);
}
app.endUndoGroup();
}
function changeLabel( n ){
sl = getSelectedProjectItems();
for ( var i = 0; i < sl.length ; i ++){
var item = sl[i];
if ( n == 8 ){
item.comment = ""; //remove the "collected" comment
}
item.label = n;
}
}
function purgeEmptyFolders(){
//app.beginUndoGroup("Purge Empty Folders")
var emptyFolders = [];
var p = app.project;
for ( var i = p.numItems ; i >= 1 ; i -- ){
item = p.item(i);
if ( item.typeName == "Folder" ){
if ( item.numItems <= 0 ){
item.remove();
}
}
}
//app.endUndoGroup()
}
function getAllItems( folderItem ){
var items = [];
var folders = [];
for ( var i = 1 ; i <= folderItem.numItems ; i ++ ){
var item = folderItem.item(i);
if ( (item.typeName != "Folder") ){
//if ( (isInArray( items ,item )) == false ){
items.push( item );
//}
}else{
var new_items = getAllItems(item);
for ( var j = 0 ; j < new_items.length ; j ++ ){
new_item = new_items[j];
//if ( (isInArray ( new_item )) == false ){
items.push ( new_item );
//}
}
}
}
return items
}
function flatten( items, root ){
app.beginUndoGroup("Flatten Selected Folder Contents")
for ( var i = 0; i < items.length ; i ++){
item = items[i];
item.parentFolder = root;
}
app.endUndoGroup()
purgeEmptyFolders();
}
/* Exposed Functions */
function plus1() {
incVer(1);
}
function minus1() {
incVer(-1);
}
function minus1() {
incVer(-1);
}
function tagWip() {
changeLabel( 8 );
}
function collect() {
prSlCmps();
tagDone();
//alert("It's alive, it's ALIVE!!!!2");
}
function tagDone() {
changeLabel( 9 );
}
function yFlattenSelectedFolderContents(){
flatten( getAllItems( getSelectedProjectItems()[0] ) , getSelectedProjectItems()[0] );
}
function ySetProject(){
app.beginUndoGroup('ySetProject');
var preStruct = [
"01_MAIN",
"02_pComps",
"03_Images",
"04_Movies",
"05_Audio",
"06_Tools",
"07_Ref",
"08_Projects"
];
var newStruct = [];
var projectItems = [];
for(i=1;i<=app.project.items.length;i++)
{
if(app.project.items[i].parentFolder.name=='Root'){
projectItems.push(app.project.items[i].name);
}
}
//to start a new organized project since the beginning
if (projectItems.length == 0){
newStruct = preStruct;
}else{
for(a=0;a<preStruct.length;a++){
if ((projectItems.getOne(preStruct[a]))==-1){
newStruct.push(preStruct[a]);
}
}
}
for(i = 1;i<=newStruct.length;i++)
{
app.project.items.addFolder(newStruct[i-1]);
if ( app.project.items[i].name == preStruct[0] ) //Put in MAIN.
{
//alert("yes");
//app.project.items[i].items.addComp("JOBCODE_TYPE_[Scene_name]_vA_r000",1920,1080,1,30,23.976);
}
}
saveNow = confirm("Project Succesfully Set, Save Project?",true,"ySetProject");
if(saveNow==true){
app.project.save()
}else{
}
}
function renderMarkers(){
p = app.project;
rq = p.renderQueue;
rqi = rq.items;
comp = p.activeItem;
var myRenderNull = comp.layer("Render");
if ( myRenderNull == null ){
myRenderNull = app.project.activeItem.layers.addNull();
myRenderNull.name = "Render";
myRenderNull.inPoint = -1;
myRenderNull.outPoint = -1;
alert('Created "Render Stills" layer.\nAdd markers to this layer and run again to render stills.');
}
markers= myRenderNull.property("Marker");
for ( var j = 1 ; j <= markers.numKeys ; j ++ ){
i = rqi.add( comp );
var destPath = i.outputModule(1).file.path;
//i.outputModule(1).applyTemplate("PNG+");
var markerName = markers.keyValue(j).comment;
i.timeSpanStart = markers.keyTime(j);
i.timeSpanDuration = comp.frameDuration;
var destName = comp.name.replace(" ","_");
var destFrame = markers.keyTime(j) / comp.frameDuration;
if ( markerName == "" ){
i.outputModule(1).file = new File( destPath + "/" + destName + "_Still_f" + "[####]" )
}else{
i.outputModule(1).file = new File( destPath + "/" + destName + "_Still" + "_f[####]_" + markerName )
}
//alert( i.outputModule(1).file );
//i.outputModule(1).includeSourceXMP = true;
rq.render();
}
//alert(i.timeSpanStart);
//alert(i.timeSpanDuration);
}

@ -0,0 +1,8 @@
## data.properties file for en_US
testString=testString_en_US
label.value=testString_en_US
input.value=Submit_en_US
legend.innerHTML=Personal_Information_en_US
textarea.a.innerHTML=Information_en_US blablabla...
textarea.aa.innerHTML=Report a bug when you see this string!

@ -0,0 +1,8 @@
## data.properties file for ja_JP
testString=testString_ja_JP
label.value=testString_ja_JP
input.value=Submit_ja_JP
legend.innerHTML=Personal_Information_ja_JP
textarea.a.innerHTML=Information_ja_JP blablabla...
textarea.aa.innerHTML=Report a bug when you see this string!

@ -0,0 +1,8 @@
## data.properties file for default
testString=testString_default
label.value=testString_default
input.value=Submit_In_default
legend.innerHTML=Personal_Information_default
textarea.a.innerHTML=Information_en_US blablabla...
textarea.aa.innerHTML=Report a bug when you see this string!

@ -0,0 +1,8 @@
## data.properties file for zn_CH
testString=testString_zn_CH
label.value=testString_zn_CH
input.value=Submit_zn_CH
legend.innerHTML=Personal_Information_zn_CH
textarea.a.innerHTML=Information_zn_CH blablabla...
textarea.aa.innerHTML=Report a bug when you see this string!

@ -0,0 +1 @@
application/vnd.adobe.air-ucf-package+zip
Loading…
Cancel
Save