Clarisse 5.0 SP8 SDK  5.0.5.8.0
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Classes | Public Member Functions | Static Public Member Functions | List of all members
TextureEvaluatorManager Class Reference

Singleton that manages for TextureEvaluators. More...

Public Member Functions

void add_evaluation (TextureEvaluationConfig &config, const double priority_offset=0.0)
 Adds a batch of evaluators using the config parameters.
 
unsigned int remove_evaluation (const TextureEvaluationConfig &config)
 Kills and removes all the evaluators for the given requester.
 
void remove_all ()
 Kills and removes all evaluators for all requesters.
 
void remove_quality (TextureEvaluationConfig &config, ModuleImageQuality::Level quality)
 Searches for an evaluator belonging to the given requester, with the matching quality, and removes it.
 

Static Public Member Functions

static void initialize (OfApp &of_app)
 Initializes the singleton instance. Does nothing if already initialized.
 
static void destroy ()
 Destroys the singleton instance. Does nothing if already destroyed.
 
static TextureEvaluatorManagerget ()
 Returns the manager singleton instance.
 
static AppBase::EvalFps get_eval_fps ()
 Returns the evaluation FPS value.
 

Detailed Description

Singleton that manages for TextureEvaluators.

The singleton is initialized and destroyed by the GuiApp.
Texture and UV evaluation use the EVAL_FPS_SHADING value.

Member Function Documentation

void TextureEvaluatorManager::add_evaluation ( TextureEvaluationConfig &  config,
const double  priority_offset = 0.0 
)

Adds a batch of evaluators using the config parameters.

Evaluators are prioritized by quality: lowest quality has the higher priority.

If there are existing evaluations for the config's requester, they will be removed before adding the new ones.

Parameters
configThe TextureEvaluationConfig.
priority_offsetOptional priority offset for evaluators.
unsigned int TextureEvaluatorManager::remove_evaluation ( const TextureEvaluationConfig &  config)

Kills and removes all the evaluators for the given requester.

Parameters
configThe TextureEvaluationConfig.
Returns
Number of removed evaluations if any. If the result is greater than 0 it means working or pending evaluations were removed.
void TextureEvaluatorManager::remove_quality ( TextureEvaluationConfig &  config,
ModuleImageQuality::Level  quality 
)

Searches for an evaluator belonging to the given requester, with the matching quality, and removes it.

Parameters
configThe TextureEvaluationConfig.
qualityQuality of the evaluations to remove.

Trying to remove a quality while the list is being modified: potentially because current evaluations are already being removed by remove_evaluation. Do nothing and exit.