summaryrefslogtreecommitdiff
path: root/src/xine-engine
diff options
context:
space:
mode:
authorGuenter Bartsch <guenter@users.sourceforge.net>2001-09-10 03:04:48 +0000
committerGuenter Bartsch <guenter@users.sourceforge.net>2001-09-10 03:04:48 +0000
commit6fdc5685796399e9ddea30b7dcffc607bd4c10b3 (patch)
tree4b180a7aa74abbc6b6d8be29520fa27ef0cb848c /src/xine-engine
parent148419cfcd693508fc7a23158b393070a32f97d0 (diff)
downloadxine-lib-6fdc5685796399e9ddea30b7dcffc607bd4c10b3.tar.gz
xine-lib-6fdc5685796399e9ddea30b7dcffc607bd4c10b3.tar.bz2
a quicktime demuxer based on openquicktime, cinepack support fixed, minor bugfixes regarding buffer type handling
CVS patchset: 600 CVS date: 2001/09/10 03:04:48
Diffstat (limited to 'src/xine-engine')
-rw-r--r--src/xine-engine/audio_decoder.c18
-rw-r--r--src/xine-engine/audio_out.c10
-rw-r--r--src/xine-engine/audio_out.h3
-rw-r--r--src/xine-engine/buffer.h9
-rw-r--r--src/xine-engine/xine.c6
5 files changed, 28 insertions, 18 deletions
diff --git a/src/xine-engine/audio_decoder.c b/src/xine-engine/audio_decoder.c
index d1cc90071..76bf4d03c 100644
--- a/src/xine-engine/audio_decoder.c
+++ b/src/xine-engine/audio_decoder.c
@@ -17,7 +17,7 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*
- * $Id: audio_decoder.c,v 1.34 2001/09/09 15:39:47 jkeil Exp $
+ * $Id: audio_decoder.c,v 1.35 2001/09/10 03:04:48 guenter Exp $
*
*
* functions that implement audio decoding
@@ -44,11 +44,11 @@ void *audio_decoder_loop (void *this_gen) {
while (running) {
- /* printf ("audio_loop: waiting for package...\n"); */
+ /* printf ("audio_loop: waiting for package...\n"); */
buf = this->audio_fifo->get (this->audio_fifo);
-
- /* printf ("audio_loop: got package pts = %d\n", buf->PTS); */
+
+ /* printf ("audio_loop: got package pts = %d\n", buf->PTS); */
if (buf->input_pos)
this->cur_input_pos = buf->input_pos;
@@ -134,7 +134,7 @@ void *audio_decoder_loop (void *this_gen) {
if ( (buf->type & 0xFF000000) == BUF_AUDIO_BASE ) {
- /* printf ("audio_decoder: got an audio buffer, type %08x\n", buf->type); */
+ /* printf ("audio_loop: got an audio buffer, type %08x\n", buf->type); */
/* update track map */
@@ -143,7 +143,7 @@ void *audio_decoder_loop (void *this_gen) {
i++;
/*
- printf ("audio_decoder: got an audio buffer, type %08x, %d map entries, i=%d\n",
+ printf ("audio_loop: got an audio buffer, type %08x, %d map entries, i=%d\n",
buf->type, this->audio_track_map_entries, i);
*/
@@ -184,16 +184,18 @@ void *audio_decoder_loop (void *this_gen) {
this->cur_audio_decoder_plugin = decoder;
this->cur_audio_decoder_plugin->init (this->cur_audio_decoder_plugin, this->audio_out);
- printf ("audio_decoder: using decoder >%s< \n",
+ printf ("audio_loop: using decoder >%s< \n",
decoder->get_identifier());
}
+
+ /* printf ("audio_loop: sending data to decoder\n"); */
decoder->decode_data (decoder, buf);
}
}
} else
- printf ("audio_decoder: unknown buffer type: %08x\n", buf->type);
+ printf ("audio_loop: unknown buffer type: %08x\n", buf->type);
profiler_stop_count (1);
}
diff --git a/src/xine-engine/audio_out.c b/src/xine-engine/audio_out.c
index cb9846410..f3cef32fd 100644
--- a/src/xine-engine/audio_out.c
+++ b/src/xine-engine/audio_out.c
@@ -17,7 +17,7 @@
* along with self program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*
- * $Id: audio_out.c,v 1.12 2001/09/06 15:26:07 joachim_koenig Exp $
+ * $Id: audio_out.c,v 1.13 2001/09/10 03:04:48 guenter Exp $
*
* 22-8-2001 James imported some useful AC3 sections from the previous alsa driver.
* (c) 2001 Andy Lo A Foe <andy@alsaplayer.org>
@@ -135,6 +135,7 @@ static int ao_open(ao_instance_t *this,
this->mode = mode;
this->input_frame_rate = rate;
+ this->bits = bits;
this->audio_started = 0;
this->last_audio_vpts = 0;
@@ -150,6 +151,11 @@ static int ao_open(ao_instance_t *this,
default: /* AUTO */
this->do_resample = this->output_frame_rate != this->input_frame_rate;
}
+
+ /* HACK: we do not have resample functions for 8-bit audio */
+ if (this->bits==8)
+ this->do_resample = 0;
+
if (this->do_resample)
printf("audio_out: will resample audio from %d to %d\n",
this->input_frame_rate, this->output_frame_rate);
@@ -311,7 +317,7 @@ static int ao_write(ao_instance_t *this,
} else switch (this->mode) {
case AO_CAP_MODE_MONO:
audio_out_resample_mono (output_frames, num_frames,
- this->frame_buffer, num_output_frames);
+ this->frame_buffer, num_output_frames);
this->driver->write(this->driver, this->frame_buffer, num_output_frames);
break;
case AO_CAP_MODE_STEREO:
diff --git a/src/xine-engine/audio_out.h b/src/xine-engine/audio_out.h
index f2a0e2b4b..83a18a1ce 100644
--- a/src/xine-engine/audio_out.h
+++ b/src/xine-engine/audio_out.h
@@ -17,7 +17,7 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*
- * $Id: audio_out.h,v 1.13 2001/09/06 13:27:47 jkeil Exp $
+ * $Id: audio_out.h,v 1.14 2001/09/10 03:04:48 guenter Exp $
*/
#ifndef HAVE_AUDIO_OUT_H
#define HAVE_AUDIO_OUT_H
@@ -167,6 +167,7 @@ struct ao_instance_s {
int resample_conf;
int do_resample;
int mode;
+ int bits;
int gap_tolerance;
uint16_t *frame_buffer;
int16_t *zero_space;
diff --git a/src/xine-engine/buffer.h b/src/xine-engine/buffer.h
index 2830cb18c..85f99e585 100644
--- a/src/xine-engine/buffer.h
+++ b/src/xine-engine/buffer.h
@@ -17,7 +17,7 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*
- * $Id: buffer.h,v 1.11 2001/09/08 18:11:41 guenter Exp $
+ * $Id: buffer.h,v 1.12 2001/09/10 03:04:48 guenter Exp $
*
*
* contents:
@@ -70,7 +70,7 @@ extern "C" {
#define BUF_VIDEO_BASE 0x02000000
#define BUF_VIDEO_MPEG 0x02000000
#define BUF_VIDEO_MPEG4 0x02010000
-#define BUF_VIDEO_QUICKTIME 0x02020000
+#define BUF_VIDEO_CINEPAK 0x02020000
#define BUF_VIDEO_SORENSON 0x02030000
#define BUF_VIDEO_MSMPEG4 0x02040000
#define BUF_VIDEO_MJPEG 0x02050000
@@ -82,7 +82,10 @@ extern "C" {
#define BUF_VIDEO_ATIVCR2 0x020b0000
#define BUF_VIDEO_I263 0x020c0000
#define BUF_VIDEO_RV10 0x020d0000
-#define BUF_VIDEO_CINEPACK 0x020e0000
+#define BUF_VIDEO_FILL 0x020e0000
+#define BUF_VIDEO_RGB 0x020f0000
+#define BUF_VIDEO_YUY2 0x02100000
+#define BUF_VIDEO_JPEG 0x02110000
/* audio buffer types: */
diff --git a/src/xine-engine/xine.c b/src/xine-engine/xine.c
index 8af7b3461..b78b3a994 100644
--- a/src/xine-engine/xine.c
+++ b/src/xine-engine/xine.c
@@ -17,7 +17,7 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*
- * $Id: xine.c,v 1.58 2001/09/06 18:38:12 jkeil Exp $
+ * $Id: xine.c,v 1.59 2001/09/10 03:04:48 guenter Exp $
*
* top-level xine functions
*
@@ -127,7 +127,7 @@ static int try_demux_with_stages(xine_t *this, const char *MRL,
while(stages[s] != -1) {
for(i = 0; i < this->num_demuxer_plugins; i++) {
- printf ("trying demuxer %s\n", this->demuxer_plugins[i]->get_identifier());
+ /* printf ("trying demuxer %s\n", this->demuxer_plugins[i]->get_identifier()); */
if(this->demuxer_plugins[i]->open(this->demuxer_plugins[i],
this->cur_input_plugin,
stages[s]) == DEMUX_CAN_HANDLE) {
@@ -284,8 +284,6 @@ void xine_play (xine_t *this, char *mrl,
this->metronom->set_speed (this->metronom, SPEED_NORMAL);
this->audio_mute = 0;
this->speed = SPEED_NORMAL;
-
- printf ("xine_play: demuxer started\n");
}
pthread_mutex_unlock (&this->xine_lock);