Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(211)

Side by Side Diff: tools/gpu/GrTest.cpp

Issue 2111423002: Fix caching of sample locations (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Some chrome bots don't have map::emplace. Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « tests/GpuSampleLocationsTest.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2013 Google Inc. 2 * Copyright 2013 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "GrTest.h" 8 #include "GrTest.h"
9 9
10 #include "GrBatchAtlas.h" 10 #include "GrBatchAtlas.h"
(...skipping 276 matching lines...) Expand 10 before | Expand all | Expand 10 after
287 287
288 bool onGetWritePixelsInfo(GrSurface* dstSurface, int width, int height, 288 bool onGetWritePixelsInfo(GrSurface* dstSurface, int width, int height,
289 GrPixelConfig srcConfig, DrawPreference*, 289 GrPixelConfig srcConfig, DrawPreference*,
290 WritePixelTempDrawInfo*) override { return false; } 290 WritePixelTempDrawInfo*) override { return false; }
291 291
292 bool onCopySurface(GrSurface* dst, 292 bool onCopySurface(GrSurface* dst,
293 GrSurface* src, 293 GrSurface* src,
294 const SkIRect& srcRect, 294 const SkIRect& srcRect,
295 const SkIPoint& dstPoint) override { return false; }; 295 const SkIPoint& dstPoint) override { return false; };
296 296
297 void onGetMultisampleSpecs(GrRenderTarget* rt, 297 void onGetMultisampleSpecs(GrRenderTarget* rt, const GrStencilSettings&,
298 const GrStencilSettings&, 298 int* effectiveSampleCnt, SamplePattern*) override {
299 int* effectiveSampleCnt,
300 SkAutoTDeleteArray<SkPoint>*) override {
301 *effectiveSampleCnt = rt->desc().fSampleCnt; 299 *effectiveSampleCnt = rt->desc().fSampleCnt;
302 } 300 }
303 301
304 bool initCopySurfaceDstDesc(const GrSurface* src, GrSurfaceDesc* desc) const override { 302 bool initCopySurfaceDstDesc(const GrSurface* src, GrSurfaceDesc* desc) const override {
305 return false; 303 return false;
306 } 304 }
307 305
308 GrGpuCommandBuffer* createCommandBuffer(GrRenderTarget* target, 306 GrGpuCommandBuffer* createCommandBuffer(GrRenderTarget* target,
309 const GrGpuCommandBuffer::LoadAndSto reInfo&, 307 const GrGpuCommandBuffer::LoadAndSto reInfo&,
310 const GrGpuCommandBuffer::LoadAndSto reInfo&) override { 308 const GrGpuCommandBuffer::LoadAndSto reInfo&) override {
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
398 SkASSERT(nullptr == fGpu); 396 SkASSERT(nullptr == fGpu);
399 fGpu = new MockGpu(this, options); 397 fGpu = new MockGpu(this, options);
400 SkASSERT(fGpu); 398 SkASSERT(fGpu);
401 this->initCommon(options); 399 this->initCommon(options);
402 400
403 // We delete these because we want to test the cache starting with zero reso urces. Also, none of 401 // We delete these because we want to test the cache starting with zero reso urces. Also, none of
404 // these objects are required for any of tests that use this context. TODO: make stop allocating 402 // these objects are required for any of tests that use this context. TODO: make stop allocating
405 // resources in the buffer pools. 403 // resources in the buffer pools.
406 fDrawingManager->abandon(); 404 fDrawingManager->abandon();
407 } 405 }
OLDNEW
« no previous file with comments | « tests/GpuSampleLocationsTest.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698