<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /></head><body style='font-size: 10pt; font-family: Verdana,Geneva,sans-serif'>
<p>I am trying to encode a stream to FLAC and want the encoder to create a SEEKTABLE but I cannot get it to work as the table always contains only place holder points. All other aspects of the produced FLAC file seem OK. </p>
<p>In order to eliminate anything in our system I modified the encoder sample code from the website and it behaves the same which make me think I'm missing something. </p>
<p>I changed the section where the meta data is added to the encoder to add a seek table block. </p>
<p><span style="font-family: 'courier new', courier, monospace;"> (metadata[2] = FLAC__metadata_object_new(FLAC__METADATA_TYPE_SEEKTABLE)) == NULL ||</span><br /><span style="font-family: 'courier new', courier, monospace;"> !FLAC__metadata_object_seektable_template_append_placeholders(metadata[2],16) ||</span></p>
<p><span style="font-family: 'courier new', courier, monospace;"> ...</span></p>
<p><span style="font-family: 'courier new', courier, monospace;"></span><span style="font-family: 'courier new', courier, monospace;"> ok = FLAC__stream_encoder_set_metadata(encoder, metadata, 3);</span></p>
<p>I don't really understand the details of the seek table but my thinking here is that I am giving the encoder a template to populate up to 16 seek points. The documentation says the encoder will modify the seek table block during encoding but the passed meta block (which I retain ownbership of) still contains only place holders at the end of the encoding. The seek table block is written to the file but has only placeholder points.</p>
<p>What am I missing?</p>
<p>Thanks. </p>
<p> </p>
<p> </p>
<p> </p>
<div> </div>
</body></html>