use SkColorInfo in fm
Just refactoring code that predates SkColorInfo. Change-Id: Iba5ffdf91e2e2517bf55ea8c5a36c4fe6583a6b3 Reviewed-on: https://skia-review.googlesource.com/c/skia/+/376760 Reviewed-by: Mike Klein <mtklein@google.com> Commit-Queue: Mike Klein <mtklein@google.com>
This commit is contained in:
parent
a654faaf7f
commit
6706c9fa14
@ -543,7 +543,7 @@ int main(int argc, char** argv) {
|
|||||||
|
|
||||||
sk_sp<SkColorSpace> cs = FLAGS_legacy ? nullptr
|
sk_sp<SkColorSpace> cs = FLAGS_legacy ? nullptr
|
||||||
: SkColorSpace::MakeRGB(tf,gamut);
|
: SkColorSpace::MakeRGB(tf,gamut);
|
||||||
const SkImageInfo unsized_info = SkImageInfo::Make(0,0, ct,at,cs);
|
const SkColorInfo color_info{ct,at,cs};
|
||||||
|
|
||||||
AutoreleasePool pool;
|
AutoreleasePool pool;
|
||||||
for (auto source : sources) {
|
for (auto source : sources) {
|
||||||
@ -551,7 +551,7 @@ int main(int argc, char** argv) {
|
|||||||
fprintf(stdout, "%50s", source.name.c_str());
|
fprintf(stdout, "%50s", source.name.c_str());
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
|
|
||||||
const SkImageInfo info = unsized_info.makeDimensions(source.size);
|
const SkImageInfo info = SkImageInfo::Make(source.size, color_info);
|
||||||
|
|
||||||
auto draw = [&source](SkCanvas* canvas) {
|
auto draw = [&source](SkCanvas* canvas) {
|
||||||
Result result = source.draw(canvas);
|
Result result = source.draw(canvas);
|
||||||
|
Loading…
Reference in New Issue
Block a user