Flutter Engine
The Flutter Engine
vulkan_native_surface_android.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_VULKAN_VULKAN_NATIVE_SURFACE_ANDROID_H_
6#define FLUTTER_VULKAN_VULKAN_NATIVE_SURFACE_ANDROID_H_
7
8#include "flutter/fml/macros.h"
10
11struct ANativeWindow;
13
14namespace vulkan {
15
17 public:
18 /// Create a native surface from the valid ANativeWindow reference. Ownership
19 /// of the ANativeWindow is assumed by this instance.
20 explicit VulkanNativeSurfaceAndroid(ANativeWindow* native_window);
21
23
24 const char* GetExtensionName() const override;
25
26 VkSurfaceKHR CreateSurfaceHandle(
28 const VulkanHandle<VkInstance>& instance) const override;
29
30 bool IsValid() const override;
31
32 SkISize GetSize() const override;
33
34 private:
35 ANativeWindow* native_window_;
36
37 FML_DISALLOW_COPY_AND_ASSIGN(VulkanNativeSurfaceAndroid);
38};
39
40} // namespace vulkan
41
42#endif // FLUTTER_VULKAN_VULKAN_NATIVE_SURFACE_ANDROID_H_
VulkanNativeSurfaceAndroid(ANativeWindow *native_window)
VkSurfaceKHR CreateSurfaceHandle(VulkanProcTable &vk, const VulkanHandle< VkInstance > &instance) const override
const char * GetExtensionName() const override
VkInstance instance
Definition: main.cc:48
vk
Definition: malisc.py:42
Definition: SkSize.h:16
struct ANativeWindow ANativeWindow