AVI file plays perfectly and no problem is reported by other programs like VDUB and GSPOT.
Investigating the problem, it seems that VLC bases its "broken index" check on comparing the video header length and the index-length. Because the first calculation is more unprecise that the second it causes "the broken index" message - a bit misleading - the index is fine.
example:
video 1 (orginal)
--------------------
total frames = 41958
microsecperframe = 33367
length = 1400012586 uS, or 1400,012586 s
stream-index:
total frames = 41958
rate = 30000dec
scale = 000003E9H ()
length = 41958*1000000 * 3E9 / 30000 = 1399998600
in seconds 1399,998600
truncated 1400 in the first case and 1399 in the second case. , VLC player therefore wrongly reports "broken index"
video 2 (last video frame editted out)
---------------------------------------------
hdr:
total frames = 41957
microsecperframe = 33367
length = 1399979219 uS, or 1399,979219 s
stream-index:
total frames = 41957
rate = 30000dec
scale = 000003E9H ()
length = 41957*1000000 * 3E9 / 30000 = 1399965233,3333333333333333333333
in seconds 1399,9652333333333333333333333333
truncated 1399 in both cases
Now VLC accepts the video and its index.
A proper index-check should check whether the index matches the actual frames.
/MSJ