Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

grf.txt description #14

Closed
dzavalishin opened this issue Sep 19, 2021 · 1 comment · Fixed by #20
Closed

grf.txt description #14

dzavalishin opened this issue Sep 19, 2021 · 1 comment · Fixed by #20

Comments

@dzavalishin
Copy link

In 'compression' part:

If the high bit is not set, what follows is code&0x7f bytes of
verbatim data.

Code:

int len = (code == 0) ? 0x80 : code;

I suppose this case must be documented too?

@glx22
Copy link
Contributor

glx22 commented Sep 19, 2021

grfcodec/src/sprites.cpp

Lines 152 to 153 in 045774d

if (code == 0)
skip = 128;
seems to be a better reference, but indeed it looks like 0 is a special undocumented case.

glx22 added a commit to glx22/grfcodec that referenced this issue Apr 30, 2023
glx22 added a commit to glx22/grfcodec that referenced this issue Apr 30, 2023
@glx22 glx22 closed this as completed in #20 Apr 30, 2023
glx22 added a commit that referenced this issue Apr 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants