# This application is released under the GNU General Public License 
# v3 (or, at your option, any later version). You can find the full 
# text of the license under http://www.gnu.org/licenses/gpl.txt. 
# By using, editing and/or distributing this software you agree to 
# the terms and conditions of this license. 
# Thank you for using free software!

# Cover Manipulation (c) BruceLee 2011 <eu.gabii@yahoo.com>


here=`echo $0 | sed -e 's/\/'$(basename $0)'$//'`
if [ "$here" = "`basename $0`" ]; then here="`pwd`"; fi
cd $here

convert -resize 291x246\! "cover.png" "newcover.png"
mv "newcover.png" "cover.png"
convert "cover.png" "mask.png" -alpha Off -compose Copy_Opacity -composite "newcover.png"
mv "newcover.png" "cover.png"

