NewBitWriter creates a BitWriter with the given initial capacity in bytes.
(capacity int)
| 71 | |
| 72 | // NewBitWriter creates a BitWriter with the given initial capacity in bytes. |
| 73 | func NewBitWriter(capacity int) *BitWriter { |
| 74 | return &BitWriter{data: make([]byte, capacity)} |
| 75 | } |
| 76 | |
| 77 | // WriteBits writes n bits (1-32) from the least significant bits of val. |
| 78 | func (w *BitWriter) WriteBits(val uint32, n int) { |
no outgoing calls
searching dependent graphs…