Solo por curiosidad, cómo el plugin "aatv" de GStreamer transforma los vídeos con los recursos del Componente
gb.media:
Código:
Public Sub Main()
Dim pl As MediaPipeline
Dim src, dcb, aa, con, snk As MediaControl
Dim asrc, abin, acon, ares, asnk As MediaControl
Dim filevideo As String
Dim tm As Date
filevideo = "/ruta/del/fichero/video"
pl = New MediaPipeline
' Parte vídeo:
src = New MediaControl(pl, "filesrc")
src["location"] = filevideo
dcb = New MediaControl(pl, "decodebin")
aa = New MediaControl(pl, "aatv")
con = New MediaControl(pl, "videoconvert")
snk = New MediaControl(pl, "autovideosink")
src.LinkTo(dcb)
dcb.LinkLaterTo(aa)
aa.LinkTo(con)
con.LinkTo(snk)
' Parte audio:
asrc = New MediaControl(pl, "filesrc")
asrc["location"] = filevideo
abin = New MediaControl(pl, "decodebin")
acon = New MediaControl(pl, "audioconvert")
ares = New MediaControl(pl, "audioresample")
asnk = New MediaControl(pl, "autoaudiosink")
asrc.LinkTo(abin)
abin.LinkLaterTo(acon)
acon.LinkTo(ares)
ares.LinkTo(asnk)
pl.Play
Repeat ' Mientras no se detecte la duración del vídeo, el ciclo continúa
Wait 0.01
Until pl.Duration > 0.00
Print "Duración del vídeo: "; Time(0, 0, 0, pl.Duration * 1000)
tm = Now
Repeat
Write "\r\e[0mTiempo transcurrido: \e[31m" & Str(Time(0, 0, 0, DateDiff(tm, Now, gb.Millisecond)))
Wait 0.01
Until DateDiff(tm, Now, gb.Millisecond) >= (pl.Duration * 1000)
pl.Stop
pl.Close
End