mirror of
https://git.mirrors.martin98.com/https://github.com/google/draco
synced 2025-06-04 11:25:44 +08:00
18 lines
326 B
Markdown
18 lines
326 B
Markdown
|
|
## Core Functions
|
|
|
|
### DecodeVarint
|
|
|
|
~~~~~
|
|
void DecodeVarint(out_val) {
|
|
in UI8
|
|
if (in & (1 << 7)) {
|
|
DecodeVarint(out_val);
|
|
out_val = (out_val << 7) | (in & ((1 << 7) - 1));
|
|
} else {
|
|
out_val = in;
|
|
}
|
|
}
|
|
~~~~~
|
|
{:.draco-syntax }
|