openalbridge/oggvorbis.h
author koda
Sun, 12 Jul 2009 19:12:08 +0000
changeset 2260 31756e21c436
parent 2257 7eb31efcfb9b
child 2265 eae64600fb69
permissions -rw-r--r--
other indentation, binding and miscellaneous fixes to openalbridge
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
2213
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
     1
/********************************************************************
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
     2
 *                                                                  *
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
     3
 * THIS FILE IS PART OF THE OggVorbis SOFTWARE CODEC SOURCE CODE.   *
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
     4
 * USE, DISTRIBUTION AND REPRODUCTION OF THIS LIBRARY SOURCE IS     *
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
     5
 * GOVERNED BY A BSD-STYLE SOURCE LICENSE INCLUDED WITH THIS SOURCE *
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
     6
 * IN 'COPYING'. PLEASE READ THESE TERMS BEFORE DISTRIBUTING.       *
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
     7
 *                                                                  *
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
     8
 * THE OggVorbis SOURCE CODE IS (C) COPYRIGHT 1994-2002             *
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
     9
 * by the Xiph.Org Foundation http://www.xiph.org/                  *
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    10
 *                                                                  *
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    11
 ********************************************************************/
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    12
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    13
#ifndef _OGGVORBIS_H
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    14
#define _OGGVORBIS_H
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    15
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    16
/*data types for ogg and vorbis that are required to be external*/
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    17
#ifndef ogg_int64_t	
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    18
#define ogg_int64_t int64_t
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    19
#endif
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    20
typedef struct {
2260
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    21
    unsigned char *data;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    22
    int storage;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    23
    int fill;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    24
    int returned;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    25
    int unsynced;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    26
    int headerbytes;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    27
    int bodybytes;
2213
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    28
} ogg_sync_state;
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    29
typedef struct vorbis_info{
2260
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    30
    int version;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    31
    int channels;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    32
    long rate;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    33
    /* The below bitrate declarations are *hints*.
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    34
     Combinations of the three values carry the following implications:
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    35
     all three set to the same value: implies a fixed rate bitstream
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    36
     only nominal set: implies a VBR stream that averages the nominal bitrate.  No hard upper/lower limit
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    37
     upper and or lower set: implies a VBR bitstream that obeys the bitrate limits. nominal may also be set to give a nominal rate.
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    38
     none set: the coder does not care to speculate. */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    39
    long bitrate_upper;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    40
    long bitrate_nominal;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    41
    long bitrate_lower;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    42
    long bitrate_window;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    43
    void *codec_setup;
2213
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    44
} vorbis_info;
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    45
typedef struct vorbis_comment{
2260
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    46
    /* unlimited user comment fields.  libvorbis writes 'libvorbis' whatever vendor is set to in encode */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    47
    char **user_comments;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    48
    int   *comment_lengths;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    49
    int    comments;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    50
    char  *vendor;
2213
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    51
} vorbis_comment;
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    52
typedef struct {
2260
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    53
    unsigned char   *body_data;    /* bytes from packet bodies */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    54
    long    body_storage;          /* storage elements allocated */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    55
    long    body_fill;             /* elements stored; fill mark */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    56
    long    body_returned;         /* elements of fill returned */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    57
    int     *lacing_vals;      /* The values that will go to the segment table */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    58
    ogg_int64_t *granule_vals; 
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    59
    /* granulepos values for headers. Not compact
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    60
     this way, but it is simple coupled to the lacing fifo */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    61
    long    lacing_storage;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    62
    long    lacing_fill;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    63
    long    lacing_packet;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    64
    long    lacing_returned;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    65
    unsigned char    header[282];      /* working space for header encode */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    66
    int              header_fill;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    67
    int     e_o_s;          /* set when we have buffered the last packet in the logical bitstream */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    68
    int     b_o_s;          /* set after we've written the initial page of a logical bitstream */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    69
    long    serialno;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    70
    long    pageno;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    71
    ogg_int64_t  packetno;      
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    72
    /* sequence number for decode; the framing knows where there's a hole in the data,
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    73
     but we need coupling so that the codec (which is in a seperate abstraction layer) also knows about the gap */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    74
    ogg_int64_t   granulepos;
2213
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    75
} ogg_stream_state;
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    76
typedef struct vorbis_dsp_state{
2260
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    77
    int analysisp;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    78
    vorbis_info *vi;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    79
    float **pcm;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    80
    float **pcmret;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    81
    int  pcm_storage;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    82
    int  pcm_current;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    83
    int  pcm_returned;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    84
    int  preextrapolate;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    85
    int  eofflag;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    86
    long lW;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    87
    long W;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    88
    long nW;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    89
    long centerW;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    90
    ogg_int64_t granulepos;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    91
    ogg_int64_t sequence;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    92
    ogg_int64_t glue_bits;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    93
    ogg_int64_t time_bits;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    94
    ogg_int64_t floor_bits;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    95
    ogg_int64_t res_bits;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    96
    void       *backend_state;
2213
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    97
} vorbis_dsp_state;
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
    98
typedef struct {
2260
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
    99
    long endbyte;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   100
    int  endbit;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   101
    unsigned char *buffer;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   102
    unsigned char *ptr;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   103
    long storage;
2213
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
   104
} oggpack_buffer;
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
   105
typedef struct vorbis_block{
2260
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   106
    /* necessary stream state for linking to the framing abstraction */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   107
    float **pcm;       /* this is a pointer into local storage */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   108
    oggpack_buffer opb;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   109
    long  lW;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   110
    long  W;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   111
    long  nW;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   112
    int   pcmend;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   113
    int   mode;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   114
    int   eofflag;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   115
    ogg_int64_t granulepos;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   116
    ogg_int64_t sequence;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   117
    vorbis_dsp_state *vd; /* For read-only access of configuration */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   118
    /* local storage to avoid remallocing; it's up to the mapping to structure it */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   119
    void  *localstore;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   120
    long  localtop;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   121
    long  localalloc;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   122
    long  totaluse;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   123
    struct alloc_chain *reap;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   124
    /* bitmetrics for the frame */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   125
    long glue_bits;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   126
    long time_bits;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   127
    long floor_bits;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   128
    long res_bits;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   129
    void *internal;
2213
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
   130
} vorbis_block;
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
   131
typedef struct {
2260
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   132
    size_t (*read_func)  (void *ptr, size_t size, size_t nmemb, void *datasource);
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   133
    int    (*seek_func)  (void *datasource, ogg_int64_t offset, int whence);
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   134
    int    (*close_func) (void *datasource);
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   135
    long   (*tell_func)  (void *datasource);
2213
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
   136
} ov_callbacks;
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
   137
typedef struct OggVorbis_File {
2260
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   138
    void            *datasource; /* Pointer to a FILE *, etc. */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   139
    int              seekable;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   140
    ogg_int64_t      offset;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   141
    ogg_int64_t      end;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   142
    ogg_sync_state   oy;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   143
    /* If the FILE handle isn't seekable (eg, a pipe), only the current stream appears */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   144
    int              links;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   145
    ogg_int64_t     *offsets;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   146
    ogg_int64_t     *dataoffsets;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   147
    long            *serialnos;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   148
    ogg_int64_t     *pcmlengths; 
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   149
    /* overloaded to maintain binary
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   150
     compatability; x2 size, stores both
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   151
     beginning and end values */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   152
    vorbis_info     *vi;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   153
    vorbis_comment  *vc;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   154
    /* Decoding working state local storage */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   155
    ogg_int64_t      pcm_offset;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   156
    int              ready_state;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   157
    long             current_serialno;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   158
    int              current_link;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   159
    double           bittrack;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   160
    double           samptrack;
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   161
    ogg_stream_state os; /* take physical pages, weld into a logical stream of packets */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   162
    vorbis_dsp_state vd; /* central working state for the packet->PCM decoder */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   163
    vorbis_block     vb; /* local working space for packet->PCM decode */
31756e21c436 other indentation, binding and miscellaneous fixes to openalbridge
koda
parents: 2257
diff changeset
   164
    ov_callbacks callbacks;
2213
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
   165
} OggVorbis_File;
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
   166
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
   167
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
   168
extern int ov_open(FILE *f,OggVorbis_File *vf,char *initial,long ibytes);
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
   169
extern long ov_read(OggVorbis_File *vf,char *buffer,int length,int bigendianp,int word,int sgned,int *bitstream);
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
   170
extern ogg_int64_t ov_pcm_total(OggVorbis_File *vf,int i);
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
   171
extern long ov_read(OggVorbis_File *vf,char *buffer,int length,int bigendianp,int word,int sgned,int *bitstream);
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
   172
extern vorbis_info *ov_info(OggVorbis_File *vf,int link);
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
   173
extern vorbis_comment *ov_comment(OggVorbis_File *f, int num);
2257
7eb31efcfb9b updates licence and fix a memory leak (which was consuming iphone memory)
koda
parents: 2213
diff changeset
   174
extern int ov_clear(OggVorbis_File *vf);
2213
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
   175
bd51bbf06033 -Smaxx's porting of the library to MSVC compilers
koda
parents:
diff changeset
   176
#endif /*_OGGVORBIS_H*/