OrcaSlicer latest
OrcaSlicer
Loading...
Searching...
No Matches
ObjColorUtils.hpp File Reference
#include <cmath>
#include <array>
#include <iostream>
#include <ctime>
#include <opencv2/core/mat.hpp>
#include <opencv2/core/matx.hpp>
#include <opencv2/core.hpp>
#include <vector>
#include <opencv2/imgproc.hpp>
#include "opencv2/opencv.hpp"
#include "libslic3r/Color.hpp"
Include dependency graph for ObjColorUtils.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  QuantKMeans

Functions

bool obj_color_deal_algo (std::vector< Slic3r::RGBA > &input_colors, std::vector< Slic3r::RGBA > &cluster_colors_from_algo, std::vector< int > &cluster_labels_from_algo, char &cluster_number, int max_cluster)

Function Documentation

◆ obj_color_deal_algo()

bool obj_color_deal_algo ( std::vector< Slic3r::RGBA > & input_colors,
std::vector< Slic3r::RGBA > & cluster_colors_from_algo,
std::vector< int > & cluster_labels_from_algo,
char & cluster_number,
int max_cluster )
10{
11 QuantKMeans quant(10);
12 quant.apply(input_colors, cluster_colors_from_algo, cluster_labels_from_algo, (int) cluster_number, max_cluster);
13 if (cluster_number == -1) {
14 return false;
15 }
16 return true;
17}
Definition ObjColorUtils.hpp:15

References QuantKMeans::apply().

Referenced by convert_obj_cluster_colors().

Here is the call graph for this function:
Here is the caller graph for this function: