Displaying 3 results from an estimated 3 matches for "set_total_samples_estimate".
2011 Sep 28
0
FLAC::Encoder::Stream == "FLAC__STREAM_ENCODER_VERIFY_MISMATCH_IN_AUDIO_DATA"
...ok &= enc.set_channels ( 2); // 2 channels
ok &= enc.set_bits_per_sample( 16); // 16 bits
ok &= enc.set_sample_rate (44100); // 44.100 Hz
ok &= enc.set_compression_level((FCompressionStrength > 8) ? 8 :
FCompressionStrength);
ok &= enc.set_total_samples_estimate(total_samples);
enc.setOutFile(&file);
/* initialize encoder */
init_status = enc.init();
if( (!ok) || (init_status != FLAC__STREAM_ENCODER_INIT_STATUS_OK)) {
return false;
}
/* read sectors from disc and feed to encoder */
for (unsigned int i = 0; i &l...
2006 Sep 07
2
Getting subframe type=verbatim on 16 bit files
...{
for(channel = 0; channel < numChannels; channel++, sample++)
{
flacBuffer[channel][sample32] =
(uint32_t)(uint16_t)buffer16[sample];
}
}
break;
..........
}
set_total_samples_estimate (numFrames); // note we are doing this
before the init function is called!
return true;
}
On 9/6/06 8:28 PM, "Josh Coalson" <xflac@yahoo.com> wrote:
> looks fine, I would suspect how the PCM sample are formatted
> and sent to process(), could you show that part of the...
2006 Sep 06
2
Getting subframe type=verbatim on 16 bit files
I'm using libFLACC++ and libFLAC and I think that I'm using the calls in the
typical order (see code below). But every monoe or stereo file that I send
thru I get files that are the same sze as the orginal wave files.
Doing a flac -a on the flac files I see that I get:
frame=9 blocksize=4608 sample_rate=8000 channels=1
channel_assignment=INDEPENDENT
subframe=0