@@ -1226,14 +1226,27 @@ void CameraDevice::InitializeVideoStreams()
12261226
12271227void CameraDevice::InitializeAudioStreams ()
12281228{
1229- // Create single audio stream with typical supported parameters
1230- AudioStream audioStream = { { 1 /* Id */ , StreamUsageEnum::kLiveView /* StreamUsage */ , AudioCodecEnum::kOpus ,
1231- kMicrophoneMaxChannelCount /* ChannelCount(Max from Spec) */ , 48000 /* SampleRate */ ,
1232- 30000 /* BitRate*/ , 24 /* BitDepth */ , 0 /* RefCount */ },
1233- false ,
1234- nullptr };
1235-
1236- mAudioStreams .push_back (audioStream);
1229+ // Mono stream
1230+ AudioStream monoStream = { { 1 /* Id */ , StreamUsageEnum::kLiveView , AudioCodecEnum::kOpus , 1 /* ChannelCount: Mono */ ,
1231+ 48000 /* SampleRate */ , 20000 /* BitRate */ , 24 /* BitDepth */ , 0 /* RefCount */ },
1232+ false ,
1233+ nullptr };
1234+ mAudioStreams .push_back (monoStream);
1235+
1236+ // Stereo stream
1237+ AudioStream stereoStream = { { 2 /* Id */ , StreamUsageEnum::kLiveView , AudioCodecEnum::kOpus , 2 /* ChannelCount: Stereo */ ,
1238+ 48000 /* SampleRate */ , 32000 /* BitRate */ , 24 /* BitDepth */ , 0 /* RefCount */ },
1239+ false ,
1240+ nullptr };
1241+ mAudioStreams .push_back (stereoStream);
1242+
1243+ // Max channel count stream (from spec constant)
1244+ AudioStream maxChannelStream = { { 3 /* Id */ , StreamUsageEnum::kLiveView , AudioCodecEnum::kOpus ,
1245+ kMicrophoneMaxChannelCount /* Max from Spec */ , 48000 /* SampleRate */ , 64000 /* BitRate */ ,
1246+ 24 /* BitDepth */ , 0 /* RefCount */ },
1247+ false ,
1248+ nullptr };
1249+ mAudioStreams .push_back (maxChannelStream);
12371250}
12381251
12391252void CameraDevice::InitializeSnapshotStreams ()
@@ -1266,7 +1279,7 @@ WebRTCTransportProvider::Delegate & CameraDevice::GetWebRTCProviderDelegate()
12661279 return mWebRTCProviderManager ;
12671280}
12681281
1269- PushAvStreamTransportDelegate & CameraDevice::GetPushAVDelegate ()
1282+ PushAvStreamTransportDelegate & CameraDevice::GetPushAVTransportDelegate ()
12701283{
12711284 return mPushAVTransportManager ;
12721285}
0 commit comments