TinyVG / specification

The specification for TinyVG. This is the central authority for the file system
https://tinyvg.tech/
MIT License
239 stars 6 forks source link

Did you consider UTF8 instead of VarUInt #1

Closed marler8997 closed 2 years ago

marler8997 commented 2 years ago

I'm reading the specification and was curious if you considered using UTF8 rather than a custom integer encoding? If so, what are your thoughts? If not, do you think using UTF8 might be a good alternative?

ikskuh commented 2 years ago

UTF-8 has a not-as-tight encoding, but allows detection of in-stream data.

This makes sense for text, but not for a fixed binary format where you cannot decipher if you're in the file or at the beginning. The current encoding is more compact, as it doesn't require this feature.

marler8997 commented 2 years ago

Ah yes that's true. Thanks for your thoughts.