I am using below command in php for converting all videos to flv. It's working proper but quality is bad after conversion. I want to retain quality after conversion.
$wide=$file['video']['resolution_x'];
$tall=$file['video']['resolution_y'];
exec("ffmpeg -i test.anyformate -ar 22050 -ab 32 -f flv -s ".$wide."x".$tall." flvideo/$vid.flv");