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

Side by Side Diff: tools/vulkan/viewer/GMSlide.cpp

Issue 1873733003: More cleanup in the Vulkan viewer (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Address comments 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 | « tools/vulkan/viewer/GMSlide.h ('k') | tools/vulkan/viewer/SKPSlide.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 2016 Google Inc. 2 * Copyright 2016 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 * Copyright 2014 Google Inc. 8 * Copyright 2014 Google Inc.
9 * 9 *
10 * Use of this source code is governed by a BSD-style license that can be 10 * Use of this source code is governed by a BSD-style license that can be
11 * found in the LICENSE file. 11 * found in the LICENSE file.
12 */ 12 */
13 13
14 #include "GMSlide.h" 14 #include "GMSlide.h"
15 #include "SkCanvas.h" 15 #include "SkCanvas.h"
16 16
17 GMSlide::GMSlide(skiagm::GM* gm) : fGM(gm) { 17 GMSlide::GMSlide(skiagm::GM* gm) : fGM(gm) {
18 fName.printf("GM_%s", gm->getName()); 18 fName.printf("GM_%s", gm->getName());
19 } 19 }
20 20
21 GMSlide::~GMSlide() { delete fGM; } 21 GMSlide::~GMSlide() { delete fGM; }
22 22
23 void GMSlide::draw(SkCanvas* canvas) { 23 void GMSlide::draw(SkCanvas* canvas) {
24 // Do we care about timing the draw of the background (once)? 24 // Do we care about timing the draw of the background (once)?
25 // Does the GM ever rely on drawBackground to lazily compute something? 25 // Does the GM ever rely on drawBackground to lazily compute something?
26 fGM->drawBackground(canvas); 26 fGM->drawBackground(canvas);
27 fGM->drawContent(canvas); 27 fGM->drawContent(canvas);
28 } 28 }
29
30 bool GMSlide::animate(const SkAnimTimer& timer) {
31 return fGM->animate(timer);
32 }
OLDNEW
« no previous file with comments | « tools/vulkan/viewer/GMSlide.h ('k') | tools/vulkan/viewer/SKPSlide.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698