search for: n_sampl

Displaying 20 results from an estimated 33 matches for "n_sampl".

Did you mean: n_sample
2007 Oct 11
0
12 commits - configure.ac doc/Makefile.am libswfdec/swfdec_as_frame.c libswfdec/swfdec_audio.c libswfdec/swfdec_audio_event.c libswfdec/swfdec_audio_event.h libswfdec/swfdec_shape_parser.c libswfdec/swfdec_sound.c test/sound
...007 +0200 add deug message diff --git a/libswfdec/swfdec_audio_event.c b/libswfdec/swfdec_audio_event.c index a82182d..8520bf9 100644 --- a/libswfdec/swfdec_audio_event.c +++ b/libswfdec/swfdec_audio_event.c @@ -154,6 +154,7 @@ swfdec_audio_event_decode (SwfdecAudioEv } } event->n_samples = event->decoded->length / bytes_per_sample * granule; + SWFDEC_LOG ("total 44100Hz samples: %u", event->n_samples); } static SwfdecAudioEvent * diff-tree 40854374b86f321fb816ce505f2ef170f59dfaf1 (from 9a75550335d3a4ea2276c7573634d12a81fc030b) Author: Benjamin Otte <ott...
2008 Jan 09
0
libswfdec/swfdec_audio_event.c libswfdec/swfdec_bits.c libswfdec/swfdec_sound.c libswfdec/swfdec_sprite.c libswfdec/swfdec_swf_decoder.c
...nd.c +++ b/libswfdec/swfdec_sound.c @@ -105,7 +105,7 @@ tag_func_sound_stream_block (SwfdecSwfDecoder * s, guint tag) SWFDEC_ERROR ("empty sound chunk"); return SWFDEC_STATUS_OK; } - SWFDEC_LOG ("got a buffer with %u samples, %d skip and %u bytes mp3 data", n_samples, skip, + SWFDEC_LOG ("got a buffer with %u samples, %d skip and %"G_GSIZE_FORMAT" bytes mp3 data", n_samples, skip, chunk->length); /* use this to write out the stream data to stdout - nice way to get an mp3 file :) */ //write (1, (void *) chunk->data, chu...
2018 Feb 26
2
glm package - Negative binomial regression model - Error
...no problems with running the model with a set of data, but now that i'm trying to run if for new one. I always have this same error when running the regression: > > #Run Regression > x=cbind(factor2ind(d$year),factor2ind(d$month_week)) > > out<- glm(cbind(influenza, n_sample) ~ x, family=quasibinomial, > data=d) > > d$prop<-out$fitted.values Error in `$<-.data.frame`(`*tmp*`, prop, value = c(0.0486530542835839, : replacement has 208 rows, data has 365 > d$n_p1<-d$prop*d$factor*10 > > obs<-aggregate(d$prop, by = list(d$mon...
2018 Feb 26
0
glm package - Negative binomial regression model - Error
...h a set of data, but now that > i'm trying to run if for new one. I always have this same error when > running the regression: > > > > > #Run Regression > > x=cbind(factor2ind(d$year),factor2ind(d$month_week)) > > > > out<- glm(cbind(influenza, n_sample) ~ x, family=quasibinomial, > > data=d) > > > > d$prop<-out$fitted.values > > Error in `$<-.data.frame`(`*tmp*`, prop, value = c(0.0486530542835839, : > replacement has 208 rows, data has 365 > > > d$n_p1<-d$prop*d$factor*10 > > > &g...
2013 Apr 19
1
How to read a direct access file by connecting fortran with R ?
...********* II) R CMD SHLIB read_binary.f90 III) dyn.load("read_libray.so") IV) Then in R, I tried many variant of the following function but I wasn't able to store the line number row into the vector img ************************************ img<-c(n_col) Read_binary<-function(n_samples,line,type) { as.integer(n_samples), as.intger(line), as.integer(typ), img=as.single(img) } ************************************ Could anyone tell me what I'm doing wrong? I'm a beginner in R and my guess is that I'm missing something into the above R function. Cheers Ar...
2007 Oct 28
0
9 commits - configure.ac libswfdec/swfdec_as_context.c libswfdec/swfdec_audio_internal.h libswfdec/swfdec_codec_audio.c libswfdec/swfdec_codec_gst.c libswfdec/swfdec_sound.c
...SwfdecSound *sound, SwfdecAudioFormat *format) tmp = swfdec_buffer_queue_pull (queue, depth); swfdec_buffer_queue_unref (queue); - sound->decoded_format = swfdec_audio_decoder_get_format (decoder); sample_bytes = swfdec_audio_format_get_bytes_per_sample (sound->decoded_format); n_samples = sound->n_samples / swfdec_audio_format_get_granularity (sound->decoded_format); commit 43c2c77acd07323c9fe8d395ec58b782222f2a70 Author: Benjamin Otte <otte at gnome.org> Date: Sun Oct 28 21:58:33 2007 +0100 make sure the sound format only gets requested after decoding diff...
2009 Aug 27
1
standard error associated with correlation coefficient
I want the standard error associated with a correlation. I can calculate using cor & var, but am wondering if there are libraries that already provide this function. [[alternative HTML version deleted]]
2007 Oct 29
0
2 commits - libswfdec/swfdec_audio_event.c test/sound
.../libswfdec/swfdec_audio_event.c b/libswfdec/swfdec_audio_event.c index 8520bf9..e0e5e93 100644 --- a/libswfdec/swfdec_audio_event.c +++ b/libswfdec/swfdec_audio_event.c @@ -59,6 +59,9 @@ swfdec_audio_event_render (SwfdecAudio *audio, gint16* dest, guint loop; guint samples; + if (event->n_samples == 0) + return; + loop = event->loop + offset / event->n_samples; offset %= event->n_samples; for (; loop < event->n_loops && n_samples > 0; loop++) {
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
...dec_sound_get_decoder_format (sound, decoder); + sound->decoded_format = swfdec_audio_codec_get_format (codec, decoder); sample_bytes = 2 * SWFDEC_AUDIO_OUT_N_CHANNELS (sound->decoded_format); /* FIXME: The size is only a guess */ swfdec_cached_load (SWFDEC_CACHED (sound), sound->n_samples * sample_bytes); - tmp = swfdec_sound_decode_buffer (sound, decoder, sound->encoded); - tmp2 = swfdec_sound_finish_decoder (sound, decoder); + tmp = swfdec_audio_codec_decode (codec, decoder, sound->encoded); + tmp2 = swfdec_audio_codec_finish (codec, decoder); if (tmp == NULL) {...
2007 Nov 10
6
[Bug 13167] New: crash firefox if you close tab while playing flash files
http://bugs.freedesktop.org/show_bug.cgi?id=13167 Summary: crash firefox if you close tab while playing flash files Product: swfdec Version: unspecified Platform: Other OS/Version: All Status: NEW Severity: normal Priority: medium Component: library AssignedTo: swfdec at lists.freedesktop.org
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
...@ -435,8 +435,8 @@ tag_func_start_sound (SwfdecSwfDecoder * int tag_func_define_button_sound (SwfdecSwfDecoder * s) { - unsigned int i; - unsigned int id; + guint i; + guint id; SwfdecButton *button; id = swfdec_bits_get_u16 (&s->b); @@ -500,7 +500,7 @@ swfdec_sound_buffer_get_n_samples (const void swfdec_sound_buffer_render (gint16 *dest, const SwfdecBuffer *source, SwfdecAudioOut format, const SwfdecBuffer *previous, - unsigned int offset, unsigned int n_samples) + guint offset, guint n_samples) { guint i, j; guint channels = SWFDEC_AUDIO_OUT_N_CHANNELS (...
2007 Dec 10
0
5 commits - libswfdec/jpeg libswfdec/swfdec_as_interpret.c libswfdec/swfdec_bits.c libswfdec/swfdec_cached.c libswfdec/swfdec_codec_adpcm.c libswfdec/swfdec_codec_audio.c libswfdec/swfdec_flash_security.c libswfdec/swfdec_image.c
...dffe212..ef0641e 100644 --- a/libswfdec/swfdec_sound.c +++ b/libswfdec/swfdec_sound.c @@ -549,9 +549,9 @@ swfdec_sound_buffer_render (gint16 *dest, const SwfdecBuffer *source, } } if (channels == 2) { - swfdec_sound_buffer_render_stereo (dest, (const gint16 *) source->data, offset, n_samples, rate); + swfdec_sound_buffer_render_stereo (dest, (const void *) source->data, offset, n_samples, rate); } else { - swfdec_sound_buffer_render_mono (dest, (const gint16 *) source->data, offset, n_samples, rate); + swfdec_sound_buffer_render_mono (dest, (const void *) source-&gt...
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
...@ -435,8 +435,8 @@ tag_func_start_sound (SwfdecSwfDecoder * int tag_func_define_button_sound (SwfdecSwfDecoder * s) { - unsigned int i; - unsigned int id; + guint i; + guint id; SwfdecButton *button; id = swfdec_bits_get_u16 (&s->b); @@ -500,7 +500,7 @@ swfdec_sound_buffer_get_n_samples (const void swfdec_sound_buffer_render (gint16 *dest, const SwfdecBuffer *source, SwfdecAudioOut format, const SwfdecBuffer *previous, - unsigned int offset, unsigned int n_samples) + guint offset, guint n_samples) { guint i, j; guint channels = SWFDEC_AUDIO_OUT_N_CHANNELS (...
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
...+ buffer = swfdec_audio_decoder_pull (flv->decoder); } - g_assert (buffer); g_queue_push_tail (flv->playback_queue, buffer); return buffer; } @@ -144,7 +136,8 @@ swfdec_audio_flv_render (SwfdecAudio *au if (!buffer) break; } - samples = swfdec_sound_buffer_get_n_samples (buffer, flv->out); + samples = swfdec_sound_buffer_get_n_samples (buffer, + swfdec_audio_decoder_get_format (flv->decoder)); if (start) { if (samples <= start) { start -= samples; @@ -157,7 +150,9 @@ swfdec_audio_flv_render (SwfdecAudio *au SWFDEC_LOG ("ren...
2007 Oct 30
0
libswfdec/swfdec_audio_event.c
...--- a/libswfdec/swfdec_audio_event.c +++ b/libswfdec/swfdec_audio_event.c @@ -69,7 +69,7 @@ swfdec_audio_event_render (SwfdecAudio *audio, gint16* dest, swfdec_sound_buffer_render (dest, event->decoded, event->decoded_format, loop == 0 ? NULL : event->decoded, offset, samples); n_samples -= samples; - dest += samples * 4; + dest += samples * 2; offset = 0; } }
2007 Dec 11
9
[Bug 13604] New: Assertion failure when seeking on youtube with pulseaudio backend.
http://bugs.freedesktop.org/show_bug.cgi?id=13604 Summary: Assertion failure when seeking on youtube with pulseaudio backend. Product: swfdec Version: unspecified Platform: x86-64 (AMD64) URL: http://www.youtube.com OS/Version: Linux (All) Status: NEW Severity: normal Priority:
2007 Oct 13
2
[Bug 12793] New: Crash playing a swf file (because of missing NULL ptr check)
...3d80) at swfdec_sound.c:205 205 SWFDEC_LOG ("after decoding, got %u samples, should get %u and skip %u", (gdb) p tmp $1 = (SwfdecBuffer *) 0x0 The code does : SWFDEC_LOG ("after decoding, got %u samples, should get %u and skip %u", tmp->length / sample_bytes, n_samples, sound->skip); tmp->length is the culprit. but tmp is used more and more after that so perhaps a small if (!tmp) is not enough. Attaching a link to the file once it has been uploaded -- Configure bugmail: http://bugs.freedesktop.org/userprefs.cgi?tab=email ------- You are receiving thi...
2007 Apr 17
0
Branch 'as' - 17 commits - libswfdec/jpeg libswfdec/swfdec_bits.c libswfdec/swfdec_font.c libswfdec/swfdec_image.c libswfdec/swfdec_root_sprite.c libswfdec/swfdec_script.c libswfdec/swfdec_shape.c libswfdec/swfdec_sound.c libswfdec/swfdec_sprite.c
...200 return if no data is available diff --git a/libswfdec/swfdec_sound.c b/libswfdec/swfdec_sound.c index 1087f5f..dadd400 100644 --- a/libswfdec/swfdec_sound.c +++ b/libswfdec/swfdec_sound.c @@ -98,6 +98,7 @@ tag_func_sound_stream_block (SwfdecSwfDe SWFDEC_DEBUG ("empty sound block n_samples=%d skip=%d", n_samples, skip); chunk = NULL; + return SWFDEC_STATUS_OK; } else { chunk = swfdec_bits_get_buffer (&s->b, -1); if (chunk == NULL) { diff-tree de1a29a1b62e30df5cb4a26fe192efd44db98bec (from 4ecf6f08ab585cbf8089373cb6535d5e3e3493fc) Author: Be...
2007 Oct 15
0
8 commits - libswfdec/swfdec_as_interpret.c libswfdec/swfdec_sound.c libswfdec/swfdec_sound.h test/trace
...4 --- a/libswfdec/swfdec_sound.c +++ b/libswfdec/swfdec_sound.c @@ -552,27 +552,3 @@ swfdec_sound_buffer_render (gint16 *dest, const SwfdecBuffer *source, } } -/** - * swfdec_sound_render: - * @sound: a #SwfdecSound - * @dest: target to add to - * @offset: offset in samples into the data - * @n_samples: amount of samples to render - * - * Renders the given sound onto the existing data in @dest. - **/ -void -swfdec_sound_render (SwfdecSound *sound, gint16 *dest, - guint offset, guint n_samples) -{ - SwfdecBuffer *buffer; - SwfdecAudioFormat format; - g_return_if_fail (SWFDEC_IS_SOUND (soun...
2007 Oct 14
0
4 commits - libswfdec/swfdec_as_interpret.c libswfdec/swfdec_sound.c test/trace
...a/libswfdec/swfdec_sound.c b/libswfdec/swfdec_sound.c index 7ee1660..e4e9086 100644 --- a/libswfdec/swfdec_sound.c +++ b/libswfdec/swfdec_sound.c @@ -171,6 +171,7 @@ swfdec_sound_get_decoded (SwfdecSound *sound, SwfdecAudioFormat *format) SwfdecBufferQueue *queue; guint sample_bytes; guint n_samples; + guint depth; g_return_val_if_fail (SWFDEC_IS_SOUND (sound), NULL); g_return_val_if_fail (format != NULL, NULL); @@ -199,7 +200,12 @@ swfdec_sound_get_decoded (SwfdecSound *sound, SwfdecAudioFormat *format) swfdec_buffer_queue_push (queue, tmp); } swfdec_audio_decoder_free (...