
Advanced search
Other articles (91)
-
Ajouter des informations spécifiques aux utilisateurs et autres modifications de comportement liées aux auteurs
12 April 2011, byLa manière la plus simple d’ajouter des informations aux auteurs est d’installer le plugin Inscription3. Il permet également de modifier certains comportements liés aux utilisateurs (référez-vous à sa documentation pour plus d’informations).
Il est également possible d’ajouter des champs aux auteurs en installant les plugins champs extras 2 et Interface pour champs extras. -
Les autorisations surchargées par les plugins
27 April 2010, byMediaspip core
autoriser_auteur_modifier() afin que les visiteurs soient capables de modifier leurs informations sur la page d’auteurs -
Publier sur MédiaSpip
13 June 2013Puis-je poster des contenus à partir d’une tablette Ipad ?
Oui, si votre Médiaspip installé est à la version 0.2 ou supérieure. Contacter au besoin l’administrateur de votre MédiaSpip pour le savoir
On other websites (11091)
-
FFMPEG Process not ending when encoding libx264
17 January 2015, by Jamie HartnollWell, I’m very new and inexperienced with using
Process
and usingFFMPEG
, and command line processes in ASP.NET in general... but, have something working, nearly!I’m trying to convert AVI files to MP4 files which can be streamed to an HTML5 player.
After a lot of messing around, I have found that for this to work it has to be encoded with X264, but, for some reason, when I do this the FFMPEG process does not close/end.
The code I am using is below and works perfectly if I use
-vcodec mpeg4
, but when I use-vcodec libx264
, whilst it works and produces the file I need toProcess
never ends.To get round this, I am temporarily adding 5 second time out to
WaitForExit
in theProcess
, but this is definitely a hack and whilst is OK with what I am doing at the moment is not a robust solution.Can anyone point me in the direction of why this is happening?!
Public Shared Sub AviToMP4(VideoFileName As String, Optional DeleteSource As Boolean = True)
Dim SourceFile As String = VideoFileName.Replace(".avi", "")
Dim DestinationFile As String = SourceFile
Dim FFMPEG_EXE_PATH As String = """" & System.AppDomain.CurrentDomain.BaseDirectory() & "ffMPEG.exe"""
Dim Codec = "libx264" ' libx264 || mpeg4
Dim cdml = " -i """ & SourceFile & ".avi"" -acodec aac -strict -2 -b:a 128k -vcodec " & Codec & " -b:v 1200k -flags +aic+mv4 """ & DestinationFile & ".mp4"""
Dim ProcessorLocation As String = FFMPEG_EXE_PATH
Dim CommandLines As String = cdml
Try
Dim ProcessingResponse As String = ""
Using myProcess As New Process()
myProcess.StartInfo.UseShellExecute = False
myProcess.StartInfo.RedirectStandardInput = True
myProcess.StartInfo.RedirectStandardOutput = True
myProcess.StartInfo.RedirectStandardError = True
myProcess.StartInfo.CreateNoWindow = True
myProcess.StartInfo.WindowStyle = ProcessWindowStyle.Hidden
myProcess.StartInfo.FileName = ProcessorLocation
myProcess.StartInfo.Arguments = CommandLines
myProcess.Start()
ProcessingResponse = myProcess.StandardError.ReadToEnd()
myProcess.WaitForExit(5000) ' <<< Have to put a timeout here for libx264 or it will never end!!
End Using
HttpContext.Current.Response.Write("<pre>" & ProcessingResponse & "</pre><hr />")
If File.Exists(SourceFile) AndAlso DeleteSource Then
File.Delete(SourceFile)
End If
Catch ex As Exception
HttpContext.Current.Response.Write(ex.ToString & "<p>")
End Try
End Sub
</p> -
FFMPEG : Cut Video AND Include Ending Video/Image
7 November 2016, by user3273784I am using this command line to add a five second image on end of video:
ffmpeg -i "f:\output\input.mov" -loop 1 -t 5 -i "f:\output\taff.jpg" -f lavfi -t 5 -i anullsrc -filter_complex "[0:v] [0:a] [1:v] [2:a] concat=n=2:v=1:a=1 [v] [a]" -c:v libx264 -c:a aac -strict -2 -map "[v]" -map "[a]" f:\output\output.mp4
It works great, but sometimes I want to cut the video and then add the five seconds. So, make a 120 second video 110 seconds, then add the 5 second ending.
Possibly in one command line? I’ve tried to break it into two, by starting with cutting the video, but then I get an "Unable to parse option value "-1" pixel format" error if I try to re-encode the video I cut with ffmpeg using this:
ffmpeg -i f:\output\input.mov -vcodec copy -acodec copy -ss 00:00:00.000 -t 00:01:50.000 f:\output\output.mov
That output video will then give an error if I try to run the first command line against it.
All feedback appreciated on shortening a video, and then adding ending.
Cheers!
Ryan -
FFMPEG : Cut Video AND Include Ending Video/Image
10 February 2019, by user3273784I am using this command line to add a five second image on end of video:
ffmpeg -i "f:\output\input.mov" -loop 1 -t 5 -i "f:\output\taff.jpg" -f lavfi -t 5 -i anullsrc -filter_complex "[0:v] [0:a] [1:v] [2:a] concat=n=2:v=1:a=1 [v] [a]" -c:v libx264 -c:a aac -strict -2 -map "[v]" -map "[a]" f:\output\output.mp4
It works great, but sometimes I want to cut the video and then add the five seconds. So, make a 120 second video 110 seconds, then add the 5 second ending.
Possibly in one command line? I’ve tried to break it into two, by starting with cutting the video, but then I get an "Unable to parse option value "-1" pixel format" error if I try to re-encode the video I cut with ffmpeg using this:
ffmpeg -i f:\output\input.mov -vcodec copy -acodec copy -ss 00:00:00.000 -t 00:01:50.000 f:\output\output.mov
That output video will then give an error if I try to run the first command line against it.
All feedback appreciated on shortening a video, and then adding ending.
Cheers!
Ryan