|
Grok 20.3.2
|
An abstract class that can execute T1 phase of codec by running a tf::Executor. More...
#include <CodecScheduler.h>
Public Member Functions | |
| CodecScheduler (uint16_t numComps) | |
| Contructs a CodecScheduler. | |
| virtual | ~CodecScheduler () |
| Destroys a CodecScheduler. | |
| virtual bool | scheduleT1 (ITileProcessor *proc)=0 |
| Schedules all T1 tasks for a ITileProcessor. | |
| void | run (void) |
| Runs tf::Executor. | |
| bool | wait (void) |
| Waits for tf::Executor to complete. | |
| virtual void | release (void)=0 |
| Releases Taskflow resources. | |
| Public Member Functions inherited from FlowComponent | |
| void | addTo (tf::Taskflow &composition) |
| Composes this FlowComponent's tf::Taskflow with another tf::Taskflow. | |
| void | precede (FlowComponent &successor) |
| Schedule this FlowComponent before another FlowComponent. | |
| void | precede (tf::Task &successor) |
| Schedule this Taskflow before another FlowComponent. | |
| tf::Task & | getCompositionTask (void) |
| void | conditional_precede (FlowComponent *root, FlowComponent *successor, std::function< int()> condition_lambda) |
| Conditionally schedule successor based on condition_lambda. | |
| FlowComponent * | name (const std::string &name) |
| Gets name of composition task. | |
| tf::Task & | nextTask () |
| Gets next task placeholder for componentFlow_. | |
Protected Member Functions | |
| void | releaseCoders (void) |
Protected Attributes | |
| std::atomic_bool | success_ |
| atomic tracking of compress/decompress success | |
| uint16_t | numcomps_ |
| number of components | |
| std::vector< t1::ICoder * > | coders_ |
| pool of ICoder | |
| tf::Future< void > | runFuture_ |
| tf::Future<void> resulting from running scheduler | |
An abstract class that can execute T1 phase of codec by running a tf::Executor.
This class is derived from FlowComponent, and acts as the root tf::Taskflow. Scheduling of tasks for this root is implemented in derived classes.
|
explicit |
Contructs a CodecScheduler.
| numComps | number of image components |
References numcomps_, and success_.
Referenced by grk::SchedulerExcalibur::SchedulerExcalibur(), and grk::SchedulerStandard::SchedulerStandard().
|
virtual |
Destroys a CodecScheduler.
References releaseCoders().
|
pure virtual |
Releases Taskflow resources.
Implemented in grk::DecompressScheduler, grk::DecompressSchedulerExcalibur, and grk::SchedulerStandard.
|
protected |
References coders_.
Referenced by ~CodecScheduler().
| void grk::CodecScheduler::run | ( | void | ) |
Runs tf::Executor.
References TFSingleton::get(), and runFuture_.
|
pure virtual |
Schedules all T1 tasks for a ITileProcessor.
| proc | ITileProcessor |
Implemented in grk::CompressScheduler, grk::DecompressScheduler, and grk::DecompressSchedulerExcalibur.
| bool grk::CodecScheduler::wait | ( | void | ) |
Waits for tf::Executor to complete.
References runFuture_, and success_.
|
protected |
pool of ICoder
Referenced by grk::CompressScheduler::compress(), grk::CompressScheduler::populateT1Flow(), releaseCoders(), and grk::CompressScheduler::scheduleT1().
|
protected |
number of components
Referenced by CodecScheduler(), grk::CompressScheduler::CompressScheduler(), grk::CompressSchedulerExcalibur::CompressSchedulerExcalibur(), grk::SchedulerStandard::getImageComponentFlow(), grk::SchedulerStandard::graph(), grk::SchedulerStandard::release(), grk::SchedulerStandard::SchedulerStandard(), grk::DecompressScheduler::scheduleT1(), grk::DecompressSchedulerExcalibur::scheduleT1(), and grk::DecompressScheduler::~DecompressScheduler().
|
protected |
|
protected |
atomic tracking of compress/decompress success
Referenced by CodecScheduler(), grk::DecompressScheduler::scheduleT1(), grk::DecompressSchedulerExcalibur::scheduleT1(), and wait().