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

Side by Side Diff: src/gpu/GrBatchAtlas.cpp

Issue 1831133004: Revert of Consolidate GPU buffer implementations (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 8 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 | « include/gpu/GrTypesPriv.h ('k') | src/gpu/GrBatchFlushState.h » ('j') | 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 2015 Google Inc. 2 * Copyright 2015 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 "GrBatchAtlas.h" 8 #include "GrBatchAtlas.h"
9 #include "GrBatchFlushState.h" 9 #include "GrBatchFlushState.h"
10 #include "GrRectanizer.h" 10 #include "GrRectanizer.h"
11 #include "GrTracing.h" 11 #include "GrTracing.h"
12 #include "GrVertexBuffer.h"
12 13
13 //////////////////////////////////////////////////////////////////////////////// 14 ////////////////////////////////////////////////////////////////////////////////
14 15
15 GrBatchAtlas::BatchPlot::BatchPlot(int index, uint64_t genID, int offX, int offY , int width, 16 GrBatchAtlas::BatchPlot::BatchPlot(int index, uint64_t genID, int offX, int offY , int width,
16 int height, GrPixelConfig config) 17 int height, GrPixelConfig config)
17 : fLastUpload(0) 18 : fLastUpload(0)
18 , fLastUse(0) 19 , fLastUse(0)
19 , fIndex(index) 20 , fIndex(index)
20 , fGenID(genID) 21 , fGenID(genID)
21 , fID(CreateId(fIndex, fGenID)) 22 , fID(CreateId(fIndex, fGenID))
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after
254 // Note that this plot will be uploaded inline with the draws whereas the 255 // Note that this plot will be uploaded inline with the draws whereas the
255 // one it displaced most likely was uploaded asap. 256 // one it displaced most likely was uploaded asap.
256 newPlot->setLastUploadToken(batchTarget->currentToken()); 257 newPlot->setLastUploadToken(batchTarget->currentToken());
257 SkAutoTUnref<GrPlotUploader> uploader(new GrPlotUploader(newPlot, fTexture)) ; 258 SkAutoTUnref<GrPlotUploader> uploader(new GrPlotUploader(newPlot, fTexture)) ;
258 batchTarget->upload(uploader); 259 batchTarget->upload(uploader);
259 *id = newPlot->id(); 260 *id = newPlot->id();
260 261
261 fAtlasGeneration++; 262 fAtlasGeneration++;
262 return true; 263 return true;
263 } 264 }
OLDNEW
« no previous file with comments | « include/gpu/GrTypesPriv.h ('k') | src/gpu/GrBatchFlushState.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698