Hi! I wasn’t sure if this was something possible through a workaround, or if it’s something that might be able to be implemented.
Thank you!
Hi! I wasn’t sure if this was something possible through a workaround, or if it’s something that might be able to be implemented.
Thank you!
Hi @CraigK !
you can change this property with this code:
var activeComp = app.project.activeItem;
activeComp.pixelAspect = 2;
using the the project action “run javascript code”, this code will change the active composition pixel aspect ratio to 2, you can change this number as you need.
currently this is the only workaround for changing this property.
This property will be implemented in the next update.
Please let me know if you need a more specific piece of code for your automation.
Thanks,
Alon
Ah! Thank you!! Is it possible to change the aspect ratio of footage, as well using the same kind of workaround?
Yes, it will work for both
It did work on the Comp aspect ratio, but changing the text from Comp to Layer just changed the Comp aspect ratio.
changing the text won’t work, you have to find the footage first, you have to loop on the items in the project like how the loop in the script does but in code,
can you explain what are the footage you are trying to find so I can send you the appropriate code?
For Example this code will change the aspect ratio of all the selected footage in the project panel:
for (var i = 1 ; i <= app.project.numItems ; i++){
if (app.project.item(i).selected){
try{
app.project.item(i).pixelAspect = 2;
}catch(err){}
}
}
YES!!! That did it! The combination of those two javascripts automated exactly what I needed. I needed it to change the Comp to a square pixel aspect ratio, and make the footage selected a 2:1 aspect ratio.
Thank you!!!
Nice!, glad I was able to help, I already implemented this property but it will have to wait to the full release.
Sorry - I’m now realizing when trying to alter the aspect ratios in both the selected footage and the comp it’s in, it won’t do both in one automation. It’s like one cancels out the other. To be clearer, it only applies the aspect ratio to the comp, and not the layer, if I run both javascript in the same automation - even if they are separated into two different “loops”.
I just came up with a temporary workaround, that I have to select the footage in my comp, and also select the footage in my project window. That seems to make it work for now.
The code that I send you affect only the selected footage items in the project panel and not the selected layers in the active composition, so if you want to change the selected layers aspect ratio there is another part of the automation that is currently missing.
You can create this automation by first looping on the layers in the active composition, select the source footage of the selected layers in the project panel and then run the JavaScript code.
All the steps:
I hope that this iteration will finally work well, you can download the automation,
Download-
Pixel Aspect.json (8.0 KB)
Thanks,
Alon
Thank you, so much!!!
VERY much appreciated. That makes sense!