Flutter Engine
The Flutter Engine
GraphicsPipeline.cpp
Go to the documentation of this file.
1/*
2 * Copyright 2021 Google LLC
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
10
11namespace skgpu::graphite {
12
13GraphicsPipeline::GraphicsPipeline(const SharedContext* sharedContext, PipelineInfo* pipelineInfo)
14 : Resource(sharedContext,
17 /*gpuMemorySize=*/0) {
18#if defined(GRAPHITE_TEST_UTILS)
19 if (pipelineInfo) {
20 fPipelineInfo.fRenderStepID = pipelineInfo->fRenderStepID;
21 fPipelineInfo.fPaintID = pipelineInfo->fPaintID;
22 fPipelineInfo.fSkSLVertexShader =
23 SkShaderUtils::PrettyPrint(pipelineInfo->fSkSLVertexShader);
24 fPipelineInfo.fSkSLFragmentShader =
25 SkShaderUtils::PrettyPrint(pipelineInfo->fSkSLFragmentShader);
26 fPipelineInfo.fNativeVertexShader = std::move(pipelineInfo->fNativeVertexShader);
27 fPipelineInfo.fNativeFragmentShader = std::move(pipelineInfo->fNativeFragmentShader);
28 }
29#endif
30}
31
33
34} // namespace skgpu::graphite
@ kYes
Do pre-clip the geometry before applying the (perspective) matrix.
GraphicsPipeline(const SharedContext *, PipelineInfo *)
std::string PrettyPrint(const std::string &string)
Definition: GpuTools.h:21
Budgeted
Definition: GpuTypes.h:35