]> git.sesse.net Git - ffmpeg/commitdiff
Factoring out chan_slice / 27 into seq variable
authorRoman Shaposhnik <roman@shaposhnik.org>
Wed, 27 Aug 2008 20:21:17 +0000 (20:21 +0000)
committerRoman Shaposhnik <roman@shaposhnik.org>
Wed, 27 Aug 2008 20:21:17 +0000 (20:21 +0000)
Originally committed as revision 14997 to svn://svn.ffmpeg.org/ffmpeg/trunk

libavcodec/dv.c

index 2322e92fc4118434e06fd5ab7bb32d67d21dea4d..b7dde76bed34de618d1392ddce89ca8c601ae3d4 100644 (file)
@@ -965,7 +965,10 @@ static int dv_decode_mt(AVCodecContext *avctx, void* sl)
     /* byte offset of this channel's data */
     int chan_offset = chan * s->sys->difseg_size * 150 * 80;
 
-    dv_decode_video_segment(s, &s->buf[((chan_slice/27)*6+(chan_slice/3)+chan_slice*5+7)*80 + chan_offset],
+    /* DIF sequence */
+    int seq = chan_slice / 27;
+
+    dv_decode_video_segment(s, &s->buf[(seq*6+(chan_slice/3)+chan_slice*5+7)*80 + chan_offset],
                             &s->sys->video_place[slice*5]);
     return 0;
 }