Flutter Engine
The Flutter Engine
Draw.h
Go to the documentation of this file.
1/*
2 * Copyright 2023 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 Draw_DEFINED
9#define Draw_DEFINED
10
11#include "gm/gm.h"
14
15#include <string>
16
17// Holds the result of the draw() function.
18struct GMOutput {
20 std::string msg;
22
24 std::string msg = "",
27};
28
29// Draws a GM on a surface.
30//
31// To make the Bazel build more modular, multiple implementations of this function exist. Each
32// implementation lives in a separate .cpp files that is conditionally included based on the
33// //gm/vias:via Bazel config flag.
34GMOutput draw(skiagm::GM* gm, SkSurface* surface, std::string via);
35
36#endif // Draw_DEFINED
GMOutput draw(skiagm::GM *gm, SkSurface *surface, std::string via)
Definition: SimpleVias.cpp:182
Definition: gm.h:110
VkSurfaceKHR surface
Definition: main.cc:49
Definition: bitmap.py:1
DrawResult
Definition: gm.h:104
Definition: Draw.h:18
GMOutput(skiagm::GM::DrawResult result=skiagm::DrawResult::kFail, std::string msg="", SkBitmap bitmap=SkBitmap())
Definition: Draw.h:23
std::string msg
Definition: Draw.h:20
SkBitmap bitmap
Definition: Draw.h:21
skiagm::GM::DrawResult result
Definition: Draw.h:19