(profile: &str)
| 1103 | } |
| 1104 | |
| 1105 | fn stream_quality_env_for_profile(profile: &str) -> anyhow::Result<StreamQualityEnvironment> { |
| 1106 | match profile { |
| 1107 | "quality" => Ok(StreamQualityEnvironment { |
| 1108 | profile: "quality", |
| 1109 | max_edge: 4096, |
| 1110 | fps: 60, |
| 1111 | min_bitrate: 60_000_000, |
| 1112 | bits_per_pixel: 10, |
| 1113 | }), |
| 1114 | "full" => Ok(StreamQualityEnvironment { |
| 1115 | profile: "full", |
| 1116 | max_edge: 4096, |
| 1117 | fps: 60, |
| 1118 | min_bitrate: 12_000_000, |
| 1119 | bits_per_pixel: 4, |
| 1120 | }), |
| 1121 | "balanced" => Ok(StreamQualityEnvironment { |
| 1122 | profile: "balanced", |
| 1123 | max_edge: 1280, |
| 1124 | fps: 60, |
| 1125 | min_bitrate: 6_000_000, |
| 1126 | bits_per_pixel: 5, |
| 1127 | }), |
| 1128 | "fast" => Ok(StreamQualityEnvironment { |
| 1129 | profile: "fast", |
| 1130 | max_edge: 960, |
| 1131 | fps: 30, |
| 1132 | min_bitrate: 2_500_000, |
| 1133 | bits_per_pixel: 3, |
| 1134 | }), |
| 1135 | "smooth" => Ok(StreamQualityEnvironment { |
| 1136 | profile: "smooth", |
| 1137 | max_edge: 4096, |
| 1138 | fps: 60, |
| 1139 | min_bitrate: 4_000_000, |
| 1140 | bits_per_pixel: 5, |
| 1141 | }), |
| 1142 | "economy" => Ok(StreamQualityEnvironment { |
| 1143 | profile: "economy", |
| 1144 | max_edge: 1080, |
| 1145 | fps: 30, |
| 1146 | min_bitrate: 3_500_000, |
| 1147 | bits_per_pixel: 6, |
| 1148 | }), |
| 1149 | "low" => Ok(StreamQualityEnvironment { |
| 1150 | profile: "low", |
| 1151 | max_edge: 720, |
| 1152 | fps: 30, |
| 1153 | min_bitrate: 2_000_000, |
| 1154 | bits_per_pixel: 5, |
| 1155 | }), |
| 1156 | "tiny" => Ok(StreamQualityEnvironment { |
| 1157 | profile: "tiny", |
| 1158 | max_edge: 540, |
| 1159 | fps: 30, |
| 1160 | min_bitrate: 1_200_000, |
| 1161 | bits_per_pixel: 4, |
| 1162 | }), |
no outgoing calls
no test coverage detected