mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-09-10 02:37:04 +00:00
ENH: add module flush vol predictor
jira:NONE Signed-off-by: xun.zhang <xun.zhang@bambulab.com> Change-Id: Ie1b0d4c443df4a26ff1b010e73d589162a0fbff7 (cherry picked from commit 475e9b34ff85cf6058ac639fde4b73264e350195)
This commit is contained in:
22
src/libslic3r/FlushVolPredictor.hpp
Normal file
22
src/libslic3r/FlushVolPredictor.hpp
Normal file
@@ -0,0 +1,22 @@
|
||||
#ifndef FLUSH_VOL_PREDICTOR_HPP
|
||||
#define FLUSH_VOL_PREDICTOR_HPP
|
||||
|
||||
#include<unordered_map>
|
||||
|
||||
class FlushVolPredictor
|
||||
{
|
||||
public:
|
||||
bool predict(const unsigned char src_r, const unsigned char src_g, const unsigned char src_b,
|
||||
const unsigned char dst_r, const unsigned char dst_g, const unsigned char dst_b, float& flush);
|
||||
static FlushVolPredictor& get_instance();
|
||||
private:
|
||||
FlushVolPredictor(const std::string& data_file);
|
||||
FlushVolPredictor(const FlushVolPredictor&) = delete;
|
||||
FlushVolPredictor& operator=(const FlushVolPredictor&) = delete;
|
||||
~FlushVolPredictor() = default;
|
||||
private:
|
||||
std::unordered_map<uint64_t, float> m_flush_map;
|
||||
bool m_valid;
|
||||
};
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user