if (context->codec_settings.video.bandwidth) {
context->bandwidth = context->codec_settings.video.bandwidth;
} else {
- context->bandwidth = context->codec_settings.video.width * context->codec_settings.video.height / 1024;
+ context->bandwidth = context->codec_settings.video.width * context->codec_settings.video.height / 512;
}
if (context->bandwidth > 5120) {
if (vbw) {
int v = atoi(vbw);
bw = v;
+
+ if (switch_stristr("KB", vbw)) {
+ bw *= 8;
+ } else if (switch_stristr("mb", vbw)) {
+ bw *= 1024;
+ } else if (switch_stristr("MB", vbw)) {
+ bw *= 8192;
+ }
+
}
if (bw > 0) {