| Index: src/gpu/vk/GrVkProgramDesc.h
|
| diff --git a/src/gpu/gl/GrGLProgramDesc.h b/src/gpu/vk/GrVkProgramDesc.h
|
| similarity index 78%
|
| copy from src/gpu/gl/GrGLProgramDesc.h
|
| copy to src/gpu/vk/GrVkProgramDesc.h
|
| index 0ebf6a228ec8906260e431d5ad89629ffcbbbdfb..1767a051babb70e22e401b8adadf3b19b5615c73 100644
|
| --- a/src/gpu/gl/GrGLProgramDesc.h
|
| +++ b/src/gpu/vk/GrVkProgramDesc.h
|
| @@ -1,30 +1,34 @@
|
| /*
|
| - * Copyright 2013 Google Inc.
|
| + * Copyright 2015 Google Inc.
|
| *
|
| * Use of this source code is governed by a BSD-style license that can be
|
| * found in the LICENSE file.
|
| */
|
|
|
| -#ifndef GrGLProgramDesc_DEFINED
|
| -#define GrGLProgramDesc_DEFINED
|
| +#ifndef GrVkProgramDesc_DEFINED
|
| +#define GrVkProgramDesc_DEFINED
|
|
|
| #include "GrColor.h"
|
| #include "GrProgramDesc.h"
|
| #include "GrGpu.h"
|
| #include "GrTypesPriv.h"
|
|
|
| -class GrGLGpu;
|
| -class GrGLProgramDescBuilder;
|
| +#include "shaderc/shaderc.h"
|
| +#include "vulkan/vulkan.h"
|
|
|
| -class GrGLProgramDesc : public GrProgramDesc {
|
| - friend class GrGLProgramDescBuilder;
|
| +class GrVkGpu;
|
| +class GrVkProgramDescBuilder;
|
| +
|
| +class GrVkProgramDesc : public GrProgramDesc {
|
| +private:
|
| + friend class GrVkProgramDescBuilder;
|
| };
|
|
|
| /**
|
| * This class can be used to build a GrProgramDesc. It also provides helpers for accessing
|
| * GL specific info in the header.
|
| */
|
| -class GrGLProgramDescBuilder {
|
| +class GrVkProgramDescBuilder {
|
| public:
|
| typedef GrProgramDesc::KeyHeader KeyHeader;
|
| // The key, stored in fKey, is composed of five parts(first 2 are defined in the key itself):
|
| @@ -35,7 +39,7 @@ public:
|
| // Each processor's key is a variable length array of uint32_t.
|
| enum {
|
| // Part 3.
|
| - kHeaderOffset = GrGLProgramDesc::kHeaderOffset,
|
| + kHeaderOffset = GrVkProgramDesc::kHeaderOffset,
|
| kHeaderSize = SkAlign4(sizeof(KeyHeader)),
|
| // Part 4.
|
| // This is the offset into the backenend specific part of the key, which includes
|
| @@ -52,7 +56,8 @@ public:
|
| * general draw information, as well as the specific color, geometry,
|
| * and coverage stages which will be used to generate the GL Program for
|
| * this optstate.
|
| - * @param GrGLSLCaps Capabilities of the GLSL backend.
|
| + * @param GrVkGpu A GL Gpu, the caps and Gpu object are used to output processor specific
|
| + * parts of the descriptor.
|
| * @param GrProgramDesc The built and finalized descriptor
|
| **/
|
| static bool Build(GrProgramDesc*,
|
|
|