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

Unified Diff: src/gpu/vk/GrVkTexture.h

Issue 1974983002: Refactor Vulkan image, texture, RTs so that create and getter handles match. (Closed) Base URL: https://skia.googlesource.com/skia.git@fixLayerVersion
Patch Set: clean up Created 4 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: src/gpu/vk/GrVkTexture.h
diff --git a/src/gpu/vk/GrVkTexture.h b/src/gpu/vk/GrVkTexture.h
index c8fb917347bfaa246472cd144bc954d9a8ed0fa6..77245971ff4a9aa2ae805b06cdffb5da7131ba64 100644
--- a/src/gpu/vk/GrVkTexture.h
+++ b/src/gpu/vk/GrVkTexture.h
@@ -14,7 +14,7 @@
class GrVkGpu;
class GrVkImageView;
-struct GrVkTextureInfo;
+struct GrVkImageInfo;
class GrVkTexture : public GrTexture, public virtual GrVkImage {
public:
@@ -22,8 +22,7 @@ public:
const GrVkImage::ImageDesc&);
static GrVkTexture* CreateWrappedTexture(GrVkGpu*, const GrSurfaceDesc&,
- GrWrapOwnership,
- VkFormat, const GrVkTextureInfo*);
+ GrWrapOwnership, const GrVkImageInfo*);
~GrVkTexture() override;
@@ -36,12 +35,12 @@ public:
bool reallocForMipmap(const GrVkGpu* gpu, uint32_t mipLevels);
protected:
- GrVkTexture(GrVkGpu*, const GrSurfaceDesc&,
- const GrVkImage::Resource*, const GrVkImageView* imageView);
+ GrVkTexture(GrVkGpu*, const GrSurfaceDesc&, const GrVkImageInfo&, const GrVkImageView*,
+ bool isBorrowed);
template<typename ResourceType>
- static GrVkTexture* Create(GrVkGpu*, ResourceType, const GrSurfaceDesc&, VkFormat,
- const GrVkImage::Resource* texImpl);
+ static GrVkTexture* Create(GrVkGpu*, ResourceType, const GrSurfaceDesc&, const GrVkImageInfo&,
+ bool isBorrowed);
GrVkGpu* getVkGpu() const;
@@ -51,9 +50,9 @@ protected:
private:
enum Wrapped { kWrapped };
GrVkTexture(GrVkGpu*, SkBudgeted, const GrSurfaceDesc&,
- const GrVkImage::Resource*, const GrVkImageView* imageView);
+ const GrVkImageInfo&, const GrVkImageView* imageView, bool /*isBorrowed*/);
GrVkTexture(GrVkGpu*, Wrapped, const GrSurfaceDesc&,
- const GrVkImage::Resource*, const GrVkImageView* imageView);
+ const GrVkImageInfo&, const GrVkImageView* imageView, bool isBorrowed);
const GrVkImageView* fTextureView;

Powered by Google App Engine
This is Rietveld 408576698