chromium/services/device/generic_sensor/platform_sensor_util.cc

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

#include "services/device/generic_sensor/platform_sensor_util.h"

#include <cmath>

#include "base/notreached.h"
#include "base/ranges/algorithm.h"
#include "services/device/public/cpp/generic_sensor/sensor_reading.h"

namespace device {

namespace {

// Check that each rounding multiple is positive number.
static_assert;

static_assert;

static_assert;

static_assert;

static_assert;

static_assert;

// Check that threshold value is at least half of rounding multiple.
static_assert;

template <typename T>
T square(T x) {}

}  // namespace

double RoundToMultiple(double value, double multiple) {}

void RoundAccelerometerReading(SensorReadingXYZ* reading) {}

void RoundGyroscopeReading(SensorReadingXYZ* reading) {}

void RoundIlluminanceReading(SensorReadingSingle* reading) {}

void RoundOrientationQuaternionReading(SensorReadingQuat* reading) {}

void RoundOrientationEulerReading(SensorReadingXYZ* reading) {}

void RoundMagnetometerReading(SensorReadingXYZ* reading) {}

void RoundSensorReading(SensorReading* reading, mojom::SensorType sensor_type) {}

}  // namespace device