<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=iso-8859-1"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
{font-family:Helvetica;
panose-1:2 11 6 4 2 2 2 2 2 4;}
@font-face
{font-family:Helvetica;
panose-1:2 11 6 4 2 2 2 2 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Tahoma;
panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
span.apple-style-span
{mso-style-name:apple-style-span;}
span.EmailStyle18
{mso-style-type:personal-reply;
font-family:"Arial","sans-serif";
color:#1F497D;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:70.85pt 70.85pt 70.85pt 70.85pt;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=FR link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> Hi Ross,<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'>Surely I badly use the matroska parser…<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'>What I was trying to do is to connect each matroska subsession to a sink. In fact I don’t need ServerMediaSession, it is just to get the FramedSource corresponding to a subsession.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'>The following code seem to works with some mkv but produce an overflow of BANK_SIZE with the file I send previously<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'>#include "liveMedia.hh"<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'>#include "BasicUsageEnvironment.hh"<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'>static char newMatroskaDemuxWatchVariable;<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'>static MatroskaFileServerDemux* demux;<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'>static void onMatroskaDemuxCreation(MatroskaFileServerDemux* newDemux, void* /*clientData*/) {<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> demux = newDemux;<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> newMatroskaDemuxWatchVariable = 1;<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'>}<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'>int main(int argc, char** argv) {<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> TaskScheduler* scheduler = BasicTaskScheduler::createNew();<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> UsageEnvironment* env = BasicUsageEnvironment::createNew(*scheduler);<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> // A Matroska ('.mkv') file, with video+audio+subtitle streams:<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> {<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> char const* inputFileName = "test.mkv";<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> ServerMediaSession* sms = ServerMediaSession::createNew(*env, inputFileName, inputFileName,inputFileName);<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> newMatroskaDemuxWatchVariable = 0;<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> MatroskaFileServerDemux::createNew(*env, inputFileName, onMatroskaDemuxCreation, NULL);<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> env->taskScheduler().doEventLoop(&newMatroskaDemuxWatchVariable);<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> ServerMediaSubsession* smss = NULL;<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> unsigned fileSinkBufferSize = 100000; <o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> while ((smss = demux->newServerMediaSubsession()) != NULL) {<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> sms->addSubsession(smss);<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> MediaSource* source = demux->newDemuxedTrack(0,smss->trackNumber()); <o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> MediaSink* sink = FileSink::createNew(*env, smss->trackId(),fileSinkBufferSize, False);<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> sink->startPlaying(*source,NULL,NULL); <o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span lang=EN-US style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> </span><span style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'>}<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> }<o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> env->taskScheduler().doEventLoop(); <o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> return 0; <o:p></o:p></span></p><p class=MsoNormal style='margin-left:35.4pt'><span style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'>}<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'>Thanks for your help.<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'> Michel.<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'><o:p> </o:p></span></p><div><div><div><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>[@@ THALES GROUP INTERNAL @@]<o:p></o:p></span></p></div></div></div><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Arial","sans-serif";color:#1F497D'><o:p> </o:p></span></p><div><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm'><p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>De :</span></b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> live-devel-bounces@ns.live555.com [mailto:live-devel-bounces@ns.live555.com] <b>De la part de</b> Ross Finlayson<br><b>Envoyé :</b> lundi 4 novembre 2013 18:26<br><b>À :</b> LIVE555 Streaming Media - development & use<br><b>Objet :</b> Re: [Live-devel] Matroska BANK_SIZE overflow<o:p></o:p></span></p></div></div><p class=MsoNormal><o:p> </o:p></p><div><p class=MsoNormal>Adding a missing word to my previous answer:<o:p></o:p></p></div><div><p class=MsoNormal><br><br><o:p></o:p></p><div><div><p class=MsoNormal>How are you parsing/demultiplexing this Matroska file? Are you using your own application (that presumably uses the API in "liveMedia/include/MatroskaFile.hh")? If so, then please [provide] the code for a simple application (as simple as you can make it) that reproduces this problem when parsing/demultiplexing this Matroska file.<o:p></o:p></p></div></div></div><p class=MsoNormal style='margin-bottom:12.0pt'><o:p> </o:p></p><div><p class=MsoNormal><span class=apple-style-span><span style='font-family:"Helvetica","sans-serif";color:black'>Ross Finlayson</span></span><span style='font-family:"Helvetica","sans-serif";color:black'><br><span class=apple-style-span>Live Networks, Inc.</span><br><span class=apple-style-span><a href="http://www.live555.com/">http://www.live555.com/</a></span></span> <o:p></o:p></p></div><p class=MsoNormal><o:p> </o:p></p></div></body></html>