Hi all!.
I have very good good news for the Mac users.
finally I write a script in order to convert Videos AVI or MPG to
Teclast AVI Video.
My program its under the GPL GNU license, it names "Teclast C260 Converter for Mac"
And cuz I love the Opensource, this is Open Souce and free.
Only follow this steps for make the program and run it:
1.- Download
mencoder for mac here
2.- Copy the application to
/usr/bin and
/usr/local/bin
How to do This???
Simply. Open a Terminal login as root:
sudo -s Type your root password
Type this:
cp -R /Users/Yourusername/Desktop/mencoder /usr/bin
cp -R /usr/bin/mencoder /usr/local/bin.
If dont shows any error message, let go.
3.- Now we make the Script of Converter Video:
3.1.- Open Terminal again
3.2.- Login as root
sudo -s
3.3.- Go to the Desktop of your account:
cd /Users/yourUsername/Desktop
3.4.- Type
nano (this is an text-plane editor like Vim in Linux)
3.5.-
Copy and paste this code onto the Terminal Window:
----------------------------------------------------------------------
#!/bin/bash
# Comprobe that receives the file name to convert
if [ -z $1 ]; then
clear
echo "
******* Teclast C260 AVI Converter *******
---------------by Voldemort--------------
You must write the file name to convert (AVI or MPG)"
exit 1
fi
# Get name and extension of main file
# Name of main file serves to get the name of Converted Video
# Extension serves to know the file format to convert
name=${1%.*}
ext=${1##*.}
# Determines extension type
case $ext in
mpeg|mpg) ext="mpeg";;
avi) ;;
*) echo "Extension $ext not valid"; exit 1;;
esac
# It creates the Converted Video
name=${name}_convertido.${ext}
command=/usr/local/bin/mencoder
if [ -x $command ]; then
echo "
******** Converting Video for Teclast C260 *************
"
$command -noodml "${1}" \
-of avi \
-o "$name" \
-ofps 22 \
-vf-add scale=320:240 \
-vf-add expand=320:240:-1:-1:1 \
-srate 44100 \
-ovc xvid \
-xvidencopts bitrate=500:max_bframes=0:quant_type=h263:me_quali ty=4 \
-oac lavc \
-lavcopts acodec=mp2:abitrate=128
echo "
******** Video has converted successfully *******"
else
echo "$command is missing"
exit 1;
fi
------------------------------------------------------------------------------------
3.6.- Once pasted the text, save it with "CTRL+O"
put this name: Teclast.sh
3.7.- Once made this, exit nano: CTRL+X
3.8.- As you can see, the Teclast.sh file its in your desktop, now in order to execute it, we need to assign Excecution permissions, type this:
chmod +x Teclast.sh
and Its ready.
Enjoy it.
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
HOW TO USE IT:
The use is really simple.
In this case I put the file on the Desktop, but you can change the path of this, and place it whatever you want:
SINTAXIS:
sh Teclast.sh OriginalVideo.avi
Dont worry man, no needs to put a second file.
The script make the Video converter with a name like this: OriginalVideo_converted.
Wait until the Script do his work, and when its 100%, Voila!!!
You have the Video ready to play in your Teclast C260.
NOTE: IF YOU EXPERIMENT PROBLEMS WITH YOUR C260 PLAYER, POSSIBLY YOU HAVE THE 1.0.0.0 FIRMWARE, PLEASE CHECK THE POST ABOUT UPDATE TO THE LATEST FIRMWARE 1.10.0001
-- It fix slow transfer connection and other problems
NOTE 2: For a Uknown reson this post shows the phrase "quality" this:
qual ity, please when you copy the code write it right "quality".
If you dont fix this, the script dont work.
Have Fun!!!
