summaryrefslogtreecommitdiffstats
path: root/third_party/jpeg-xl/lib/jxl/splines.h
diff options
context:
space:
mode:
Diffstat (limited to 'third_party/jpeg-xl/lib/jxl/splines.h')
-rw-r--r--third_party/jpeg-xl/lib/jxl/splines.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/third_party/jpeg-xl/lib/jxl/splines.h b/third_party/jpeg-xl/lib/jxl/splines.h
index acdd0857d0..af51ec937e 100644
--- a/third_party/jpeg-xl/lib/jxl/splines.h
+++ b/third_party/jpeg-xl/lib/jxl/splines.h
@@ -6,6 +6,7 @@
#ifndef LIB_JXL_SPLINES_H_
#define LIB_JXL_SPLINES_H_
+#include <array>
#include <cmath>
#include <cstddef>
#include <cstdint>
@@ -24,6 +25,8 @@ class BitReader;
static constexpr float kDesiredRenderingDistance = 1.f;
+typedef std::array<float, 32> Dct32;
+
enum SplineEntropyContexts : size_t {
kQuantizationAdjustmentContext = 0,
kStartingPositionContext,
@@ -45,10 +48,10 @@ struct Spline {
};
std::vector<Point> control_points;
// X, Y, B.
- float color_dct[3][32];
+ std::array<Dct32, 3> color_dct;
// Splines are draws by normalized Gaussian splatting. This controls the
// Gaussian's parameter along the spline.
- float sigma_dct[32];
+ Dct32 sigma_dct;
};
class QuantizedSplineEncoder;