summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRalph Giles <giles@xiph.org>2006-01-09 01:45:05 +0000
committerRalph Giles <giles@xiph.org>2006-01-09 01:45:05 +0000
commit521f4d211d5435e623992b09bbd1d8e21e7af3c2 (patch)
tree741b7f1734502fd7d8e02d26db77fd164148f00f
parent11396c027a7f457ae4e68f01b4962988f128c46b (diff)
downloadtremor-521f4d211d5435e623992b09bbd1d8e21e7af3c2.tar.gz
Fix a number of warnings, issue #622.
git-svn-id: https://svn.xiph.org/trunk/Tremor@10707 0101bb08-14d6-0310-b084-bc0e0c8e3800
-rw-r--r--block.h48
-rw-r--r--floor0.c2
-rw-r--r--floor1.c1
-rw-r--r--mdct.c1
-rw-r--r--misc.h3
-rw-r--r--res012.c1
-rw-r--r--synthesis.c1
-rw-r--r--vorbisfile.c4
8 files changed, 58 insertions, 3 deletions
diff --git a/block.h b/block.h
new file mode 100644
index 0000000..a563586
--- /dev/null
+++ b/block.h
@@ -0,0 +1,48 @@
+/********************************************************************
+ * *
+ * THIS FILE IS PART OF THE OggVorbis 'TREMOR' CODEC SOURCE CODE. *
+ * *
+ * USE, DISTRIBUTION AND REPRODUCTION OF THIS LIBRARY SOURCE IS *
+ * GOVERNED BY A BSD-STYLE SOURCE LICENSE INCLUDED WITH THIS SOURCE *
+ * IN 'COPYING'. PLEASE READ THESE TERMS BEFORE DISTRIBUTING. *
+ * *
+ * THE OggVorbis 'TREMOR' SOURCE CODE IS (C) COPYRIGHT 1994-2006 *
+ * BY THE Xiph.Org FOUNDATION http://www.xiph.org/ *
+ * *
+ ********************************************************************
+
+ function: shared block functions
+
+ ********************************************************************/
+
+#ifndef _V_BLOCK_
+#define _V_BLOCK_
+
+extern void _vorbis_block_ripcord(vorbis_block *vb);
+extern void *_vorbis_block_alloc(vorbis_block *vb,long bytes);
+
+#endif
+/********************************************************************
+ * *
+ * THIS FILE IS PART OF THE OggVorbis 'TREMOR' CODEC SOURCE CODE. *
+ * *
+ * USE, DISTRIBUTION AND REPRODUCTION OF THIS LIBRARY SOURCE IS *
+ * GOVERNED BY A BSD-STYLE SOURCE LICENSE INCLUDED WITH THIS SOURCE *
+ * IN 'COPYING'. PLEASE READ THESE TERMS BEFORE DISTRIBUTING. *
+ * *
+ * THE OggVorbis 'TREMOR' SOURCE CODE IS (C) COPYRIGHT 1994-2002 *
+ * BY THE Xiph.Org FOUNDATION http://www.xiph.org/ *
+ * *
+ ********************************************************************
+
+ function: block functions
+
+ ********************************************************************/
+
+#ifndef _V_BLOCK_
+#define _V_BLOCK_
+
+extern void _vorbis_block_ripcord(vorbis_block *vb);
+extern void *_vorbis_block_alloc(vorbis_block *vb,long bytes);
+
+#endif
diff --git a/floor0.c b/floor0.c
index 02ac65d..081d00e 100644
--- a/floor0.c
+++ b/floor0.c
@@ -24,6 +24,7 @@
#include "registry.h"
#include "codebook.h"
#include "misc.h"
+#include "block.h"
#define LSP_FRACBITS 14
@@ -342,7 +343,6 @@ static vorbis_info_floor *floor0_unpack (vorbis_info *vi,oggpack_buffer *opb){
static vorbis_look_floor *floor0_look (vorbis_dsp_state *vd,vorbis_info_mode *mi,
vorbis_info_floor *i){
int j;
- ogg_int32_t scale;
vorbis_info *vi=vd->vi;
codec_setup_info *ci=(codec_setup_info *)vi->codec_setup;
vorbis_info_floor0 *info=(vorbis_info_floor0 *)i;
diff --git a/floor1.c b/floor1.c
index 21dd5be..80c6dd2 100644
--- a/floor1.c
+++ b/floor1.c
@@ -24,6 +24,7 @@
#include "registry.h"
#include "codebook.h"
#include "misc.h"
+#include "block.h"
#define floor1_rangedB 140 /* floor 1 fixed at -140dB to 0dB range */
diff --git a/mdct.c b/mdct.c
index c440da3..4f39e7d 100644
--- a/mdct.c
+++ b/mdct.c
@@ -33,6 +33,7 @@
********************************************************************/
#include "ivorbiscodec.h"
+#include "codebook.h"
#include "misc.h"
#include "mdct.h"
#include "mdct_lookup.h"
diff --git a/misc.h b/misc.h
index a161138..0547ac7 100644
--- a/misc.h
+++ b/misc.h
@@ -21,6 +21,7 @@
#include "os.h"
#include "asm_arm.h"
+#include <stdlib.h> /* for abs() */
#ifndef _V_WIDE_MATH
#define _V_WIDE_MATH
@@ -182,6 +183,8 @@ static inline ogg_int32_t VFLOAT_MULT(ogg_int32_t a,ogg_int32_t ap,
return 0;
}
+int _ilog(unsigned int);
+
static inline ogg_int32_t VFLOAT_MULTI(ogg_int32_t a,ogg_int32_t ap,
ogg_int32_t i,
ogg_int32_t *p){
diff --git a/res012.c b/res012.c
index 56e98f3..e5d87e9 100644
--- a/res012.c
+++ b/res012.c
@@ -25,6 +25,7 @@
#include "codebook.h"
#include "misc.h"
#include "os.h"
+#include "block.h"
typedef struct {
vorbis_info_residue0 *info;
diff --git a/synthesis.c b/synthesis.c
index 43fa70d..962c730 100644
--- a/synthesis.c
+++ b/synthesis.c
@@ -22,6 +22,7 @@
#include "codec_internal.h"
#include "registry.h"
#include "misc.h"
+#include "block.h"
int vorbis_synthesis(vorbis_block *vb,ogg_packet *op,int decodep){
vorbis_dsp_state *vd=vb->vd;
diff --git a/vorbisfile.c b/vorbisfile.c
index 0487881..0da4e0c 100644
--- a/vorbisfile.c
+++ b/vorbisfile.c
@@ -61,7 +61,7 @@
static long _get_data(OggVorbis_File *vf){
errno=0;
if(vf->datasource){
- char *buffer=ogg_sync_bufferin(vf->oy,CHUNKSIZE);
+ unsigned char *buffer=ogg_sync_bufferin(vf->oy,CHUNKSIZE);
long bytes=(vf->callbacks.read_func)(buffer,1,CHUNKSIZE,vf->datasource);
if(bytes>0)ogg_sync_wrote(vf->oy,bytes);
if(bytes==0 && errno)return(-1);
@@ -678,7 +678,7 @@ static int _ov_open1(void *f,OggVorbis_File *vf,char *initial,
previously read data (as we may be reading from a non-seekable
stream) */
if(initial){
- char *buffer=ogg_sync_bufferin(vf->oy,ibytes);
+ unsigned char *buffer=ogg_sync_bufferin(vf->oy,ibytes);
memcpy(buffer,initial,ibytes);
ogg_sync_wrote(vf->oy,ibytes);
}