View Single Post
Old 5th May 2009, 12:41   #19  |  Link
deank
Programmer (or just 教务长)
 
deank's Avatar
 
Join Date: Oct 2008
Location: Valencia, Spain
Posts: 4,251
clark, I'd suggest you this:

Code:
50    if(memcmp(ptr,"MPLS0100",8))
51        return -1;
you can either make it ..."MPLS0",5... or check for MPLS0200, too.

and

Code:
58    unsigned char* pp=ptr+68;
60    if(pp+num*82>ptr+len)
...
72        pp+=82;
This can lead you to troubles. ptr[68] and [69] keep the length of the current segment, so it is correct to increment pp in line 72 not by 82 but with the value in 68/69.

Then for the next cycle use pp as the base for other chapter calculations.
__________________
multiAVCHD - donate | popBD | uncropMKV | mkv2avi | easySUP

Last edited by deank; 5th May 2009 at 12:47.
deank is offline   Reply With Quote