 |
Flutter Impeller
|
|
Go to the documentation of this file.
5 #ifndef FLUTTER_IMPELLER_RENDERER_BACKEND_GLES_HANDLE_GLES_H_
6 #define FLUTTER_IMPELLER_RENDERER_BACKEND_GLES_HANDLE_GLES_H_
11 #include <type_traits>
13 #include "flutter/fml/hash_combine.h"
38 std::optional<UniqueID>
name;
54 constexpr
bool IsDead()
const {
return !
name.has_value(); }
62 return fml::HashCombine(
63 std::underlying_type_t<decltype(handle.
type)>(handle.
type),
86 return HandleGLES{
type, UniqueID{}};
100 if (handle.
name.has_value()) {
101 out << handle.
name.value().id;
112 #endif // FLUTTER_IMPELLER_RENDERER_BACKEND_GLES_HANDLE_GLES_H_
static HandleGLES DeadHandle()
Creates a dead handle.
std::ostream & operator<<(std::ostream &out, const impeller::Color &c)
std::optional< UniqueID > name
constexpr bool IsDead() const
Determines if the handle is dead.
std::string HandleTypeToString(HandleType type)
bool operator()(const HandleGLES &lhs, const HandleGLES &rhs) const
Represents a handle to an underlying OpenGL object. Unlike OpenGL object handles, these handles can b...
Get the hash value of this handle. Handles can be used as map keys.
A comparer used to test the equality of two handles.
std::size_t operator()(const HandleGLES &handle) const
The reactor attempts to make thread-safe usage of OpenGL ES easier to reason about.
ScopedObject< Object > Create(CtorArgs &&... args)