Updated project files to VS2008 SP1. Removed deprecated features (and warning message...
[xiph/unicode.git] / tarkin / bitwise.h
blobdb51d173870d52bb30d900c8b508e8b649f38588
1 /********************************************************************
2 * *
3 * THIS FILE IS PART OF THE Ogg Vorbis SOFTWARE CODEC SOURCE CODE. *
4 * USE, DISTRIBUTION AND REPRODUCTION OF THIS SOURCE IS GOVERNED BY *
5 * THE GNU PUBLIC LICENSE 2, WHICH IS INCLUDED WITH THIS SOURCE. *
6 * PLEASE READ THESE TERMS DISTRIBUTING. *
7 * *
8 * THE OggSQUISH SOURCE CODE IS (C) COPYRIGHT 1994-2000 *
9 * by Monty <monty@xiph.org> and The XIPHOPHORUS Company *
10 * http://www.xiph.org/ *
11 * *
12 ********************************************************************
14 function: packing variable sized words into an octet stream
15 last mod: $Id: bitwise.h,v 1.1 2001/02/13 01:06:24 giles Exp $
17 ********************************************************************/
19 #ifndef _V_BITW_H_
20 #define _V_BITW_H_
22 typedef struct {
23 long endbyte;
24 int endbit;
26 unsigned char *buffer;
27 unsigned char *ptr;
28 long storage;
30 } oggpack_buffer;
32 extern void _oggpack_writeinit(oggpack_buffer *b);
33 extern void _oggpack_reset(oggpack_buffer *b);
34 extern void _oggpack_writeclear(oggpack_buffer *b);
35 extern void _oggpack_readinit(oggpack_buffer *b,char *buf,int bytes);
36 extern void _oggpack_write(oggpack_buffer *b,unsigned long value,int bits);
37 extern long _oggpack_look(oggpack_buffer *b,int bits);
38 extern long _oggpack_look1(oggpack_buffer *b);
39 extern void _oggpack_adv(oggpack_buffer *b,int bits);
40 extern void _oggpack_adv1(oggpack_buffer *b);
41 extern long _oggpack_read(oggpack_buffer *b,int bits);
42 extern long _oggpack_read1(oggpack_buffer *b);
43 extern long _oggpack_bytes(oggpack_buffer *b);
44 extern long _oggpack_bits(oggpack_buffer *b);
45 extern char *_oggpack_buffer(oggpack_buffer *b);
47 #endif