jsoto
5th September 2004, 22:17
In
http://dvd.sourceforge.net/dvdinfo/dsi_pkt.html
you can read
Sector: 5a9 sp_synca[0:31] length: 32*4
relative offset to 1st subpicture packet for this VOBU
the msb (bit 31) is used to denote the direction, 0=forward, 1=backward
00 00 00 00 indicates the subpicture does not exist
3f ff ff ff indicates no subpicture data for this VOBU
7f ff ff ff indicates the subpicture data is contained within this VOBU
But, I believe these pointers are different from audio ones. In this case, the relative offset is between this VOBU and the VOBU (nav pack) which has the subpicture packet.
Can anyone confirm this?
This is the related part of dvdauthor code, where these pointers are adjusted
for( j=0; j<va->numsubpicturetracks; j++ ) {
struct audchannel *ach=&p->audch[j|32];
int s;
if( ach->numaudpts ) {
int id=findspuidx(p,j|32,vi->sectpts[0]);
// if overlaps A, point to A
// else if (A before here or doesn't exist) and (B after here or doesn't exist), point to here
// else point to B
if( id>=0 &&
ach->audpts[id].pts[0]<vi->sectpts[1] &&
ach->audpts[id].pts[1]>=vi->sectpts[0] )
s=findvobubysect(p,ach->audpts[id].sect);
else if( (id<0 || ach->audpts[id].pts[1]<vi->sectpts[0]) &&
(id+1==ach->numaudpts || ach->audpts[id+1].pts[0]>=vi->sectpts[1]) )
s=i;
else
s=findvobubysect(p,ach->audpts[id+1].sect);
id=(s<i);
s=getsect(p,i,s,0,0x7fffffff)&0x7fffffff;
if(!s)
s=0x7fffffff;
if(s!=0x7fffffff && id)
s|=0x80000000;
} else
s=0;
write4(buf+0x5a9+j*4,s);
}
Can anyone explain me what is 'A' and 'B' in the comment?
And, is there a way to adjust them without calculate the pts1 (end of picture presentation time) value?
jsoto
http://dvd.sourceforge.net/dvdinfo/dsi_pkt.html
you can read
Sector: 5a9 sp_synca[0:31] length: 32*4
relative offset to 1st subpicture packet for this VOBU
the msb (bit 31) is used to denote the direction, 0=forward, 1=backward
00 00 00 00 indicates the subpicture does not exist
3f ff ff ff indicates no subpicture data for this VOBU
7f ff ff ff indicates the subpicture data is contained within this VOBU
But, I believe these pointers are different from audio ones. In this case, the relative offset is between this VOBU and the VOBU (nav pack) which has the subpicture packet.
Can anyone confirm this?
This is the related part of dvdauthor code, where these pointers are adjusted
for( j=0; j<va->numsubpicturetracks; j++ ) {
struct audchannel *ach=&p->audch[j|32];
int s;
if( ach->numaudpts ) {
int id=findspuidx(p,j|32,vi->sectpts[0]);
// if overlaps A, point to A
// else if (A before here or doesn't exist) and (B after here or doesn't exist), point to here
// else point to B
if( id>=0 &&
ach->audpts[id].pts[0]<vi->sectpts[1] &&
ach->audpts[id].pts[1]>=vi->sectpts[0] )
s=findvobubysect(p,ach->audpts[id].sect);
else if( (id<0 || ach->audpts[id].pts[1]<vi->sectpts[0]) &&
(id+1==ach->numaudpts || ach->audpts[id+1].pts[0]>=vi->sectpts[1]) )
s=i;
else
s=findvobubysect(p,ach->audpts[id+1].sect);
id=(s<i);
s=getsect(p,i,s,0,0x7fffffff)&0x7fffffff;
if(!s)
s=0x7fffffff;
if(s!=0x7fffffff && id)
s|=0x80000000;
} else
s=0;
write4(buf+0x5a9+j*4,s);
}
Can anyone explain me what is 'A' and 'B' in the comment?
And, is there a way to adjust them without calculate the pts1 (end of picture presentation time) value?
jsoto