#include "video/stream_synchronization.h"
#include <stdlib.h>
#include <algorithm>
#include "rtc_base/logging.h"
namespace webrtc {
static const int kMaxChangeMs = …;
static const int kMaxDeltaDelayMs = …;
static const int kFilterLength = …;
static const int kMinDeltaMs = …;
StreamSynchronization::StreamSynchronization(uint32_t video_stream_id,
uint32_t audio_stream_id)
: … { … }
bool StreamSynchronization::ComputeRelativeDelay(
const Measurements& audio_measurement,
const Measurements& video_measurement,
int* relative_delay_ms) { … }
bool StreamSynchronization::ComputeDelays(int relative_delay_ms,
int current_audio_delay_ms,
int* total_audio_delay_target_ms,
int* total_video_delay_target_ms) { … }
void StreamSynchronization::SetTargetBufferingDelay(int target_delay_ms) { … }
void StreamSynchronization::ReduceAudioDelay() { … }
void StreamSynchronization::ReduceVideoDelay() { … }
}