3

I am trying to render video from Adobe After Effects using PHP through command line. When i try to render video from After effects render Queue, i can see in Task Manager that all CPU cores are using. i have following PHP script which takes AE template file and render video.

<?php
  exec('aerender.exe -project myproject.aepx -comp "Final" -mp  -output video.mov')

 // -mp - Additional processes may be created to render multiple frames simultaneously
?>

When i execute this PHP file from command line like

php /path/to/above_script_file.php

its working fine too. All CPU cores are using and video is rendering.

enter image description here

BUT when i execute same script from browser using WAMP server, rendering starts, all instances get starts but suddenly close and 1 or sometimes 2 After effects instances are running but in hanged position. No memory or CPU is changing.

enter image description here

These are my After Effects preferences

enter image description here

UPDATE: When i am trying to render using below command aerender -project /path/ -comp Final -mp -output out.mov

its working and using multiprocessing. but when trying to render from web app it show below error message in log file

There is an error in background rendering so switching to foreground rendering after 0 frames completed out of total 601 frames.

Message interpretation:enter link description here

The multiprocessing feature was unable to use all instances beyond a     certain point in the rendering process. This is an error that only shows     in the render log file.
2

You may want to try to write the output of your task to a file and tell your system to start it as a background task by adding the &:

exec('aerender.exe -project myproject.aepx -comp "Final" -mp -output video.mov >/dev/null &')

It might also be something in your server setup, the max. memory maybe?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.