Beatmup
Beatmup::Android::Context Class Reference

Android context. More...

#include <context.h>

Inheritance diagram for Beatmup::Android::Context:
Beatmup::Context Beatmup::Object

Public Member Functions

 Context (JNIEnv *jenv, const Beatmup::PoolIndex numThreadPools)
 
 ~Context ()
 
- Public Member Functions inherited from Beatmup::Context
 Context ()
 
 Context (const PoolIndex numThreadPools)
 
 ~Context ()
 
float performTask (AbstractTask &task, const PoolIndex pool=DEFAULT_POOL)
 Performs a given task. More...
 
void repeatTask (AbstractTask &task, bool abortCurrent, const PoolIndex pool=DEFAULT_POOL)
 Ensures a given task executed at least once. More...
 
Job submitTask (AbstractTask &task, const PoolIndex pool=DEFAULT_POOL)
 Adds a new task to the jobs queue. More...
 
Job submitPersistentTask (AbstractTask &task, const PoolIndex pool=DEFAULT_POOL)
 Adds a new persistent task to the jobs queue. More...
 
void waitForJob (Job job, const PoolIndex pool=DEFAULT_POOL)
 Waits until a given job finishes. More...
 
bool abortJob (Job job, const PoolIndex pool=DEFAULT_POOL)
 Aborts a given submitted job. More...
 
void wait (const PoolIndex pool=DEFAULT_POOL)
 Blocks until all the submitted jobs are executed. More...
 
bool busy (const PoolIndex pool=DEFAULT_POOL)
 Queries whether a given thread pool is busy with a task. More...
 
void check (const PoolIndex pool=DEFAULT_POOL)
 Checks if a specific thread pool is doing great: rethrows exceptions occurred during tasks execution, if any. More...
 
const ThreadIndex maxAllowedWorkerCount (const PoolIndex pool=DEFAULT_POOL) const
 
void limitWorkerCount (ThreadIndex maxValue, const PoolIndex pool=DEFAULT_POOL)
 Limits maximum number of threads (workers) when performing tasks in a given pool. More...
 
void setEventListener (EventListener *eventListener)
 Installs new event listener. More...
 
EventListenergetEventListener () const
 Returns current event listener (or NULL) More...
 
bool isGpuQueried () const
 
bool isGpuReady () const
 
void warmUpGpu ()
 Initializes GPU within a given Context if not yet (takes no effect if it already is). More...
 
bool queryGpuInfo (std::string &vendor, std::string &renderer)
 Initializes the GPU if not yet and queries information about it. More...
 
bool isManagingThread () const
 
GL::RecycleBingetGpuRecycleBin () const
 
bool operator== (const Context &context) const
 Context comparaison operator Two different instances of contexts are basically never identical; returning true only if the two point to the same instance. More...
 
- Public Member Functions inherited from Beatmup::Object
virtual ~Object ()
 

Additional Inherited Members

- Static Public Attributes inherited from Beatmup::Context
static const PoolIndex DEFAULT_POOL = 0
 

Detailed Description

Android context.

Definition at line 32 of file context.h.

Constructor & Destructor Documentation

◆ Context()

Android::Context::Context ( JNIEnv *  jenv,
const Beatmup::PoolIndex  numThreadPools 
)

Definition at line 24 of file context.cpp.

24  :
25  Beatmup::Context(numThreadPools)
26 {}
Basic class: task and memory management, any kind of static data.
Definition: context.h:59

◆ ~Context()

Android::Context::~Context ( )

Definition at line 29 of file context.cpp.

29  {
30 }

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