changeset 391:ddb1be8aa479 libavcodec

improved mpeg1/2 decoding speed
author glantau
date Sat, 18 May 2002 22:56:50 +0000
parents 48e08d9871da
children 4ef26ed29399
files mpeg12.c
diffstat 1 files changed, 6 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/mpeg12.c	Sat May 18 22:56:25 2002 +0000
+++ b/mpeg12.c	Sat May 18 22:56:50 2002 +0000
@@ -855,6 +855,8 @@
                 if (cbp & (1 << (5 - i))) {
                     if (mpeg2_decode_block_intra(s, block[i], i) < 0)
                         return -1;
+                } else {
+                    s->block_last_index[i] = -1;
                 }
             }
         } else {
@@ -862,6 +864,8 @@
                 if (cbp & (1 << (5 - i))) {
                     if (mpeg2_decode_block_non_intra(s, block[i], i) < 0)
                         return -1;
+                } else {
+                    s->block_last_index[i] = -1;
                 }
             }
         }
@@ -870,6 +874,8 @@
             if (cbp & (1 << (5 - i))) {
                 if (mpeg1_decode_block(s, block[i], i) < 0)
                     return -1;
+            } else {
+                s->block_last_index[i] = -1;
             }
         }
     }