MCPcopy Create free account
hub / github.com/ARM-software/astc-encoder / prepare_angular_tables

Function prepare_angular_tables

Source/astcenc_weight_align.cpp:72–84  ·  view source on GitHub ↗

See header for documentation. */

Source from the content-addressed store, hash-verified

70
71/* See header for documentation. */
72void prepare_angular_tables()
73{
74 for (unsigned int i = 0; i < ANGULAR_STEPS; i++)
75 {
76 float angle_step = static_cast<float>(i + 1);
77
78 for (unsigned int j = 0; j < SINCOS_STEPS; j++)
79 {
80 sin_table[j][i] = static_cast<float>(sinf((2.0f * astc::PI / (SINCOS_STEPS - 1.0f)) * angle_step * static_cast<float>(j)));
81 cos_table[j][i] = static_cast<float>(cosf((2.0f * astc::PI / (SINCOS_STEPS - 1.0f)) * angle_step * static_cast<float>(j)));
82 }
83 }
84}
85
86/**
87 * @brief Compute the angular alignment factors and offsets.

Callers 1

astcenc_context_allocFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected