View Single Post
Old 28th August 2008, 16:24   #54  |  Link
LoRd_MuldeR
Software Developer
 
LoRd_MuldeR's Avatar
 
Join Date: Jun 2005
Location: Last House on Slunk Street
Posts: 13,248
Quote:
Originally Posted by LigH View Post
Not sure if I will use it already for DivX264 CLI alpha 1, but maybe some day...
It already works with my simplistic Demo application and this commandline:
cmd.exe /c "C:\Program Files (x86)\DivX\DivX H.264 Codec CLI\bin\WhisX.bat"

(But the log filter would need some adjustment for divx264.exe -- done, see post above)


@ DivX developers:

It seems the DivX CLI encoder is missing to call fflush() after writing the progress line to STDOUT/STDERR.
This will cause a nasty delay when redirecting the console output...

x264 does do it the following way:
Code:
            if( i_frame_total )
            {
                int eta = i_elapsed * (i_frame_total - i_frame) / ((int64_t)i_frame * 1000000);
                i_progress = i_frame * 1000 / i_frame_total;
                fprintf( stderr, "encoded frames: %d/%d (%.1f%%), %.2f fps, eta %d:%02d:%02d  \r",
                         i_frame, i_frame_total, (float)i_progress / 10, fps,
                         eta/3600, (eta/60)%60, eta%60 );
            }
            else
                fprintf( stderr, "encoded frames: %d, %.2f fps   \r", i_frame, fps );
            fflush( stderr ); // needed in windows
__________________
Go to https://standforukraine.com/ to find legitimate Ukrainian Charities 🇺🇦✊

Last edited by LoRd_MuldeR; 28th August 2008 at 20:25.
LoRd_MuldeR is offline   Reply With Quote