]> granicus.if.org Git - handbrake/commitdiff
Revert changes to threading sleep intervals.
authorjohnallen <johnallenemail@gmail.com>
Tue, 9 Jan 2007 01:46:52 +0000 (01:46 +0000)
committerjohnallen <johnallenemail@gmail.com>
Tue, 9 Jan 2007 01:46:52 +0000 (01:46 +0000)
Some users have issues with this.
It is less risky to not include this for release 0.7.2

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@100 b64f7644-9d1e-0410-96f1-a4d463321fa5

libhb/hb.c
libhb/muxcommon.c
libhb/work.c
macosx/HandBrake.xcodeproj/project.pbxproj

index 977e3dc710c84fb6ed8301359948c6a6917164cb..bdd2353d94267b08acbf839442571840adc0f068 100644 (file)
@@ -664,7 +664,7 @@ static void thread_func( void * _h )
             hb_unlock( h->state_lock );
         }
 
-        hb_snooze( 1000 );
+        hb_snooze( 50 );
     }
 
     if( h->work_thread )
index 99fe6fc91bc879bf18aa1714a387d6498d44c112..70e384e8a707e6dc5f39e82f2bf3c3581d8830b3 100644 (file)
@@ -140,15 +140,10 @@ static void MuxerFunc( void * _mux )
         if( !( track = GetTrack( list ) ) )
         {
             hb_snooze( thread_sleep_interval );
-                       thread_sleep_interval += 1;
+//                     thread_sleep_interval += 1;
             continue;
         }
-               thread_sleep_interval = MAX(1, (thread_sleep_interval - 1));
-#if 0
-               if ((thread_sleep_interval <= 1) || (thread_sleep_interval > 100)) {
-                       hb_log("%s: %d", "Muxer", thread_sleep_interval);
-               }
-#endif
+//             thread_sleep_interval = MAX(1, (thread_sleep_interval - 1));
 
         buf = hb_fifo_get( track->fifo );
         if( job->pass != 1 )
index d1f2aaf5ca52f1b2b61ff1e1c71dae36a41bd4da..6529e2fbb5b2fbd2df1729f0bb814e9768e3f8e2 100644 (file)
@@ -327,20 +327,16 @@ static void work_loop( void * _w )
         hb_lock( job->pause );
         hb_unlock( job->pause );
 #endif
-        //if( hb_fifo_is_full( w->fifo_out ) ||
-        if( (hb_fifo_percent_full( w->fifo_out ) > 0.8) ||
+        if( hb_fifo_is_full( w->fifo_out ) ||
+//        if( (hb_fifo_percent_full( w->fifo_out ) > 0.8) ||
             !( buf_in = hb_fifo_get( w->fifo_in ) ) )
         {
             hb_snooze( w->thread_sleep_interval );
-                       w->thread_sleep_interval += 1;
+//                     w->thread_sleep_interval += 1;
             continue;
         }
-               w->thread_sleep_interval = MAX(1, (w->thread_sleep_interval - 1));
-#if 0
-               if ((w->thread_sleep_interval <= 1) || (w->thread_sleep_interval > 100)) {
-                       hb_log("%s: %d", w->name, w->thread_sleep_interval);
-               }
-#endif
+//             w->thread_sleep_interval = MAX(1, (w->thread_sleep_interval - 1));
+
         w->work( w, &buf_in, &buf_out );
         if( buf_in )
         {
index beb466526bf75b9023399222dc42b6de5957583c..b77f580b76aeaba5b205c4d1c54c510aa2bf42e8 100644 (file)
@@ -66,7 +66,7 @@
                4D86C74F07281F4E007BA979 /* ScanController.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = ScanController.h; sourceTree = "<group>"; };
                4DD27BA507C0065C0023D231 /* QueueController.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = QueueController.h; sourceTree = "<group>"; };
                4DD27BA607C0065C0023D231 /* QueueController.mm */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.objcpp; path = QueueController.mm; sourceTree = "<group>"; };
-               4DD93FA6082036E8008E1322 /* HandBrake.app */ = {isa = PBXFileReference; includeInIndex = 0; lastKnownFileType = wrapper.application; path = HandBrake.app; sourceTree = BUILT_PRODUCTS_DIR; };
+               4DD93FA6082036E8008E1322 /* HandBrake.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = HandBrake.app; sourceTree = BUILT_PRODUCTS_DIR; };
                4DDE9724052B7B2B00C39CA9 /* OpenGL.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = OpenGL.framework; path = /System/Library/Frameworks/OpenGL.framework; sourceTree = "<absolute>"; };
                4DE09E62082038A400FB751F /* HandBrake.plist */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text.xml; path = HandBrake.plist; sourceTree = "<group>"; };
                4DE93A3507F5A2C900F3C78F /* PrefsController.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = PrefsController.h; sourceTree = "<group>"; };