#include "../transcoder/basisu.h"
#include "basisu_frontend.h"
#include "basisu_opencl.h"
#include <unordered_set>
#include <unordered_map>
#if BASISU_SUPPORT_SSE
#define CPPSPMD_NAME …
#include "basisu_kernels_declares.h"
#endif
#define BASISU_FRONTEND_VERIFY(c) …
namespace basisu
{
const uint32_t cMaxCodebookCreationThreads = …;
const uint32_t BASISU_MAX_ENDPOINT_REFINEMENT_STEPS = …;
const uint32_t BASISU_ENDPOINT_PARENT_CODEBOOK_SIZE = …;
const uint32_t BASISU_SELECTOR_PARENT_CODEBOOK_SIZE_COMP_LEVEL_01 = …;
const uint32_t BASISU_SELECTOR_PARENT_CODEBOOK_SIZE_COMP_LEVEL_DEFAULT = …;
static inline void handle_verify_failure(int line)
{ … }
bool basisu_frontend::init(const params &p)
{ … }
bool basisu_frontend::compress()
{ … }
bool basisu_frontend::init_global_codebooks()
{ … }
void basisu_frontend::introduce_special_selector_clusters()
{ … }
void basisu_frontend::optimize_selector_codebook()
{ … }
void basisu_frontend::init_etc1_images()
{ … }
void basisu_frontend::init_endpoint_training_vectors()
{ … }
void basisu_frontend::generate_endpoint_clusters()
{ … }
void basisu_frontend::generate_block_endpoint_clusters()
{ … }
void basisu_frontend::compute_endpoint_clusters_within_each_parent_cluster()
{ … }
void basisu_frontend::compute_endpoint_subblock_error_vec()
{ … }
void basisu_frontend::introduce_new_endpoint_clusters()
{ … }
struct color_rgba_hasher
{ … };
void basisu_frontend::generate_endpoint_codebook(uint32_t step)
{ … }
bool basisu_frontend::check_etc1s_constraints() const
{ … }
uint32_t basisu_frontend::refine_endpoint_clusterization()
{ … }
void basisu_frontend::eliminate_redundant_or_empty_endpoint_clusters()
{ … }
void basisu_frontend::create_initial_packed_texture()
{ … }
void basisu_frontend::compute_selector_clusters_within_each_parent_cluster()
{ … }
void basisu_frontend::generate_selector_clusters()
{ … }
void basisu_frontend::create_optimized_selector_codebook(uint32_t iter)
{ … }
void basisu_frontend::find_optimal_selector_clusters_for_each_block()
{ … }
uint32_t basisu_frontend::refine_block_endpoints_given_selectors()
{ … }
void basisu_frontend::dump_endpoint_clusterization_visualization(const char *pFilename, bool vis_endpoint_colors)
{ … }
void basisu_frontend::finalize()
{ … }
void basisu_frontend::reoptimize_remapped_endpoints(const uint_vec &new_block_endpoints, int_vec &old_to_new_endpoint_cluster_indices, bool optimize_final_codebook, uint_vec *pBlock_selector_indices)
{ … }
bool basisu_frontend::validate_endpoint_cluster_hierarchy(bool ensure_clusters_have_same_parents) const
{ … }
bool basisu_frontend::validate_output() const
{ … }
void basisu_frontend::dump_debug_image(const char *pFilename, uint32_t first_block, uint32_t num_blocks_x, uint32_t num_blocks_y, bool output_blocks)
{ … }
}