1 /*
2  * Copyright 2018 Google Inc.
3  *
4  * Use of this source code is governed by a BSD-style license that can be
5  * found in the LICENSE file.
6  */
7 
8 #ifndef ProxyUtils_DEFINED
9 #define ProxyUtils_DEFINED
10 
11 #include "include/private/GrTypesPriv.h"
12 #include "src/gpu/GrImageInfo.h"
13 #include "src/gpu/GrPipeline.h"
14 #include "src/gpu/GrTextureProxy.h"
15 
16 class GrProgramInfo;
17 
18 namespace sk_gpu_test {
19 
20 /** Makes a texture proxy containing the passed in color data. */
21 sk_sp<GrTextureProxy> MakeTextureProxyFromData(GrContext*,
22                                                GrRenderable,
23                                                GrSurfaceOrigin,
24                                                const GrImageInfo&,
25                                                const void* data,
26                                                size_t rowBytes);
27 
28 GrProgramInfo* CreateProgramInfo(const GrCaps*,
29                                  SkArenaAlloc*,
30                                  const GrSurfaceProxyView* outputView,
31                                  GrAppliedClip&&,
32                                  const GrXferProcessor::DstProxyView&,
33                                  GrGeometryProcessor*,
34                                  SkBlendMode,
35                                  GrPrimitiveType,
36                                  GrPipeline::InputFlags flags = GrPipeline::InputFlags::kNone,
37                                  const GrUserStencilSettings* stencil =
38                                                                 &GrUserStencilSettings::kUnused);
39 
40 
41 }  // namespace sk_gpu_test
42 
43 #endif
44