mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 05:17:35 +00:00
LibGfx/JPEGXL: Support clusters with a single distribution
This type of cluster is an exception and has specific rules (but simpler) to be read. This is a requirement to support complex distributions as they use a symbol decoder initialized with a single distribution.
This commit is contained in:
parent
a8857c06b3
commit
18c511f54c
1 changed files with 6 additions and 2 deletions
|
@ -1201,8 +1201,12 @@ private:
|
||||||
ErrorOr<void> read_pre_clustered_distributions(LittleEndianInputBitStream& stream, u8 num_distrib)
|
ErrorOr<void> read_pre_clustered_distributions(LittleEndianInputBitStream& stream, u8 num_distrib)
|
||||||
{
|
{
|
||||||
// C.2.2 Distribution clustering
|
// C.2.2 Distribution clustering
|
||||||
if (num_distrib == 1)
|
if (num_distrib == 1) {
|
||||||
TODO();
|
// If num_dist == 1, then num_clusters = 1 and clusters[0] = 0, and the remainder of this subclause is skipped.
|
||||||
|
m_clusters = { 0 };
|
||||||
|
TRY(m_configs.try_resize(1));
|
||||||
|
return {};
|
||||||
|
};
|
||||||
|
|
||||||
TRY(m_clusters.try_resize(num_distrib));
|
TRY(m_clusters.try_resize(num_distrib));
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue