# HG changeset patch # User romansh # Date 1223394585 0 # Node ID 9709530b68b55b122628be54ad4b1418642bd25e # Parent 8b2c1cfecd949ab7172838654aabda400c3d9fad simplifying the code as per Michael's suggestion diff -r 8b2c1cfecd94 -r 9709530b68b5 dv.c --- a/dv.c Sat Oct 04 23:30:35 2008 +0000 +++ b/dv.c Tue Oct 07 15:49:45 2008 +0000 @@ -122,7 +122,7 @@ half_ch = sys->difseg_size/2; /* We work with 720p frames split in half, thus even frames have channels 0,1 and odd 2,3 */ - ipcm = (sys->height == 720 && ((frame[1]>>2)&0x3) == 0)?2:0; + ipcm = (sys->height == 720 && !(frame[1]&0x0C))?2:0; pcm = ppcm[ipcm++]; /* for each DIF channel */ @@ -339,7 +339,7 @@ /* We work with 720p frames split in half, thus even frames have channels 0,1 and odd 2,3 */ if (c->sys->height == 720) { - if (((buf[1]>>2)&0x3)) + if (buf[1]&0x0C) c->audio_pkt[2].size = c->audio_pkt[3].size = 0; else c->audio_pkt[0].size = c->audio_pkt[1].size = 0;