未验证 提交 110bce4f 编写于 作者: C Chinmay Garde 提交者: GitHub

Use the GPU object constructor to create a gradient shader. (#5136)

Fixes build break introduced in 33aaf6fc.
上级 33aaf6fc
......@@ -100,11 +100,11 @@ void CanvasGradient::initSweep(double center_x,
sk_matrix = ToSkMatrix(matrix4);
}
set_shader(SkGradientShader::MakeSweep(
set_shader(UIDartState::CreateGPUObject(SkGradientShader::MakeSweep(
center_x, center_y, reinterpret_cast<const SkColor*>(colors.data()),
color_stops.data(), colors.num_elements(), tile_mode,
start_angle * 180.0 / M_PI, end_angle * 180.0 / M_PI, 0,
has_matrix ? &sk_matrix : nullptr));
has_matrix ? &sk_matrix : nullptr)));
}
CanvasGradient::CanvasGradient() = default;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册