This is a first step towards the ability to produce several different output formats... Refactor the code to separate - the double buffering - the actual image generation, which works in RGB - the conversion routine Furthermore, replace unsigned char by std::byte and introduce std::array and structured binding to avoid many usages of pointers; hopefully this makes the intention of the code clearer. Verified and cross-checked the actual converion logic; in fact this is a conversion to "YUV" as used by MPEG, which in more precise terms is Y'CrCb with Rec.601 colour space and a scan range limitation (16...235) on the Luma component.
9.5 MiB
9.5 MiB
| The file is too large to be shown. |