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

Side by Side Diff: src/gpu/vk/GrVkTexture.cpp

Issue 1842753002: Style bikeshed - remove extraneous whitespace (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 | « src/gpu/vk/GrVkTexture.h ('k') | src/gpu/vk/GrVkTextureRenderTarget.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 "GrVkTexture.h" 8 #include "GrVkTexture.h"
9 #include "GrVkGpu.h" 9 #include "GrVkGpu.h"
10 #include "GrVkImageView.h" 10 #include "GrVkImageView.h"
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 69
70 GrVkTexture* texture = Create(gpu, desc, lifeCycle, imageDesc.fFormat, image Resource); 70 GrVkTexture* texture = Create(gpu, desc, lifeCycle, imageDesc.fFormat, image Resource);
71 // Create() will increment the refCount of the image resource if it succeeds 71 // Create() will increment the refCount of the image resource if it succeeds
72 imageResource->unref(gpu); 72 imageResource->unref(gpu);
73 73
74 return texture; 74 return texture;
75 } 75 }
76 76
77 GrVkTexture* GrVkTexture::CreateWrappedTexture(GrVkGpu* gpu, const GrSurfaceDesc & desc, 77 GrVkTexture* GrVkTexture::CreateWrappedTexture(GrVkGpu* gpu, const GrSurfaceDesc & desc,
78 GrGpuResource::LifeCycle lifeCycl e, 78 GrGpuResource::LifeCycle lifeCycl e,
79 VkFormat format, 79 VkFormat format,
80 const GrVkTextureInfo* info) { 80 const GrVkTextureInfo* info) {
81 SkASSERT(info); 81 SkASSERT(info);
82 // Wrapped textures require both image and allocation (because they can be m apped) 82 // Wrapped textures require both image and allocation (because they can be m apped)
83 SkASSERT(VK_NULL_HANDLE != info->fImage && VK_NULL_HANDLE != info->fAlloc); 83 SkASSERT(VK_NULL_HANDLE != info->fImage && VK_NULL_HANDLE != info->fAlloc);
84 84
85 GrVkImage::Resource::Flags flags = (VK_IMAGE_TILING_LINEAR == info->fImageTi ling) 85 GrVkImage::Resource::Flags flags = (VK_IMAGE_TILING_LINEAR == info->fImageTi ling)
86 ? Resource::kLinearTiling_Flag : Resource:: kNo_Flags; 86 ? Resource::kLinearTiling_Flag : Resource:: kNo_Flags;
87 87
88 const GrVkImage::Resource* imageResource; 88 const GrVkImage::Resource* imageResource;
89 if (kBorrowed_LifeCycle == lifeCycle) { 89 if (kBorrowed_LifeCycle == lifeCycle) {
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
138 138
139 GrBackendObject GrVkTexture::getTextureHandle() const { 139 GrBackendObject GrVkTexture::getTextureHandle() const {
140 // Currently just passing back the pointer to the Resource as the handle 140 // Currently just passing back the pointer to the Resource as the handle
141 return (GrBackendObject)&fResource; 141 return (GrBackendObject)&fResource;
142 } 142 }
143 143
144 GrVkGpu* GrVkTexture::getVkGpu() const { 144 GrVkGpu* GrVkTexture::getVkGpu() const {
145 SkASSERT(!this->wasDestroyed()); 145 SkASSERT(!this->wasDestroyed());
146 return static_cast<GrVkGpu*>(this->getGpu()); 146 return static_cast<GrVkGpu*>(this->getGpu());
147 } 147 }
148
OLDNEW
« no previous file with comments | « src/gpu/vk/GrVkTexture.h ('k') | src/gpu/vk/GrVkTextureRenderTarget.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698