Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Region_Iterator_Iterator.cpp
Go to the documentation of this file.
1// Copyright 2019 Google LLC.
2// Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.
4// HASH=a2db43ee3cbf6893e9b23927fb44298a
5REG_FIDDLE(Region_Iterator_Iterator, 256, 256, true, 0) {
6void draw(SkCanvas* canvas) {
8 SkRegion region;
9 region.setRect({1, 2, 3, 4});
10 iter.reset(region);
11 auto r = iter.rect();
12 SkDebugf("rect={%d,%d,%d,%d}\n", r.fLeft, r.fTop, r.fRight, r.fBottom);
13}
14} // END FIDDLE
void SK_SPI SkDebugf(const char format[],...) SK_PRINTF_LIKE(1
static void draw(SkCanvas *canvas, SkRect &target, int x, int y)
Definition aaclip.cpp:27
const SkIRect & rect() const
Definition SkRegion.h:501
void reset(const SkRegion &region)
bool setRect(const SkIRect &rect)
Definition SkRegion.cpp:192
#define REG_FIDDLE(NAME, W, H, TEXT, I)
Definition examples.h:60