chromium/third_party/blink/renderer/platform/media/smoothness_helper.cc

// Copyright 2019 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "third_party/blink/renderer/platform/media/smoothness_helper.h"

#include <optional>

#include "base/functional/bind.h"
#include "base/memory/raw_ptr.h"
#include "base/time/time.h"
#include "base/timer/timer.h"
#include "base/unguessable_token.h"
#include "media/learning/common/learning_task_controller.h"

namespace blink {
namespace {

FeatureVector;
LearningTaskController;
TargetValue;

static constexpr base::TimeDelta kSegmentSize =;

// Maximum distance between NNRs for them to be consecutive.
static constexpr base::TimeDelta kMaxNNRDistance =;

// Max proportion of dropped frames in a window before we call it "not smooth".
static constexpr float kMaxDroppedFramesPerWindow =;

}  // namespace

// Monitor smoothness during a playback, and call back on each window.
class SmoothnessWindowMonitor {};

SmoothnessHelper::SmoothnessHelper(const FeatureVector& features)
    :{}

SmoothnessHelper::~SmoothnessHelper() = default;

class SmoothnessHelperImpl : public SmoothnessHelper {};

// static
std::unique_ptr<SmoothnessHelper> SmoothnessHelper::Create(
    std::unique_ptr<LearningTaskController> bad_controller,
    std::unique_ptr<LearningTaskController> nnr_controller,
    const FeatureVector& features,
    Client* player) {}

// static
base::TimeDelta SmoothnessHelper::SegmentSizeForTesting() {}

}  // namespace blink