#include <software_surface_producer.h>
Definition at line 19 of file software_surface_producer.h.
◆ SoftwareSurfaceProducer()
flutter_runner::SoftwareSurfaceProducer::SoftwareSurfaceProducer |
( |
| ) |
|
|
explicit |
Definition at line 50 of file software_surface_producer.cc.
50 {
51 zx_status_t status = fdio_service_connect(
52 "/svc/fuchsia.sysmem.Allocator",
53 sysmem_allocator_.NewRequest().TakeChannel().release());
57
58 status = fdio_service_connect(
59 "/svc/fuchsia.ui.composition.Allocator",
60 flatland_allocator_.NewRequest().TakeChannel().release());
62
63 valid_ = true;
64}
#define FML_DCHECK(condition)
static zx_koid_t GetCurrentProcessId()
static std::string GetCurrentProcessName()
◆ ~SoftwareSurfaceProducer()
flutter_runner::SoftwareSurfaceProducer::~SoftwareSurfaceProducer |
( |
| ) |
|
|
overridedefault |
◆ gr_context()
GrDirectContext * flutter_runner::SoftwareSurfaceProducer::gr_context |
( |
| ) |
const |
|
inlineoverridevirtual |
◆ IsValid()
bool flutter_runner::SoftwareSurfaceProducer::IsValid |
( |
| ) |
const |
|
inline |
◆ ProduceOffscreenSurface()
Implements flutter_runner::SurfaceProducer.
Definition at line 69 of file software_surface_producer.cc.
69 {
71
72 return CreateSurface(
size);
73}
#define FML_CHECK(condition)
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
◆ ProduceSurface()
Implements flutter_runner::SurfaceProducer.
Definition at line 75 of file software_surface_producer.cc.
76 {
77 TRACE_EVENT2(
"flutter",
"SoftwareSurfacePool::ProduceSurface",
"width",
78 size.width(),
"height",
size.height());
80
81 std::unique_ptr<SurfaceProducerSurface>
surface;
82 auto exact_match_it =
83 std::find_if(available_surfaces_.begin(), available_surfaces_.end(),
85 return surface->IsValid() && surface->GetSize() == size;
86 });
87 if (exact_match_it != available_surfaces_.end()) {
89 surface = std::move(*exact_match_it);
90 available_surfaces_.erase(exact_match_it);
91 } else {
93 }
94
97 return nullptr;
98 }
99
100 if (!
surface->FlushSessionAcquireAndReleaseEvents()) {
101 FML_LOG(
ERROR) <<
"Could not flush acquire/release events for buffer.";
102 return nullptr;
103 }
104
106}
#define FML_LOG(severity)
#define TRACE_EVENT2(category_group, name, arg1_name, arg1_val, arg2_name, arg2_val)
#define TRACE_EVENT_INSTANT0(category_group, name)
◆ SubmitSurfaces()
void flutter_runner::SoftwareSurfaceProducer::SubmitSurfaces |
( |
std::vector< std::unique_ptr< SurfaceProducerSurface > > |
surfaces | ) |
|
|
overridevirtual |
◆ kMaxSurfaceAge
constexpr int flutter_runner::SoftwareSurfaceProducer::kMaxSurfaceAge = 3 |
|
staticconstexpr |
◆ kMaxSurfaces
constexpr int flutter_runner::SoftwareSurfaceProducer::kMaxSurfaces = 12 |
|
staticconstexpr |
The documentation for this class was generated from the following files: