From 8e1e84d311069067b45f2841f2dbb4142a944b17 Mon Sep 17 00:00:00 2001 From: Saxon Date: Mon, 29 Jul 2019 13:43:03 +0930 Subject: [PATCH] codec/h264/h264dec/bits: removed ReadBitsInt and ReadBool as not required anymore --- codec/h264/h264dec/bits/bitreader.go | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/codec/h264/h264dec/bits/bitreader.go b/codec/h264/h264dec/bits/bitreader.go index 08cc5d41..7e17f407 100644 --- a/codec/h264/h264dec/bits/bitreader.go +++ b/codec/h264/h264dec/bits/bitreader.go @@ -128,24 +128,6 @@ func (br *BitReader) ReadBits(n int) (uint64, error) { return r, nil } -// ReadBitsInt reads n bits from the source, and returns as an int. -func (br *BitReader) ReadBitsInt(n int) (int, error) { - b, err := br.ReadBits(n) - if err != nil { - return 0, err - } - return int(b), nil -} - -// ReadBool reads a single bit from the source, converts to a bool and returns. -func (br *BitReader) ReadBool() (bool, error) { - b, err := br.ReadBits(1) - if err != nil { - return false, err - } - return b == 1, nil -} - // PeekBits provides the next n bits returning them in the least-significant // part of a uint64, without advancing through the source. // For example, with a source as []byte{0x8f,0xe3} (1000 1111, 1110 0011), we