OSDN Git Service

Workaround from "van" to prevent double chapter markers when using advanced deinterla...
authoreddyg <eddyg@b64f7644-9d1e-0410-96f1-a4d463321fa5>
Fri, 31 Aug 2007 01:31:07 +0000 (01:31 +0000)
committereddyg <eddyg@b64f7644-9d1e-0410-96f1-a4d463321fa5>
Fri, 31 Aug 2007 01:31:07 +0000 (01:31 +0000)
git-svn-id: svn://localhost/HandBrake/trunk@907 b64f7644-9d1e-0410-96f1-a4d463321fa5

libhb/deinterlace.c

index a6d3832..2d35ecf 100644 (file)
@@ -65,7 +65,7 @@ hb_filter_private_t * hb_deinterlace_init( int pix_fmt,
                                            int height,\r
                                            char * settings );\r
 \r
-int hb_deinterlace_work( const hb_buffer_t * buf_in,\r
+int hb_deinterlace_work( hb_buffer_t * buf_in,\r
                          hb_buffer_t ** buf_out,\r
                          int pix_fmt,\r
                          int width, \r
@@ -497,7 +497,7 @@ void hb_deinterlace_close( hb_filter_private_t * pv )
     free( pv );\r
 }\r
 \r
-int hb_deinterlace_work( const hb_buffer_t * buf_in,\r
+int hb_deinterlace_work( hb_buffer_t * buf_in,\r
                          hb_buffer_t ** buf_out,\r
                          int pix_fmt,\r
                          int width, \r
@@ -551,6 +551,9 @@ int hb_deinterlace_work( const hb_buffer_t * buf_in,
         yadif_store_ref( (const uint8_t**)pv->pic_in.data, pv );\r
         \r
         hb_buffer_copy_settings( pv->buf_settings, buf_in );\r
+
+        /* don't let 'work_loop' send a chapter mark upstream */
+        buf_in->new_chap  = 0;
 \r
         pv->yadif_ready = 1;\r
         \r
@@ -588,6 +591,9 @@ int hb_deinterlace_work( const hb_buffer_t * buf_in,
     \r
     /* Replace buffered settings with input buffer settings */\r
     hb_buffer_copy_settings( pv->buf_settings, buf_in );    \r
+
+    /* don't let 'work_loop' send a chapter mark upstream */
+    buf_in->new_chap  = 0;
 \r
     return FILTER_OK;\r
 }\r