Flutter Engine
 
Loading...
Searching...
No Matches
impeller::testing::TestReactorGLES Class Reference
Inheritance diagram for impeller::testing::TestReactorGLES:
impeller::ReactorGLES impeller::ReactorGLES

Public Member Functions

 TestReactorGLES ()
 
 ~TestReactorGLES ()=default
 
 TestReactorGLES ()
 
 ~TestReactorGLES ()=default
 
- Public Member Functions inherited from impeller::ReactorGLES
 ReactorGLES (std::unique_ptr< ProcTableGLES > gl)
 Create a new reactor. There are expensive and only one per application instance is necessary.
 
 ~ReactorGLES ()
 Destroy a reactor.
 
bool IsValid () const
 If this is a valid reactor. Invalid reactors must be discarded immediately.
 
WorkerID AddWorker (std::weak_ptr< Worker > worker)
 Adds a worker to the reactor. Each new worker must ensure that the context it manages is the same as the other workers in the reactor or in the same sharegroup.
 
bool RemoveWorker (WorkerID id)
 Remove a previously added worker from the reactor. If the reactor has no workers, pending added operations will never run.
 
const ProcTableGLESGetProcTable () const
 Get the OpenGL proc. table the reactor uses to manage handles.
 
std::optional< GLuint > GetGLHandle (const HandleGLES &handle) const
 Returns the OpenGL handle for a reactor handle if one is available. This is typically only safe to call within a reaction. That is, within a ReactorGLES::Operation.
 
std::optional< GLsync > GetGLFence (const HandleGLES &handle) const
 
HandleGLES CreateHandle (HandleType type, GLuint external_handle=GL_NONE)
 Create a reactor handle.
 
HandleGLES CreateUntrackedHandle (HandleType type) const
 Create a handle that is not managed by ReactorGLES.
 
void CollectHandle (HandleGLES handle)
 Collect a reactor handle.
 
void SetDebugLabel (const HandleGLES &handle, std::string_view label)
 Set the debug label on a reactor handle.
 
bool CanSetDebugLabels () const
 Whether the device is capable of writing debug labels.
 
bool AddOperation (Operation operation, bool defer=false)
 Adds an operation that the reactor runs on a worker that ensures that an OpenGL context is current.
 
bool RegisterCleanupCallback (const HandleGLES &handle, const fml::closure &callback)
 Register a cleanup callback that will be invokved with the provided user data when the handle is destroyed.
 
bool React ()
 Perform a reaction on the current thread if able.
 

Additional Inherited Members

- Public Types inherited from impeller::ReactorGLES
using WorkerID = UniqueID
 
using Operation = std::function< void(const ReactorGLES &reactor)>
 

Detailed Description

Definition at line 18 of file blit_command_gles_unittests.cc.

Constructor & Destructor Documentation

◆ TestReactorGLES() [1/2]

impeller::testing::TestReactorGLES::TestReactorGLES ( )
inline

Definition at line 20 of file blit_command_gles_unittests.cc.

21 : ReactorGLES(std::make_unique<ProcTableGLES>(kMockResolverGLES)) {}
ReactorGLES(std::unique_ptr< ProcTableGLES > gl)
Create a new reactor. There are expensive and only one per application instance is necessary.
const ProcTableGLES::Resolver kMockResolverGLES
Definition mock_gles.cc:287

◆ ~TestReactorGLES() [1/2]

impeller::testing::TestReactorGLES::~TestReactorGLES ( )
default

◆ TestReactorGLES() [2/2]

impeller::testing::TestReactorGLES::TestReactorGLES ( )
inline

Definition at line 33 of file render_pass_gles_unittests.cc.

34 : ReactorGLES(std::make_unique<ProcTableGLES>(kMockResolverGLES)) {}

◆ ~TestReactorGLES() [2/2]

impeller::testing::TestReactorGLES::~TestReactorGLES ( )
default

The documentation for this class was generated from the following files: