bs_write_sint_exp_golomb {bitstreamio} | R Documentation |
Read/Write Exponential-Golomb encoded signed integers
Description
Read/Write Exponential-Golomb encoded signed integers
Usage
bs_write_sint_exp_golomb(bs, x)
bs_read_sint_exp_golomb(bs, n = 1L)
Arguments
bs |
Bistream connection object created with |
x |
integer vector to write |
n |
number of encoded integers to read |
Value
Reading returns a vector of integers. Writing returns the bitstream invisibly.
Examples
bs <- bs_open(raw(), 'w')
bs_write_sint_exp_golomb(bs, c(0, 4, -21))
raw_vec <- bs_close(bs)
raw_vec
bs <- bs_open(raw_vec, 'r')
bs_read_sint_exp_golomb(bs, 3)
bs_close(bs)
[Package bitstreamio version 0.1.0 Index]