Flutter Engine
The Flutter Engine
surface.cc
Go to the documentation of this file.
1// Copyright 2013 The Flutter Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
6
7#include "flutter/fml/logging.h"
8
9namespace impeller {
10
12
13Surface::Surface(const RenderTarget& target_desc) : desc_(target_desc) {
14 if (auto size = desc_.GetColorAttachmentSize(0u); size.has_value()) {
15 size_ = size.value();
16 } else {
17 return;
18 }
19
20 is_valid_ = true;
21}
22
23Surface::~Surface() = default;
24
25const ISize& Surface::GetSize() const {
26 return size_;
27}
28
29bool Surface::IsValid() const {
30 return is_valid_;
31}
32
34 return desc_;
35}
36
37bool Surface::Present() const {
38 return false;
39};
40
41} // namespace impeller
std::optional< ISize > GetColorAttachmentSize(size_t index) const
bool IsValid() const
Definition: surface.cc:29
virtual ~Surface()
const ISize & GetSize() const
Definition: surface.cc:25
virtual bool Present() const
Definition: surface.cc:37
const RenderTarget & GetTargetRenderPassDescriptor() const
Definition: surface.cc:33
it will be possible to load the file into Perfetto s trace viewer disable asset Prevents usage of any non test fonts unless they were explicitly Loaded via prefetched default font Indicates whether the embedding started a prefetch of the default font manager before creating the engine run In non interactive keep the shell running after the Dart script has completed enable serial On low power devices with low core running concurrent GC tasks on threads can cause them to contend with the UI thread which could potentially lead to jank This option turns off all concurrent GC activities domain network JSON encoded network policy per domain This overrides the DisallowInsecureConnections switch Embedder can specify whether to allow or disallow insecure connections at a domain level old gen heap size
Definition: switches.h:259