search for: bits_per_sample

Displaying 20 results from an estimated 32 matches for "bits_per_sample".

2006 Apr 01
1
debugging the bits_per_sample and channels metadata in FLAC
...I compile the FLAC libraries in debug mode on ARMV4 (ported) and it works fine I compile the FLAC libraries in release mode on ARMV4 (ported) and no FLAC files play >From what I can see, in metadata_callback, I get different values for channel and bitsperssample metadata->data.stream_info.bits_per_sample is 16 in debug mode, 1072 in release mode metadata->data.stream_info.channels is 2 in debug mode, 34 in release mode I'm using FLAC CVS, but reproduced this in FLAC 1.1 and FLAC 1.2 I also tried several different .flac files For the port, I don't really touch much of the FLAC code so I...
2018 Mar 22
2
Crash when writing 32bit flac files, am I doing something wrong ?
Hello, I manage to successfully write 8, 16 and 24 bit, all stereo, FLAC files. But when I try to write 32 bit FLACs my program crashes. *FLAC__stream_encoder_set_bits_per_sample *is called to match the desired bit depth (8, 16, 24, 32) It's the same code for all bit depths, i provide a fixed-size signed int buffer to the lib (size=16384), with values with appropriate ranges for each bit depth (-128...+127 for 8 bit, etc.). The crash happens in stream_encoder.c line 2...
2004 Sep 10
2
getting framesize in client
...y_file(char *filename) { FILE *f; - gchar *ret; wide_samples_in_reservoir_ = 0; audio_error_ = false; @@ -219,10 +223,8 @@ return; } - ret = flac_format_song_title(filename); - flac_ip.set_info(ret, file_info_.length_in_msec, file_info_.sample_rate * file_info_.channels * file_info_.bits_per_sample, file_info_.sample_rate, file_info_.channels); - - g_free(ret); + file_info_.title = flac_format_song_title(filename); + flac_ip.set_info(file_info_.title, file_info_.length_in_msec, file_info_.sample_rate * file_info_.channels * file_info_.bits_per_sample, file_info_.sample_rate, file_info_.channe...
2004 Sep 10
5
[st.n@gmx.net: Bug#200435: xmms-flac: doesn't properly support long files]
severity 200435 normal thanks I received this bug report from a Debian user. I can't think of any reason offhand why the command line tool would work while the xmms plugin would fail. ----- Forwarded message from Stephan Niemz <st.n@gmx.net> ----- Date: Tue, 8 Jul 2003 10:24:57 +0200 From: Stephan Niemz <st.n@gmx.net> Resent-From: Stephan Niemz <st.n@gmx.net> To: Debian
2004 Sep 10
0
getting framesize in client
...y_file(char *filename) { FILE *f; - gchar *ret; wide_samples_in_reservoir_ = 0; audio_error_ = false; @@ -219,10 +223,8 @@ return; } - ret = flac_format_song_title(filename); - flac_ip.set_info(ret, file_info_.length_in_msec, file_info_.sample_rate * file_info_.channels * file_info_.bits_per_sample, file_info_.sample_rate, file_info_.channels); - - g_free(ret); + file_info_.title = flac_format_song_title(filename); + flac_ip.set_info(file_info_.title, file_info_.length_in_msec, file_info_.sample_rate * file_info_.channels * file_info_.bits_per_sample, file_info_.sample_rate, file_info_.channe...
2012 Apr 05
2
[PATCH 2/2] V2: Use a single definition of MIN and MAX in sources
...gth calculation is off by default. The simple * (and fast) estimation (of how many bits a residual value will be * encoded with) in this encoder is very good, almost always yielding @@ -691,7 +682,7 @@ static FLAC__StreamEncoderInitStatus init_stream_internal_( if(encoder->protected_->bits_per_sample < 16) { /* @@@ need some data about how to set this here w.r.t. blocksize and sample rate */ /* @@@ until then we'll make a guess */ - encoder->protected_->qlp_coeff_precision = max(FLAC__MIN_QLP_COEFF_PRECISION, 2 + encoder->protected_->bits_per_sample / 2); + encode...
2004 Sep 10
2
xmms plugin, fileinfo
...= ""; +#include <gtk/gtk.h> - if(!FLAC__metadata_get_streaminfo(filename, &streaminfo)) { - return FALSE; - } - - tmp_file_info->sample_rate = streaminfo.data.stream_info.sample_rate; - tmp_file_info->channels = streaminfo.data.stream_info.channels; - tmp_file_info->bits_per_sample = streaminfo.data.stream_info.bits_per_sample; - tmp_file_info->total_samples = streaminfo.data.stream_info.total_samples; - - tmp_file_info->length_in_msec = streaminfo.data.stream_info.total_samples * 10 / (streaminfo.data.stream_info.sample_rate / 100); - - return TRUE; -} +#include "...
2005 Oct 25
1
Re: Reg. FLAC decoding
...et, just x86 and ppc. but > yes, FLAC__lpc_restore_signal() will give the most bang for the > buck and is the easiest (it's just a multiply-accumulate-shift > loop). Aw., I dont think I can look into this right now. However, I have some doubts. Is it possible for the frame->header.bits_per_sample, frame->header.sample_rate to differ from frame to frame?? -- Joe Steeve (http://www.joesteeve.org/) Z500 Development team (http://www.z500series.com/) Terminus Graphics Studios http://www.terminus.in/
2014 Jun 19
1
stream_encoder: 32 vs 64 bit accumulator
...g comment is inside src/libFLAC/include/private/fixed.h: "The _wide() version uses 64-bit integers which is statistically necessary when bits-per-sample + log2(blocksize) > 30" I mean the word "statistically". libFLAC uses FLAC__fixed_compute_best_predictor_wide() if "bits_per_sample + FLAC__bitmath_ilog2(blocksize)+1 > 30" is true (see encoder->private_->use_wide_by_block variable in stream_encoder.c)
2018 Mar 24
0
Crash when writing 32bit flac files, am I doing something wrong ?
On Thu, Mar 22, 2018 at 3:41 AM, Stéphane Damo <stephane.damo at gmail.com> wrote: > Hello, > > I manage to successfully write 8, 16 and 24 bit, all stereo, FLAC files. But > when I try to write 32 bit FLACs my program crashes. > > FLAC__stream_encoder_set_bits_per_sample is called to match the desired bit > depth (8, 16, 24, 32) > > It's the same code for all bit depths, i provide a fixed-size signed int > buffer to the lib (size=16384), with values with appropriate ranges for each > bit depth (-128...+127 for 8 bit, etc.). > > The crash ha...
2011 Sep 26
1
mid-side coding and bits per sample
...gt;protected_->blocksize); encoder->private_->subframe_workspace_mid_side[channel][0].wasted_bits = encoder->private_->subframe_workspace_mid_side[channel][1].wasted_bits = w; encoder->private_->subframe_bps_mid_side[channel] = encoder->protected_->bits_per_sample - w + (channel==0? 0:1); } } ++++++++++++++++++++++++ In that piece of code the encoder determines how many wasted bits there are in each channel (mid-side) and calculates effective BPS for each of them. What i don't understand is why it should add one bit to the BPS of the side ch...
2004 Sep 10
0
http streaming in the xmms plugin
..._info() { *************** *** 136,141 **** --- 176,206 ---- return &flac_ip; } + void set_track_info(const char* title, int length_in_msec) + { + if (file_info_.is_playing) { + flac_ip.set_info((char*) title, length_in_msec, file_info_.sample_rate * file_info_.channels * file_info_.bits_per_sample, file_info_.sample_rate, file_info_.channels); + } + } + + static gchar* homedir() + { + gchar *result; + char *env_home = getenv("HOME"); + if (env_home) { + result = g_strdup (env_home); + } else { + uid_t uid = getuid(); + struct passwd *pwent; + do { + pwent = getpwen...
2005 Sep 30
0
Re: Reg. FLAC decoding
...char *)buffer[0]; short * TempSource = (short *)&LChannel[LPos]; etc. also, it's probably faster and safer to get the #channels, bits-per-sample, and sample rate from the the frame header itself, e.g. channels = frame->header.channels sample_rate = frame->header.sample_rate bits_per_sample = frame->header.bits_per_sample c.f. http://flac.sourceforge.net/api/structFLAC____FrameHeader.html let me know if this works or if you have other questions. Josh --- Joe Steeve <joesteeve@zodiactorp.com> wrote: > > I'm using seekable_stream_decoder, And., this is my write...
2004 Sep 10
3
[st.n@gmx.net: Bug#200435: xmms-flac: doesn't properly support long files]
...d line tool would work while the xmms plugin would > > fail. > ... > > It's an overflow, this patch will fix it. > > --- plugin.c.orig 2003-05-20 21:57:04.000000000 +0200 > +++ plugin.c 2003-07-08 22:03:37.000000000 +0200 > @@ -537,7 +537,7 @@ > file_info->bits_per_sample = metadata->data.stream_info.bits_per_sample; > file_info->channels = metadata->data.stream_info.channels; > file_info->sample_rate = metadata->data.stream_info.sample_rate; > - file_info->length_in_msec = file_info->total_samples * 10 / (file_info->sample_ra...
2010 Jun 28
1
ACE does not work for me at all.
Hello, all. 1) ACE does not work for me I am in a voip project using Speex, failed to have hte Speex ACE work. here is how I initialize it: /** * Configurations : * #define BITS_PER_SAMPLE (16) * #define SAMPLE_RATE (8000) * #define CHANNEL_NB (1) * #define DURATION (20) * SPEEX_MODEID_NB */ _eco_state = speex_echo_state_init(_encframe_size, 10*_encframe_size); speex_echo_ctl(_eco_state, SPEEX_ECHO_SET_SAMPLING_RATE, &_sample_rate); _den_state = speex_preprocess_state_init(_encf...
2004 Sep 10
3
getting framesize in client
On Fri, Nov 08, 2002 at 12:39:52PM -0800, Josh Coalson wrote: > --- Miroslav Lichvar <lichvarm@phoenix.inf.upol.cz> wrote: > > I have few notes: > > > > It seems there is changed API in CVS again. So, what about adding > > function like > > unsigned FLAC__format_frame_size(const FLAC__Frame *frame) > > which returns size of the frame in bytes. This
2005 Sep 30
2
Reg. FLAC decoding
...pThis = (AFLACStreamPlayer *)client_data; /* Query the m_AppPlayerPipe and check for commands from it. Act * accordingly */ pThis->QueryCommand (); Channels = FLAC__seekable_stream_decoder_get_channels (pThis->m_Decoder); BitsPerSample = FLAC__seekable_stream_decoder_get_bits_per_sample (pThis->m_Decoder); pThis->m_AudioSettings.PcmCdaParams.BitsPerSample = BitsPerSample; pThis->m_AudioSettings.PcmCdaParams.SamplingFrequency = FLAC__seekable_stream_decoder_get_sample_rate (pThis->m_Decoder); pThis->ApplyAudioDecoderSettingsOnTheFly (); unsigne...
2017 Jan 19
4
[PATCH] Fix cppcheck warnings
...else { /*@@@ need some error here like wa2: MessageBox(mod_.hMainWindow, "ERROR: plugin can only handle 8/16-bit samples\n", "ERROR: plugin can only handle 8/16-bit samples", 0); */ - fprintf(stderr, "libxmms-flac: can't handle %d bit output\n", stream_data_.bits_per_sample); + fprintf(stderr, "libxmms-flac: can't handle %u bit output\n", stream_data_.bits_per_sample); safe_decoder_finish_(decoder_); return; } diff --git a/src/share/utf8/charset.c b/src/share/utf8/charset.c index 432e32d..0c2d1ee 100644 --- a/src/share/utf8/charset.c +++ b/s...
2014 Mar 08
2
16 bits FLAC file data to 32 bit float buffer for CPU processing
Hello. I create FLAC file decoding, processing and playing program and have the following question : how to convert FLAC 16 bit file data to 32 bit float buffer for CPU processing? I've already inplemented sound playing and tested it with sine wave - it works without problems; I even made writing into decoding buffer values of sine wave, instead of decoded FLAC file data, and it also works
2005 Oct 25
2
Re: Reg. FLAC decoding
Sorry for the delay in getting back to you., I was working on something else and just now got FLAC to work. Ok., FLAC files are playing now :) Cheers. There is a slight noise happening in the background., which i'm figuring out. I hope that it'll be solved soon. However, i wanted to know if there are any ARM specific optimizations that can be done. The processor is a 166MHz processor. Do