Lines Matching refs:surface

51     auto surface = SkSurface::MakeRasterN32Premul(1, 1);
52 surface->getCanvas()->drawColor(SK_ColorBLUE, SkBlendMode::kSrcOver);
53 ASSERT_EQ(TestUtils::getColor(surface, 0, 0), SK_ColorBLUE);
54 pipeline->renderFrame(layerUpdateQueue, dirty, renderNodes, opaque, contentDrawBounds, surface);
55 ASSERT_EQ(TestUtils::getColor(surface, 0, 0), SK_ColorRED);
72 auto surface = SkSurface::MakeRasterN32Premul(2, 2);
73 surface->getCanvas()->drawColor(SK_ColorBLUE, SkBlendMode::kSrcOver);
74 ASSERT_EQ(TestUtils::getColor(surface, 0, 0), SK_ColorBLUE);
75 pipeline->renderFrame(layerUpdateQueue, dirty, renderNodes, true, contentDrawBounds, surface);
76 ASSERT_EQ(TestUtils::getColor(surface, 0, 0), SK_ColorBLUE);
77 ASSERT_EQ(TestUtils::getColor(surface, 0, 1), SK_ColorGREEN);
78 pipeline->renderFrame(layerUpdateQueue, dirty, renderNodes, false, contentDrawBounds, surface);
79 ASSERT_EQ(TestUtils::getColor(surface, 0, 0), (unsigned int)SK_ColorTRANSPARENT);
80 ASSERT_EQ(TestUtils::getColor(surface, 0, 1), SK_ColorGREEN);
94 auto surface = SkSurface::MakeRasterN32Premul(2, 2);
95 surface->getCanvas()->drawColor(SK_ColorBLUE, SkBlendMode::kSrcOver);
96 ASSERT_EQ(TestUtils::getColor(surface, 0, 0), SK_ColorBLUE);
97 pipeline->renderFrame(layerUpdateQueue, dirty, renderNodes, true, contentDrawBounds, surface);
98 ASSERT_EQ(TestUtils::getColor(surface, 0, 0), SK_ColorBLUE);
99 ASSERT_EQ(TestUtils::getColor(surface, 1, 0), SK_ColorBLUE);
100 ASSERT_EQ(TestUtils::getColor(surface, 0, 1), SK_ColorRED);
101 ASSERT_EQ(TestUtils::getColor(surface, 1, 1), SK_ColorRED);
162 auto surface = SkSurface::MakeRasterN32Premul(1, 1);
165 surface->getCanvas()->drawColor(SK_ColorBLUE, SkBlendMode::kSrcOver);
166 ASSERT_EQ(TestUtils::getColor(surface, 0, 0), SK_ColorBLUE);
169 pipeline->renderFrame(layerUpdateQueue, dirty, renderNodes, opaque, contentDrawBounds, surface);
170 ASSERT_EQ(TestUtils::getColor(surface, 0, 0), SK_ColorWHITE);
174 pipeline->renderFrame(layerUpdateQueue, dirty, renderNodes, opaque, contentDrawBounds, surface);
175 ASSERT_EQ(TestUtils::getColor(surface, 0, 0), (unsigned) 0xffd0d0ff);
179 pipeline->renderFrame(layerUpdateQueue, dirty, renderNodes, opaque, contentDrawBounds, surface);
180 ASSERT_EQ(TestUtils::getColor(surface, 0, 0), (unsigned) 0xffd0ffd0);
184 pipeline->renderFrame(layerUpdateQueue, dirty, renderNodes, opaque, contentDrawBounds, surface);
185 ASSERT_EQ(TestUtils::getColor(surface, 0, 0), (unsigned) 0xffffc0c0);
189 pipeline->renderFrame(layerUpdateQueue, dirty, renderNodes, opaque, contentDrawBounds, surface);
190 ASSERT_EQ(TestUtils::getColor(surface, 0, 0), (unsigned) 0xffff8080);
194 pipeline->renderFrame(layerUpdateQueue, dirty, renderNodes, opaque, contentDrawBounds, surface);
195 ASSERT_EQ(TestUtils::getColor(surface, 0, 0), (unsigned) 0xffff8080);
280 sk_sp<DeferLayer<DeferTestCanvas>> surface(new DeferLayer<DeferTestCanvas>());
281 pipeline->renderFrame(layerUpdateQueue, dirty, nodes, true, contentDrawBounds, surface);
282 EXPECT_EQ(4, surface->canvas()->mDrawCounter);
310 sk_sp<DeferLayer<ClippedTestCanvas>> surface(new DeferLayer<ClippedTestCanvas>());
312 SkRect::MakeWH(CANVAS_WIDTH, CANVAS_HEIGHT), surface);
313 EXPECT_EQ(1, surface->canvas()->mDrawCounter);
341 sk_sp<DeferLayer<ClipReplaceTestCanvas>> surface(new DeferLayer<ClipReplaceTestCanvas>());
343 SkRect::MakeWH(CANVAS_WIDTH, CANVAS_HEIGHT), surface);
344 EXPECT_EQ(1, surface->canvas()->mDrawCounter);