summaryrefslogtreecommitdiff
path: root/src/lib/openjp2/bio.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/openjp2/bio.c')
-rw-r--r--src/lib/openjp2/bio.c26
1 files changed, 10 insertions, 16 deletions
diff --git a/src/lib/openjp2/bio.c b/src/lib/openjp2/bio.c
index 09dcd7f5..8106df75 100644
--- a/src/lib/openjp2/bio.c
+++ b/src/lib/openjp2/bio.c
@@ -44,12 +44,6 @@
/*@{*/
/**
-Write a bit
-@param bio BIO handle
-@param b Bit to write (0 or 1)
-*/
-static void opj_bio_putbit(opj_bio_t *bio, OPJ_UINT32 b);
-/**
Read a bit
@param bio BIO handle
@return Returns the read bit
@@ -100,16 +94,6 @@ static OPJ_BOOL opj_bio_bytein(opj_bio_t *bio)
return OPJ_TRUE;
}
-static void opj_bio_putbit(opj_bio_t *bio, OPJ_UINT32 b)
-{
- if (bio->ct == 0) {
- opj_bio_byteout(
- bio); /* MSD: why not check the return value of this function ? */
- }
- bio->ct--;
- bio->buf |= b << bio->ct;
-}
-
static OPJ_UINT32 opj_bio_getbit(opj_bio_t *bio)
{
if (bio->ct == 0) {
@@ -162,6 +146,16 @@ void opj_bio_init_dec(opj_bio_t *bio, OPJ_BYTE *bp, OPJ_UINT32 len)
bio->ct = 0;
}
+void opj_bio_putbit(opj_bio_t *bio, OPJ_UINT32 b)
+{
+ if (bio->ct == 0) {
+ opj_bio_byteout(
+ bio); /* MSD: why not check the return value of this function ? */
+ }
+ bio->ct--;
+ bio->buf |= b << bio->ct;
+}
+
void opj_bio_write(opj_bio_t *bio, OPJ_UINT32 v, OPJ_UINT32 n)
{
OPJ_INT32 i;