Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'Avoid After Effects slowdowns' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Avoid After Effects slowdowns
Authored by: humanbulk on Dec 12, '11 01:38:21AM

I improve the script for my own system. Also I add a little clock to reset the priority set every minute.


repeat with shotcount from 1 to 99999
tell application "Finder" to set theApps to name of every process

set newPriority to "5"
set theApp to "After Effects"
set thePID to do shell script "ps -axww | /usr/bin/grep '[/]" & theApp & "'| awk '{print $1}' | head -1"
Renice(newPriority, thePID, theApp)

set newPriority to "15"
set theApp to "aerendercore"
set thePID to do shell script "ps -axww | /usr/bin/grep '[/]" & theApp & "'| awk '{print $1}' | head -1"
Renice(newPriority, thePID, theApp)

set newPriority to "15"
set theApp to "aerender"
set thePID to do shell script "ps -axww | /usr/bin/grep '[/]" & theApp & "'| awk '{print $1}' | head -1"
Renice(newPriority, thePID, theApp)

set newPriority to "15"
set theApp to "aeren"
set thePID to do shell script "ps -axww | /usr/bin/grep '[/]" & theApp & "'| awk '{print $1}' | head -1"
Renice(newPriority, thePID, theApp)

set newPriority to "20"
set theApp to "CS5.5ServiceManager"
set thePID to do shell script "ps -axww | /usr/bin/grep '[/]" & theApp & "'| awk '{print $1}' | head -1"
Renice(newPriority, thePID, theApp)

set newPriority to "0"
set theApp to "Adobe QT32 Server"
set thePID to do shell script "ps -axww | /usr/bin/grep '[/]" & theApp & "'| awk '{print $1}' | head -1"
Renice(newPriority, thePID, theApp)

set newPriority to "15"
set theApp to "iTunes"
set thePID to do shell script "ps -axww | /usr/bin/grep '[/]" & theApp & "'| awk '{print $1}' | head -1"
Renice(newPriority, thePID, theApp)

set newPriority to "15"
set theApp to "Dropbox"
set thePID to do shell script "ps -axww | /usr/bin/grep '[/]" & theApp & "'| awk '{print $1}' | head -1"
Renice(newPriority, thePID, theApp)

set newPriority to "15"
set theApp to "aeselflink"
set thePID to do shell script "ps -axww | /usr/bin/grep '[/]" & theApp & "'| awk '{print $1}' | head -1"
Renice(newPriority, thePID, theApp)

set newPriority to "-15"
set theApp to "kernel_task"
set thePID to do shell script "ps -axww | /usr/bin/grep '[/]" & theApp & "'| awk '{print $1}' | head -1"
Renice(newPriority, thePID, theApp)

set newPriority to "-15"
set theApp to "WindowServer"
set thePID to do shell script "ps -axww | /usr/bin/grep '[/]" & theApp & "'| awk '{print $1}' | head -1"
Renice(newPriority, thePID, theApp)

set newPriority to "-5"
set theApp to "Finder"
set thePID to do shell script "ps -axww | /usr/bin/grep '[/]" & theApp & "'| awk '{print $1}' | head -1"
Renice(newPriority, thePID, theApp)

set newPriority to "-5"
set theApp to "Dock"
set thePID to do shell script "ps -axww | /usr/bin/grep '[/]" & theApp & "'| awk '{print $1}' | head -1"
Renice(newPriority, thePID, theApp)

delay (60 * 1) -- delay one minute
end repeat


on Renice(newPriority, thePID, theApp)
try
set theConfirmation to (do shell script "renice " & newPriority & " -p " & thePID)
on error
set theConfirmation to (do shell script "renice " & newPriority & " -p " & thePID with administrator privileges)
end try
end Renice



[ Reply to This | # ]