mirror of
https://github.com/infrost/RaptorQR.git
synced 2026-09-01 07:28:02 +08:00
c93eda9156
parityCount: Math.ceil → Math.floor - Small files (G ≤ 33) now truly get 0 parity generations - Large files (G ≥ 34) still get proportional parity (≈3%) - Previously Math.ceil always gave ≥1 parity for any G ≥ 1 neededPackets: K * sourceGenerations → K * totalGenerations - Aligns with the round-robin scheduler: symbols are interleaved across ALL generations, so practical minimum is K × totalGens - Fixes the mismatch where 'needed' showed 32 but actual decode required ~48 frames (for 2 source + 1 parity case) Tests: Updated assembly test comments and totalGenerations params to match new parityCount behavior. Closes the long-standing 'needed frames count is off because of outer error correction' issue.