| Flutter Impeller |

ahb_formats.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_IMPELLER_RENDERER_BACKEND_VULKAN_SWAPCHAIN_AHB_AHB_FORMATS_H_
6 #define FLUTTER_IMPELLER_RENDERER_BACKEND_VULKAN_SWAPCHAIN_AHB_AHB_FORMATS_H_
7
8 #include "impeller/core/formats.h"
9 #include "impeller/toolkit/android/hardware_buffer.h"
10
11 namespace impeller {
12
13 constexpr PixelFormat ToPixelFormat(android::HardwareBufferFormat format) {
14 switch (format) {
15 case android::HardwareBufferFormat::kR8G8B8A8UNormInt:
16 return PixelFormat::kR8G8B8A8UNormInt;
17 }
18 FML_UNREACHABLE();
19 }
20
21 } // namespace impeller
22
23 #endif // FLUTTER_IMPELLER_RENDERER_BACKEND_VULKAN_SWAPCHAIN_AHB_AHB_FORMATS_H_
formats.h
hardware_buffer.h
impeller::android::HardwareBufferFormat
HardwareBufferFormat
Definition: hardware_buffer.h:18
impeller::android::HardwareBufferFormat::kR8G8B8A8UNormInt
@ kR8G8B8A8UNormInt
impeller
Definition: allocation.cc:12
impeller::ToPixelFormat
constexpr PixelFormat ToPixelFormat(vk::Format format)
Definition: formats_vk.h:183
impeller::PixelFormat
PixelFormat
The Pixel formats supported by Impeller. The naming convention denotes the usage of the component,...
Definition: formats.h:99
impeller::PixelFormat::kR8G8B8A8UNormInt
@ kR8G8B8A8UNormInt