AFAIK libvlc doesn't have API function to find out about broken/missing AVI index. Log might complain something that you could try to catch. <br><br><div class="gmail_quote">2010/6/10 Mehmet Kaplan <span dir="ltr"><<a href="mailto:mehmetkpln@gmail.com">mehmetkpln@gmail.com</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">vlc input.avi --sout=#std{access=file,mux=avi,dst=output.avi} fixes the file.<br>
Last problem is how I decide avi file is broken or not?<br>
How can I find indexing is problematic?<br>
<div><div></div><div class="h5"><br>
On Thu, Jun 10, 2010 at 11:13 AM, Kaarlo Räihä <<a href="mailto:kaarlo.raiha@gmail.com">kaarlo.raiha@gmail.com</a>> wrote:<br>
> AFAIK only way to permanently fix files with (lib)VLC is to remux them, but<br>
> since VLC's AVI muxer is somewhat broken I would suggest other tools.<br>
> Anyway it would be something like<br>
> vlc input.avi --sout=#std{access=file,mux=avi,dst=output.avi}<br>
> or<br>
> vlc input.avi --sout=#std{access=file,mux=ffmpeg{mux=avi},dst=output.avi}<br>
> (I am not sure if the ffmpeg version works)<br>
><br>
> 2010/6/10 Mehmet Kaplan <<a href="mailto:mehmetkpln@gmail.com">mehmetkpln@gmail.com</a>><br>
>><br>
>> Thanks, but in that link, there is only the information that I can fix<br>
>> those files with VLC Player.<br>
>> Also I wonder how i can detect broken avi files and fix those files in<br>
>> my application using libvlc?<br>
>><br>
>><br>
>> On Wed, Jun 9, 2010 at 8:38 PM, Kaarlo Räihä <<a href="mailto:kaarlo.raiha@gmail.com">kaarlo.raiha@gmail.com</a>><br>
>> wrote:<br>
>> > The AVI file has prolly a broken index info.<br>
>> ><br>
>> > <a href="http://wiki.videolan.org/WindowsFAQ-1.0.x#Can_I_fix_those_broken_AVI_files_permanently.3F" target="_blank">http://wiki.videolan.org/WindowsFAQ-1.0.x#Can_I_fix_those_broken_AVI_files_permanently.3F</a><br>

>> ><br>
>> > 2010/6/9 Mehmet Kaplan <<a href="mailto:mehmetkpln@gmail.com">mehmetkpln@gmail.com</a>><br>
>> >><br>
>> >> Hi all,<br>
>> >> I'm developing a video player application using libvlc 1.1.0.<br>
>> >> I have an avi video file with format MJPG.<br>
>> >> libvlc_media_player_get_length function returns 1 second for the total<br>
>> >> length of video. But original length is 19 seconds.<br>
>> >> When I try to open video file with installed VLC Player (1.0.2) on my<br>
>> >> computer, program pops up following dialog:<br>
>> >><br>
>> >> *******************************************************************<br>
>> >> ---------------------------<br>
>> >> AVI Index<br>
>> >> ---------------------------<br>
>> >> This AVI file is broken. Seeking will not work correctly.<br>
>> >> Do you want to try to fix it?<br>
>> >><br>
>> >> This might take a long time.<br>
>> >> *******************************************************************<br>
>> >><br>
>> >> When I choose to fix the video file, seeking is correct and video<br>
>> >> length is shown 19 seconds on VLC Player.<br>
>> >> But when i choose not to fix, length is 1 second such as in my program.<br>
>> >> What is the problem in this avi video file, how VLC Player fixes this<br>
>> >> file and how can I do the same thing VLC Player does?<br>
>> >><br>
>> >> Thanks in advance.<br>
>> >> _______________________________________________<br>
>> >> vlc-devel mailing list<br>
>> >> To unsubscribe or modify your subscription options:<br>
>> >> <a href="http://mailman.videolan.org/listinfo/vlc-devel" target="_blank">http://mailman.videolan.org/listinfo/vlc-devel</a><br>
>> ><br>
>> ><br>
>> > _______________________________________________<br>
>> > vlc-devel mailing list<br>
>> > To unsubscribe or modify your subscription options:<br>
>> > <a href="http://mailman.videolan.org/listinfo/vlc-devel" target="_blank">http://mailman.videolan.org/listinfo/vlc-devel</a><br>
>> ><br>
>> ><br>
>> _______________________________________________<br>
>> vlc-devel mailing list<br>
>> To unsubscribe or modify your subscription options:<br>
>> <a href="http://mailman.videolan.org/listinfo/vlc-devel" target="_blank">http://mailman.videolan.org/listinfo/vlc-devel</a><br>
><br>
><br>
> _______________________________________________<br>
> vlc-devel mailing list<br>
> To unsubscribe or modify your subscription options:<br>
> <a href="http://mailman.videolan.org/listinfo/vlc-devel" target="_blank">http://mailman.videolan.org/listinfo/vlc-devel</a><br>
><br>
><br>
_______________________________________________<br>
vlc-devel mailing list<br>
To unsubscribe or modify your subscription options:<br>
<a href="http://mailman.videolan.org/listinfo/vlc-devel" target="_blank">http://mailman.videolan.org/listinfo/vlc-devel</a><br>
</div></div></blockquote></div><br>