Lumiera  0.pre.03
»edit your freedom«
EngineService Class Reference

#include "steam/engine/engine-service.hpp"

Description

A service to schedule series of calculations, delivering the rendered data into an external output sink in a timely fashion.

Actually the CalculationStream instances provided through this (facade) interface are backed by jobs executed through the scheduler in the vault layer. The implementation of this service is responsible for creating the right job entries in the correct order and to enqueue these into the scheduler.

Definition at line 102 of file engine-service.hpp.

Public Types

typedef lib::polyvalue::CloneValueSupport< Quality_Clonable_QoS_Strategy
 
typedef lib::PolymorphicValue< Quality, QoS_IMPL_SIZE, _Clonable_QoS_StrategyQoS_Definition
 

Public Member Functions

CalcStreams calculate (ModelPort mPort, Timings nominalTimings, OutputConnection &output, Quality serviceQuality=QoS_DEFAULT)
 core operation: activate the Lumiera Render Engine. More...
 
CalcStreams calculateBackground (ModelPort mPort, Timings nominalTimings, Quality serviceQuality=QoS_BACKGROUND)
 

Static Public Attributes

static lib::Depend< EngineServiceinstance
 access point to the Engine Interface. More...
 
static QoS_Definition QoS_BACKGROUND = QoS_Definition::build<DefaultQoS> (BACKGROUND)
 
static QoS_Definition QoS_COMPROMISE = QoS_Definition::build<Compromise> (PLAYBACK)
 
static QoS_Definition QoS_DEFAULT = QoS_Definition::build<DefaultQoS> (PLAYBACK)
 
static QoS_Definition QoS_PERFECT_RESULT = QoS_Definition::build<DefaultQoS> (RENDER)
 
static QoS_Definition QoS_SYNC_PRIORITY = QoS_Definition::build<PriorityQoS>()
 

Classes

class  Quality
 Quality-of-Service definition for an Render Engine usage. More...
 

Friends

class EngineDiagnostics
 

Protected Member Functions

void activateTracing ()
 Switch the complete engine into diagnostics mode. More...
 
virtual RenderEnvironmentconfigureCalculation (ModelPort, Timings, Quality)
 
void disableTracing ()
 EX_FREE.
 

Private Types

enum  { QoS_IMPL_SIZE = sizeof(size_t) }
 

Static Private Member Functions

static CalcStream activateCalculation (play::DataSink, RenderEnvironment &)
 

Additional Inherited Members

- Private Member Functions inherited from NonCopyable
 NonCopyable (NonCopyable const &)=delete
 
NonCopyableoperator= (NonCopyable const &)=delete
 

Member Function Documentation

◆ calculate()

CalcStreams calculate ( ModelPort  mPort,
Timings  nominalTimings,
OutputConnection output,
Quality  serviceQuality = QoS_DEFAULT 
)

core operation: activate the Lumiera Render Engine.

Invoking this service effectively hooks up each channel of the given model exit point to deliver into the corresponding output sink on the given OutputConnection (which is assumed to be already allocated for active use by this connection). The generated calculation streams represent actively ongoing calculations within the engine, started right away, according to the given timing constraints and service quality.

Definition at line 80 of file engine-service.cpp.

References EngineService::activateCalculation(), and EngineService::configureCalculation().

+ Here is the call graph for this function:

◆ configureCalculation()

RenderEnvironment & configureCalculation ( ModelPort  mPort,
Timings  nominalTimings,
Quality  serviceQuality 
)
protectedvirtual

extension point Create the environment for rendering a connected and related set of output streams. Configure and prepare all the internal components, pre-allocate resources and add entries to the registration tables necessary to get the related render activities into "running" state. The created setup will typically be used to generate all the individual channel streams linked together for playback or rendering; they all share the same media type and quality settings.

Returns
an abstracted representation of the specific setup for this render; from this point on, this RenderEnvironment closure will be the only way for client code to talk to "the engine". The actual instance of this closure is just a handle and can be copied; any CalcStream created off this closure will be linked to the same "environment" and be tracked and managed for resource usage automatically.
Note
variations and especially mock implementations of the render engine might choose to configure internals differently. As long as the CalcStream and the embedded RenderEnvironment are consistent, such a specific configuration remains opaque for the user of the created render activity

Reimplemented in EngineServiceMock.

Definition at line 148 of file engine-service.cpp.

Referenced by EngineService::calculate().

+ Here is the caller graph for this function:

◆ activateTracing()

void activateTracing ( )
protected

Switch the complete engine into diagnostics mode.

This activates additional logging and reporting facilities, allowing to verify some specific operations within the engine did indeed happen. Activating this mode incurs a performance hit.

Definition at line 169 of file engine-service.cpp.

◆ activateCalculation()

CalcStream activateCalculation ( play::DataSink  sink,
RenderEnvironment engineCallback 
)
staticprivate

build a representation of a single, ongoing calculation effort. This "CalcStream" is tied to the actual engine implementation, but only through an opaque link, representing this concrete engine as an engine::RenderEnvironment closure. This enables the created CalcStream to be re-configured and adjusted while running.

Definition at line 119 of file engine-service.cpp.

Referenced by EngineService::calculate().

+ Here is the caller graph for this function:

Member Data Documentation

◆ instance

lib::Depend< EngineService > instance
static

access point to the Engine Interface.

storage for the EngineService interface object

this is an facade interface for internal use by the player. Client code should use the Player.

Definition at line 143 of file engine-service.hpp.

Referenced by LumieraRenderProcessBuilder::buildCalculationStreams().

+ Inheritance diagram for EngineService:
+ Collaboration diagram for EngineService:

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