fix bitrate setting and add bitrate validation
Merge pull request #850 from ruil2/enc_bitrate_setting_v10

fix bitrate setting and add bitrate validation