| OLD | NEW | 
|    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 #include "VulkanViewer.h" |    8 #include "VulkanViewer.h" | 
|    9  |    9  | 
|   10 #include "GMSlide.h" |   10 #include "GMSlide.h" | 
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|   64  |   64  | 
|   65     SkDebugf("Command line arguments: "); |   65     SkDebugf("Command line arguments: "); | 
|   66     for (int i = 1; i < argc; ++i) { |   66     for (int i = 1; i < argc; ++i) { | 
|   67         SkDebugf("%s ", argv[i]); |   67         SkDebugf("%s ", argv[i]); | 
|   68     } |   68     } | 
|   69     SkDebugf("\n"); |   69     SkDebugf("\n"); | 
|   70  |   70  | 
|   71     SkCommandLineFlags::Parse(argc, argv); |   71     SkCommandLineFlags::Parse(argc, argv); | 
|   72  |   72  | 
|   73     fWindow = Window::CreateNativeWindow(platformData); |   73     fWindow = Window::CreateNativeWindow(platformData); | 
|   74     fWindow->attach(Window::kVulkan_BackendType, 0, nullptr); |   74     fWindow->attach(Window::kVulkan_BackendType, 0); | 
|   75  |   75  | 
|   76     // register callbacks |   76     // register callbacks | 
|   77     fWindow->registerKeyFunc(on_key_handler, this); |   77     fWindow->registerKeyFunc(on_key_handler, this); | 
|   78     fWindow->registerCharFunc(on_char_handler, this); |   78     fWindow->registerCharFunc(on_char_handler, this); | 
|   79     fWindow->registerPaintFunc(on_paint_handler, this); |   79     fWindow->registerPaintFunc(on_paint_handler, this); | 
|   80  |   80  | 
|   81     // set up slides |   81     // set up slides | 
|   82     this->initSlides(); |   82     this->initSlides(); | 
|   83  |   83  | 
|   84     fAnimTimer.run(); |   84     fAnimTimer.run(); | 
| (...skipping 250 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  335     // Record measurements |  335     // Record measurements | 
|  336     fMeasurements[fCurrentMeasurement++] = ms; |  336     fMeasurements[fCurrentMeasurement++] = ms; | 
|  337     fCurrentMeasurement &= (kMeasurementCount - 1);  // fast mod |  337     fCurrentMeasurement &= (kMeasurementCount - 1);  // fast mod | 
|  338     SkASSERT(fCurrentMeasurement < kMeasurementCount); |  338     SkASSERT(fCurrentMeasurement < kMeasurementCount); | 
|  339  |  339  | 
|  340     fAnimTimer.updateTime(); |  340     fAnimTimer.updateTime(); | 
|  341     if (fSlides[fCurrentSlide]->animate(fAnimTimer) || fDisplayStats) { |  341     if (fSlides[fCurrentSlide]->animate(fAnimTimer) || fDisplayStats) { | 
|  342         fWindow->inval(); |  342         fWindow->inval(); | 
|  343     } |  343     } | 
|  344 } |  344 } | 
| OLD | NEW |