OrcaSlicer latest
OrcaSlicer
Loading...
Searching...
No Matches
ObjColorUtils.cpp File Reference
#include "ObjColorUtils.hpp"
#include <vector>
#include "Color.hpp"
Include dependency graph for ObjColorUtils.cpp:

Go to the source code of this file.

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: