5#ifndef FLUTTER_IMPELLER_ENTITY_CONTENTS_GRADIENT_GENERATOR_H_
6#define FLUTTER_IMPELLER_ENTITY_CONTENTS_GRADIENT_GENERATOR_H_
11#include "flutter/impeller/core/texture.h"
25 const GradientData& gradient_data,
26 const std::shared_ptr<impeller::Context>& context);
35static_assert(
sizeof(
StopData) == 32);
45 const std::vector<Scalar>& stops);
PODArray< SkColor > colors
std::vector< StopData > CreateGradientColors(const std::vector< Color > &colors, const std::vector< Scalar > &stops)
Populate a vector with the color and stop data for a gradient.
std::shared_ptr< Texture > CreateGradientTexture(const GradientData &gradient_data, const std::shared_ptr< impeller::Context > &context)
Create a host visible texture that contains the gradient defined by the provided gradient data.