#include "ui/color/dynamic_color/palette_factory.h"
#include <array>
#include <memory>
#include <utility>
#include <vector>
#include "base/containers/flat_map.h"
#include "base/containers/span.h"
#include "third_party/material_color_utilities/src/cpp/cam/hct.h"
#include "third_party/material_color_utilities/src/cpp/palettes/core.h"
#include "third_party/material_color_utilities/src/cpp/palettes/tones.h"
#include "ui/color/color_provider_manager.h"
#include "ui/color/dynamic_color/palette.h"
namespace ui {
namespace {
Hct;
SchemeVariant;
double GetRotatedHue(double source_hue,
const base::flat_map<double, double>& hues_to_rotations) { … }
double GetAdjustedChroma(
double source_hue,
const base::flat_map<double, double>& hues_to_chromas) { … }
class CustomPalette : public Palette { … };
struct Transform { … };
Transform Chroma(double chroma) { … }
struct Config { … };
TonalPalette MakePalette(double hue, const Transform& transform) { … }
std::unique_ptr<Palette> FromConfig(SkColor seed_color, const Config& config) { … }
template <class S, class T, size_t N>
base::flat_map<S, T> Zip(const std::array<S, N>& keys,
const std::array<T, N>& values) { … }
}
std::unique_ptr<Palette> GeneratePalette(SkColor seed_color,
SchemeVariant variant) { … }
}