Flutter Engine
 
Loading...
Searching...
No Matches
ios_surface_noop.h
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
5#ifndef FLUTTER_SHELL_PLATFORM_DARWIN_IOS_IOS_SURFACE_NOOP_H_
6#define FLUTTER_SHELL_PLATFORM_DARWIN_IOS_IOS_SURFACE_NOOP_H_
7
10
11@class CALayer;
12
13namespace flutter {
14
15/// @brief A rendering surface that accepts rendering intent but does not render
16/// anything.
17///
18/// This is useful for running on platforms that need an engine instance and
19/// don't have the required drivers.
20class IOSSurfaceNoop final : public IOSSurface {
21 public:
22 explicit IOSSurfaceNoop(std::shared_ptr<IOSContext> context);
23
24 ~IOSSurfaceNoop() override;
25
26 // |IOSSurface|
27 bool IsValid() const override;
28
29 // |IOSSurface|
30 void UpdateStorageSizeIfNecessary() override;
31
32 // |IOSSurface|
33 std::unique_ptr<Surface> CreateGPUSurface() override;
34
35 private:
36 IOSSurfaceNoop(const IOSSurfaceNoop&) = delete;
37
38 IOSSurfaceNoop& operator=(const IOSSurfaceNoop&) = delete;
39};
40
41} // namespace flutter
42
43#endif // FLUTTER_SHELL_PLATFORM_DARWIN_IOS_IOS_SURFACE_NOOP_H_
A rendering surface that accepts rendering intent but does not render anything.
bool IsValid() const override
std::unique_ptr< Surface > CreateGPUSurface() override
void UpdateStorageSizeIfNecessary() override