# Generate FFMPEG hiqh quality settings based upon version
ffmpeg_generate_hq()
{
	ffmpeg_help=`ffmpeg -h 2>&1`
	test_hq=`echo $ffmpeg_help | grep '\-hq' | wc -l`
	test_4mv=`echo $ffmpeg_help | grep '\-4mv' | wc -l`
	test_mv4=`echo $ffmpeg_help | grep '\-mv4' | wc -l`
	hq="-deinterlace -mbd 1"
	qpel="-qpel"
	[ "$test_4mv" -gt 0 ] && hq="$hq -4mv"
	if [ "$test_mv4" -gt 0 ]; then
		hq="$hq -mv4 1"
		qpel="$qpel 1"
	fi
}
