Displaying 11 results from an estimated 11 matches for "swfdecaudioout".
2007 Apr 05
0
4 commits - libswfdec/swfdec_audio_flv.c libswfdec/swfdec_audio_stream.c libswfdec/swfdec_codec_adpcm.c libswfdec/swfdec_codec.c libswfdec/swfdec_codec_ffmpeg.c libswfdec/swfdec_codec_gst.c libswfdec/swfdec_codec.h libswfdec/swfdec_codec_mad.c
...ern const SwfdecVideoCodec swfdec_codec_ffmpeg_video;
#endif
-extern const SwfdecVideoCodec swfdec_codec_gst_h263;
+extern const SwfdecVideoCodec swfdec_codec_gst_video;
/*** UNCOMPRESSED SOUND ***/
#define U8_FLAG (0x10000)
static gpointer
-swfdec_codec_uncompressed_init (gboolean width, SwfdecAudioOut format)
+swfdec_codec_uncompressed_init (SwfdecAudioFormat type, gboolean width, SwfdecAudioOut format)
{
guint ret = format;
if (!width)
@@ -121,7 +119,7 @@ swfdec_codec_get_audio (SwfdecAudioForma
case SWFDEC_AUDIO_FORMAT_ADPCM:
return &swfdec_codec_adpcm;
#ifdef HAVE_FFMP...
2007 Apr 08
0
6 commits - libswfdec/Makefile.am libswfdec/swfdec_audio_flv.c libswfdec/swfdec_audio_flv.h libswfdec/swfdec_audio_stream.c libswfdec/swfdec_audio_stream.h libswfdec/swfdec_buffer.c libswfdec/swfdec_codec_adpcm.c libswfdec/swfdec_codec_audio.c
...b/libswfdec/swfdec_audio_flv.h
@@ -41,15 +41,13 @@ struct _SwfdecAudioFlv
SwfdecFlvDecoder * flvdecoder; /* decoder we play back */
SwfdecAudioFormat format; /* codec format of audio */
- const SwfdecAudioCodec *codec; /* codec in use */
gboolean width; /* width of audio */
SwfdecAudioOut in; /* input format of data */
- SwfdecAudioOut out; /* output format of codec */
- gpointer decoder; /* decoder used for playback */
+ SwfdecAudioDecoder * decoder; /* decoder used for playback */
SwfdecTick timestamp; /* current playback timestamp */
- guint next_timestamp; /* next...
2007 Mar 29
0
libswfdec-gtk/swfdec_playback_alsa.c libswfdec/swfdec_audio_event.h libswfdec/swfdec_audio_flv.h libswfdec/swfdec_audio_stream.h libswfdec/swfdec_bits.c libswfdec/swfdec_bits.h libswfdec/swfdec_buffer.c libswfdec/swfdec_buffer.h libswfdec/swfdec_cache.c
...ec/swfdec_audio_stream.h
index 8758462..9d31b3c 100644
--- a/libswfdec/swfdec_audio_stream.h
+++ b/libswfdec/swfdec_audio_stream.h
@@ -46,9 +46,9 @@ struct _SwfdecAudioStream
const SwfdecAudioCodec *codec; /* codec used by this stream */
gpointer decoder; /* decoder used for this frame */
SwfdecAudioOut format; /* format used by decoder */
- unsigned int playback_skip; /* number of samples to skip at the beginning of queue */
+ guint playback_skip; /* number of samples to skip at the beginning of queue */
GQueue * playback_queue; /* all the samples we've decoded so far */
- unsigned...
2007 Jan 16
0
9 commits - libswfdec/js libswfdec/Makefile.am libswfdec/swfdec_audio_stream.c libswfdec/swfdec_audio_stream.h libswfdec/swfdec_cache.c libswfdec/swfdec_cached.c libswfdec/swfdec_cached.h libswfdec/swfdec_edittext_movie.c libswfdec/swfdec_image.c
...S
@@ -42,6 +43,7 @@ struct _SwfdecAudioStream
SwfdecSprite * sprite; /* sprite we're playing back */
SwfdecSound * sound; /* sound we're playing */
+ const SwfdecAudioCodec *codec; /* codec used by this stream */
gpointer decoder; /* decoder used for this frame */
SwfdecAudioOut format; /* format used by decoder */
unsigned int playback_skip; /* number of samples to skip at the beginning of queue */
diff --git a/libswfdec/swfdec_sound.c b/libswfdec/swfdec_sound.c
index 6e68f38..1620f5d 100644
--- a/libswfdec/swfdec_sound.c
+++ b/libswfdec/swfdec_sound.c
@@ -179,6 +179...
2007 Jul 18
0
12 commits - configure.ac doc/swfdec-sections.txt libswfdec-gtk/swfdec_playback_alsa.c libswfdec/jpeg libswfdec/Makefile.am libswfdec/swfdec_amf.c libswfdec/swfdec_as_array.c libswfdec/swfdec_as_boolean.h libswfdec/swfdec_as_context.c
...#include <libswfdec/swfdec_types.h>
+#include <libswfdec/swfdec_codec_audio.h>
+#include <libswfdec/swfdec_codec_video.h>
+
+G_BEGIN_DECLS
+
+
+/* audio codecs */
+
+SwfdecAudioDecoder * swfdec_audio_decoder_adpcm_new (SwfdecAudioFormat type,
+ gboolean width,
+ SwfdecAudioOut format);
+#ifdef HAVE_MAD
+SwfdecAudioDecoder * swfdec_audio_decoder_mad_new (SwfdecAudioFormat type,
+ gboolean width,
+ SwfdecAudioOut format);
+#endif
+#ifdef HAVE_FFMPEG
+SwfdecAudioDecoder * swfdec_audio_decoder_ffmpeg_new (SwfdecAudioFormat type,
+ gboolean wid...
2007 Mar 29
0
Branch 'as' - 9 commits - libswfdec-gtk/swfdec_playback_alsa.c libswfdec/js libswfdec/Makefile.am libswfdec/swfdec_as_context.c libswfdec/swfdec_as_context.h libswfdec/swfdec_as_frame.c libswfdec/swfdec_as_frame.h libswfdec/swfdec_as_function.c
...ec/swfdec_audio_stream.h
index 8758462..9d31b3c 100644
--- a/libswfdec/swfdec_audio_stream.h
+++ b/libswfdec/swfdec_audio_stream.h
@@ -46,9 +46,9 @@ struct _SwfdecAudioStream
const SwfdecAudioCodec *codec; /* codec used by this stream */
gpointer decoder; /* decoder used for this frame */
SwfdecAudioOut format; /* format used by decoder */
- unsigned int playback_skip; /* number of samples to skip at the beginning of queue */
+ guint playback_skip; /* number of samples to skip at the beginning of queue */
GQueue * playback_queue; /* all the samples we've decoded so far */
- unsigned...
2007 Mar 20
0
4 commits - libswfdec/swfdec_flv_decoder.c libswfdec/swfdec_flv_decoder.h libswfdec/swfdec_movie.c test/trace
...uct _SwfdecFlvDecoder
int state; /* parsing state we're in */
GArray * audio; /* audio tags */
GArray * video; /* video tags */
+ GArray * data; /* data tags (if any) */
};
struct _SwfdecFlvDecoderClass {
@@ -71,6 +72,9 @@ SwfdecBuffer * swfdec_flv_decoder_get_au
SwfdecAudioOut * format,
guint * real_timestamp,
guint * next_timestamp);
+SwfdecBuffer * swfdec_flv_decoder_get_data (SwfdecFlvDecoder * flv,
+ guint timestamp,
+ guint * real_timestamp);
SwfdecMovie * swfdec_flv_decoder_add_movie (SwfdecFlvDecoder * flv,
Swfdec...
2007 Apr 08
0
libswfdec/swfdec_codec_audio.c libswfdec/swfdec_codec_gst.c
...layer->mutex);
+ g_cond_signal (player->cond);
+ player->done = TRUE;
+ g_mutex_unlock (player->mutex);
+ break;
+ default:
+ break;
+ }
+ return GST_BUS_PASS;
+}
+
+SwfdecAudioDecoder *
+swfdec_audio_decoder_gst_new (SwfdecAudioFormat type, gboolean width, SwfdecAudioOut format)
+{
+ SwfdecGstAudio *player;
+ GstElement *fakesrc, *fakesink, *decoder, *convert;
+ GstBus *bus;
+ GstCaps *caps;
+
+ if (!gst_init_check (NULL, NULL, NULL))
+ return NULL;
+
+ switch (type) {
+ case SWFDEC_AUDIO_FORMAT_MP3:
+ caps = gst_caps_from_string ("audio/mpeg,...
2007 Mar 14
0
10 commits - libswfdec/swfdec_flv_decoder.c libswfdec/swfdec_flv_decoder.h libswfdec/swfdec_js_global.c libswfdec/swfdec_js_movie.c libswfdec/swfdec_js_net_stream.c libswfdec/swfdec_loader.c libswfdec/swfdec_loader.h libswfdec/swfdec_loadertarget.c
...mp;
+ if (last_timestamp)
+ *last_timestamp = g_array_index (flv->video, SwfdecFlvVideoTag, flv->video->len - 1).timestamp;
+ return TRUE;
+}
+
SwfdecBuffer *
swfdec_flv_decoder_get_audio (SwfdecFlvDecoder *flv, guint timestamp,
SwfdecAudioFormat *codec_format, gboolean *width, SwfdecAudioOut *format,
@@ -489,6 +512,22 @@ notify_initialized (SwfdecPlayer *player
swfdec_movie_invalidate (SWFDEC_MOVIE (movie));
}
+gboolean
+swfdec_flv_decoder_is_eof (SwfdecFlvDecoder *flv)
+{
+ g_return_val_if_fail (SWFDEC_IS_FLV_DECODER (flv), TRUE);
+
+ return flv->state == SWFDEC_STATE_EOF;...
2007 Mar 02
0
12 commits - libswfdec/Makefile.am libswfdec/swfdec_audio_flv.c libswfdec/swfdec_flv_decoder.c libswfdec/swfdec_js.c libswfdec/swfdec_js.h libswfdec/swfdec_js_video.c libswfdec/swfdec_loader.c libswfdec/swfdec_loader_internal.h
...(real_timestamp)
- *real_timestamp = tag->timestamp;
+ *real_timestamp = tag->timestamp - offset;
if (format)
*format = tag->format;
return tag->buffer;
@@ -418,22 +429,37 @@ swfdec_flv_decoder_get_audio (SwfdecFlvD
SwfdecAudioFormat *codec_format, gboolean *width, SwfdecAudioOut *format,
guint *real_timestamp, guint *next_timestamp)
{
- guint id;
+ guint id, offset;
SwfdecFlvAudioTag *tag;
g_return_val_if_fail (SWFDEC_IS_FLV_DECODER (flv), NULL);
g_return_val_if_fail (flv->audio != NULL, NULL);
+ if (flv->audio->len == 0) {
+ if (next_time...
2007 Feb 06
0
109 commits - configure.ac libswfdec/js libswfdec/Makefile.am libswfdec/swfdec_bits.c libswfdec/swfdec_bits.h libswfdec/swfdec_buffer.c libswfdec/swfdec_button_movie.c libswfdec/swfdec_codec_screen.c libswfdec/swfdec_color.c libswfdec/swfdec_color.h
...it a/libswfdec/swfdec_sound.h b/libswfdec/swfdec_sound.h
index 7bf26ec..ce837db 100644
--- a/libswfdec/swfdec_sound.h
+++ b/libswfdec/swfdec_sound.h
@@ -66,7 +66,7 @@ struct _SwfdecSound
SwfdecAudioFormat format; /* format in use */
gboolean width; /* TRUE for 16bit, FALSE for 8bit */
SwfdecAudioOut original_format; /* channel/rate information */
- unsigned int n_samples; /* total number of samples */
+ unsigned int n_samples; /* total number of samples when decoded to 44100kHz */
unsigned int skip; /* samples to skip at start */
SwfdecBuffer * encoded; /* encoded data */...