开发者

Progress bar in VB 6.0 from Transcoding process in FFMPEG

firts excuse me for my English it`s super Freak. Sorry

I have a big problem , i need finish my applicatión in VB6.0 for a test in my High Sch开发者_开发技巧ooll and i can`t find the solution, My app open a FFmpeg.EXE file which open a cmd window Prompt and start a trascoding process, i need link the last line generated into the Prompt of the CMD window (Or top Bottom) , in this line exists Values what change , in this trascoding process the result are bit Rates , which fluctuates acording to others var. The idea it´s what into the form of my app i can read this line in real time to bulid a progress bar (File Size/Bitrate average)=time to process.

Can you help me. Thanks for the answer....


Put a reference to Windows Scripting Host Object Model and try this snippet

Option Explicit

Private Sub Command1_Click()
    Dim oExec       As WshExec
    Dim sRow        As String

    With New WshShell
        Set oExec = .Exec("tasklist.exe")
    End With
    Do While oExec.Status = WshRunning
        sRow = oExec.StdOut.ReadLine
        If InStr(1, sRow, "vb6.exe", vbTextCompare) > 0 Then
            MsgBox sRow, vbExclamation
        End If
    Loop
End Sub

Basicly try executing FFmpeg.EXE and ReadLine until you find some key text.


Send the output to a textfile then read this textfile. Should look something like this:

ping >e:\test.txt

Where ping is the FFmpge.EXE and e:\test.txt the output textfile


rdkleine

I read your answer and this is great work very good , only that it shows in the log a death value "text", and i need the value of fluctuates bitrates of conversion , which changes in real time in the prompt of the cmd window. i'm trying now with the source code of wqw , i'm working in there.

Thak's for your answer..

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜