if [ $BITRATE -lt 650000 ] then if [ $WIDTH -gt 800 ] then FULL=1 echo ...setting lowres ON, 1/2 resolution else mplayer -quiet -framedrop -noslices "$NAME" exit 0 fi else if [ $WIDTH -lt 800 ] then if [ $BITRATE -gt 65000 ] then FULL=1 echo ...setting lowres ON, 1/2 resolution elif [ $BITRATE -gt 1024000 ] then FULL=2 echo ...setting lowres ON, 1/4 resolution else echo ...playing video with original resolution mplayer -quiet -framedrop -noslices "$NAME" fi else if [ $WIDTH -gt `expr 4 \\* $MAX_WIDTH` -o $BITRATE -gt 3000000 ] then FULL=3 echo ...setting lowres ON, 1/8 resolution elif [ $WIDTH -gt `expr 2 \\* $MAX_WIDTH` -o $BITRATE -gt 1024000 ] then FULL=2 echo ... setting lowres ON, 1/4 resolution elif [ $WIDTH -gt $MAX_WIDTH -o $BITRATE -gt 650000 ] then FULL=1 echo ... setting lowres ON, 1/2 resolution else FULL=0 FAST="" echo ... setting lowres OFF fi fi fi