search for: audio_chunk_size

Displaying 3 results from an estimated 3 matches for "audio_chunk_size".

2015 Jun 14
2
Sound glitch when using libvorbisfile and libao
Hi Gunter, I think this problem started happening when I upgraded from Debian Wheezy to Debian Jessie. If nothing looks amiss in my code, it probably is a sound driver problem. But since it works 100% of the time in ogg123, I feel I must have missed some corner case. My audio driver is almost always active. I usually have my music player going in the background when I do my testing. The problem
2015 Jun 27
0
Sound glitch when using libvorbisfile and libao
...gured it out. What I needed to do was fill the buffer with more data before handing it off to ao_play. It requires lots of bookkeeping, pointer arithmetic, and a sufficiently large buffer. First, the bigger buffer. I just pulled this code from ogg123: #define PRIMAGIC (2*2*2*2*3*3*3*5*7) #define AUDIO_CHUNK_SIZE ((16384 + PRIMAGIC - 1)/ PRIMAGIC * PRIMAGIC) char convbuffer[AUDIO_CHUNK_SIZE]; const int convsize = AUDIO_CHUNK_SIZE; The loop is now more convoluted. Here's the old one, for reference: long bytes_read = 0; do { bytes_read = decode_vorbisfile(&vf); ao_play(device, pcmout, bytes_...
2002 Oct 05
2
ogg123 remote interface
...6 21:12:18 2002 +++ ogg123/ogg123.c Sat Oct 5 14:22:06 2002 @@ -48,19 +48,12 @@ void exit_cleanup (); -void play (char *source_string); +void play (audio_play_arg_t *audio_play_arg, buf_t *audio_buffer, char *source_string); -/* take buffer out of the data segment, not the stack */ -#define AUDIO_CHUNK_SIZE 4096 unsigned char convbuffer[AUDIO_CHUNK_SIZE]; int convsize = AUDIO_CHUNK_SIZE; - ogg123_options_t options; -stat_format_t *stat_format; -buf_t *audio_buffer; - -audio_play_arg_t audio_play_arg; - +buf_t *audio_buffer_to_cleanup = NULL; /* ------------------------- config file options -----...