|
- #pragma once
-
- #include <ecs/config.h>
-
- beg_namespace_ecs_core_parallelism
- {
-
- template<typename T_parameters>
- struct fixed_threshold
- {
- using parameters_type = T_parameters;
- using strategy_lower_type = typename parameters_type::strategy_lower_type;
- using strategy_greater_type = typename parameters_type::strategy_greater_type;
-
- strategy_lower_type _strategy_lower;
- strategy_greater_type _strategy_greater;
-
- template<typename T_instance, typename... T_args>
- inline void operator()(T_instance& instance, T_args&&... args) const
- {
- bool threshold_reached = false; // TODO
- if (!threshold_reached)
- {
- _strategy_lower(instance, std::forward<T_args>(args)...);
- }
- else
- {
- _strategy_greater(instance, std::forward<T_args>(args)...);
- }
- }
- };
-
- }
- end_namespace_ecs_core_parallelism
|