mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
846b228dbb
--HG-- extra : rebase_source : 04d15a3e154054fe00b3c01f3c252f5f9613e3e8
69 lines
2.5 KiB
Diff
69 lines
2.5 KiB
Diff
diff --git a/media/libvorbis/include/vorbis/codec.h b/media/libvorbis/include/vorbis/codec.h
|
|
index b23fe0a..c62b2d5 100644
|
|
--- a/media/libvorbis/include/vorbis/codec.h
|
|
+++ b/media/libvorbis/include/vorbis/codec.h
|
|
@@ -170,18 +170,19 @@ extern void vorbis_comment_add(vorbis_comment *vc, char *comment);
|
|
extern void vorbis_comment_add_tag(vorbis_comment *vc,
|
|
const char *tag, const char *contents);
|
|
extern char *vorbis_comment_query(vorbis_comment *vc, const char *tag, int count);
|
|
extern int vorbis_comment_query_count(vorbis_comment *vc, const char *tag);
|
|
extern void vorbis_comment_clear(vorbis_comment *vc);
|
|
|
|
extern int vorbis_block_init(vorbis_dsp_state *v, vorbis_block *vb);
|
|
extern int vorbis_block_clear(vorbis_block *vb);
|
|
+extern void vorbis_dsp_init(vorbis_dsp_state *v);
|
|
extern void vorbis_dsp_clear(vorbis_dsp_state *v);
|
|
extern double vorbis_granule_time(vorbis_dsp_state *v,
|
|
ogg_int64_t granulepos);
|
|
|
|
extern const char *vorbis_version_string(void);
|
|
|
|
/* Vorbis PRIMITIVES: analysis/DSP layer ****************************/
|
|
|
|
extern int vorbis_analysis_init(vorbis_dsp_state *v,vorbis_info *vi);
|
|
extern int vorbis_commentheader_out(vorbis_comment *vc, ogg_packet *op);
|
|
diff --git a/media/libvorbis/lib/vorbis_block.c b/media/libvorbis/lib/vorbis_block.c
|
|
index 3b6f456..d7f5974 100644
|
|
--- a/media/libvorbis/lib/vorbis_block.c
|
|
+++ b/media/libvorbis/lib/vorbis_block.c
|
|
@@ -84,18 +84,16 @@ static int ilog2(unsigned int v){
|
|
#ifndef WORD_ALIGN
|
|
#define WORD_ALIGN 8
|
|
#endif
|
|
|
|
int vorbis_block_init(vorbis_dsp_state *v, vorbis_block *vb){
|
|
int i;
|
|
memset(vb,0,sizeof(*vb));
|
|
vb->vd=v;
|
|
- vb->localalloc=0;
|
|
- vb->localstore=NULL;
|
|
if(v->analysisp){
|
|
vorbis_block_internal *vbi=
|
|
vb->internal=_ogg_calloc(1,sizeof(vorbis_block_internal));
|
|
vbi->ampmax=-9999;
|
|
|
|
for(i=0;i<PACKETBLOBS;i++){
|
|
if(i==PACKETBLOBS/2){
|
|
vbi->packetblob[i]=&vb->opb;
|
|
@@ -295,16 +293,20 @@ int vorbis_analysis_init(vorbis_dsp_state *v,vorbis_info *vi){
|
|
|
|
/* compressed audio packets start after the headers
|
|
with sequence number 3 */
|
|
v->sequence=3;
|
|
|
|
return(0);
|
|
}
|
|
|
|
+void vorbis_dsp_init(vorbis_dsp_state *v){
|
|
+ memset(v,0,sizeof(*v));
|
|
+}
|
|
+
|
|
void vorbis_dsp_clear(vorbis_dsp_state *v){
|
|
int i;
|
|
if(v){
|
|
vorbis_info *vi=v->vi;
|
|
codec_setup_info *ci=(vi?vi->codec_setup:NULL);
|
|
private_state *b=v->backend_state;
|
|
|
|
if(b){
|