Lines Matching refs:dContext
34 static bool check_rect(GrDirectContext* dContext, GrSurfaceDrawContext* rtc, const SkIRect& rect, in check_rect() argument
45 if (!rtc->readPixels(dContext, readback, {rect.fLeft, rect.fTop})) { in check_rect()
69 static void clear_op_test(skiatest::Reporter* reporter, GrDirectContext* dContext) { in clear_op_test() argument
100 rtContext = newRTC(dContext, kW, kH); in clear_op_test()
105 if (!check_rect(dContext, rtContext.get(), fullRect, kColor1, &actualValue, &failX, &failY)) { in clear_op_test()
110 rtContext = newRTC(dContext, kW, kH); in clear_op_test()
116 if (!check_rect(dContext, rtContext.get(), fullRect, kColor1, &actualValue, &failX, &failY)) { in clear_op_test()
121 rtContext = newRTC(dContext, kW, kH); in clear_op_test()
127 if (!check_rect(dContext, rtContext.get(), fullRect, kColor2, &actualValue, &failX, &failY)) { in clear_op_test()
132 rtContext = newRTC(dContext, kW, kH); in clear_op_test()
138 if (!check_rect(dContext, rtContext.get(), fullRect, kColor1, &actualValue, &failX, &failY)) { in clear_op_test()
143 rtContext = newRTC(dContext, kW, kH); in clear_op_test()
149 if (!check_rect(dContext, rtContext.get(), fullRect, kColor1, &actualValue, &failX, &failY)) { in clear_op_test()
154 rtContext = newRTC(dContext, kW, kH); in clear_op_test()
160 if (!check_rect(dContext, rtContext.get(), mid1Rect, kColor2, &actualValue, &failX, &failY)) { in clear_op_test()
165 dContext, rtContext.get(), outerLeftEdge, kColor1, &actualValue, &failX, &failY) || in clear_op_test()
167 dContext, rtContext.get(), outerTopEdge, kColor1, &actualValue, &failX, &failY) || in clear_op_test()
169 dContext, rtContext.get(), outerRightEdge, kColor1, &actualValue, &failX, &failY) || in clear_op_test()
171 dContext, rtContext.get(), outerBottomEdge, kColor1, &actualValue, &failX, &failY)) { in clear_op_test()
176 rtContext = newRTC(dContext, kW, kH); in clear_op_test()
182 if (!check_rect(dContext, rtContext.get(), fullRect, kColor1, &actualValue, &failX, &failY)) { in clear_op_test()
187 rtContext = newRTC(dContext, kW, kH); in clear_op_test()
195 if (!check_rect(dContext, rtContext.get(), mid2Rect, kColor1, &actualValue, &failX, &failY)) { in clear_op_test()
200 dContext, rtContext.get(), innerLeftEdge, kColor2, &actualValue, &failX, &failY) || in clear_op_test()
202 dContext, rtContext.get(), innerTopEdge, kColor2, &actualValue, &failX, &failY) || in clear_op_test()
204 dContext, rtContext.get(), innerRightEdge, kColor2, &actualValue, &failX, &failY) || in clear_op_test()
206 dContext, rtContext.get(), innerBottomEdge, kColor2, &actualValue, &failX, &failY)) { in clear_op_test()
211 dContext, rtContext.get(), outerLeftEdge, kColor1, &actualValue, &failX, &failY) || in clear_op_test()
213 dContext, rtContext.get(), outerTopEdge, kColor1, &actualValue, &failX, &failY) || in clear_op_test()
215 dContext, rtContext.get(), outerRightEdge, kColor1, &actualValue, &failX, &failY) || in clear_op_test()
217 dContext, rtContext.get(), outerBottomEdge, kColor1, &actualValue, &failX, &failY)) { in clear_op_test()
222 rtContext = newRTC(dContext, kW, kH); in clear_op_test()
229 if (!check_rect(dContext, rtContext.get(), mid1Rect, kColor2, &actualValue, &failX, &failY)) { in clear_op_test()
234 dContext, rtContext.get(), outerLeftEdge, kColor1, &actualValue, &failX, &failY) || in clear_op_test()
236 dContext, rtContext.get(), outerTopEdge, kColor1, &actualValue, &failX, &failY) || in clear_op_test()
238 dContext, rtContext.get(), outerRightEdge, kColor1, &actualValue, &failX, &failY) || in clear_op_test()
240 dContext, rtContext.get(), outerBottomEdge, kColor1, &actualValue, &failX, &failY)) { in clear_op_test()
246 if (!dContext->priv().caps()->performColorClearsAsDraws() && in clear_op_test()
247 !dContext->priv().caps()->performStencilClearsAsDraws() && in clear_op_test()
248 !dContext->priv().caps()->performPartialClearsAsDraws()) { in clear_op_test()
254 rtContext = newRTC(dContext, kW, kH); in clear_op_test()
273 dContext->flushAndSubmit(); in clear_op_test()
279 rtContext = newRTC(dContext, kW, kH); in clear_op_test()
299 dContext->flushAndSubmit(); in clear_op_test()