
Recherche avancée
Médias (3)
-
The Slip - Artworks
26 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Texte
-
Podcasting Legal guide
16 mai 2011, par
Mis à jour : Mai 2011
Langue : English
Type : Texte
-
Creativecommons informational flyer
16 mai 2011, par
Mis à jour : Juillet 2013
Langue : English
Type : Texte
Autres articles (39)
-
Personnaliser en ajoutant son logo, sa bannière ou son image de fond
5 septembre 2013, parCertains thèmes prennent en compte trois éléments de personnalisation : l’ajout d’un logo ; l’ajout d’une bannière l’ajout d’une image de fond ;
-
Ecrire une actualité
21 juin 2013, parPrésentez les changements dans votre MédiaSPIP ou les actualités de vos projets sur votre MédiaSPIP grâce à la rubrique actualités.
Dans le thème par défaut spipeo de MédiaSPIP, les actualités sont affichées en bas de la page principale sous les éditoriaux.
Vous pouvez personnaliser le formulaire de création d’une actualité.
Formulaire de création d’une actualité Dans le cas d’un document de type actualité, les champs proposés par défaut sont : Date de publication ( personnaliser la date de publication ) (...) -
Publier sur MédiaSpip
13 juin 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
Sur d’autres sites (4670)
-
Pipe raw audio from mp4 using ffmpeg
24 février 2015, par user1447257I have following class, that enables to read audio frames per video frame :
class AudioAcquisition :
’’’
This component returns an audio signal per video frame.
’’’def __init__(self, video_filename, bufsize=10**8):
'''
Parameters:
-----------
video_filename : String of the location of video file.
'''
# Read info from video using ffmpeg
cmd = ["ffmpeg", \
'-i', video_filename]
info_pipe = subprocess.Popen(cmd, stdout=subprocess.PIPE, \
stderr=subprocess.PIPE)
_, err = info_pipe.communicate()
self.__audio_fps = int(re.search('Stream[^\n]*Audio:[^\n]*, (\d*) Hz', err).group(1))
self.__video_fps = int(re.search('Stream[^\n]*Video:[^\n]*, (\d*) fps', err).group(1))
# Open audio using ffmpeg
cmd = ['ffmpeg', \
'-loglevel', 'quiet', \
'-i', video_filename, \
'-vn', \
'-f', 's16le', \
'-acodec', 'pcm_s16le', \
'-ac', '1', \
'-']
print " ".join(cmd)
self.__pipe = subprocess.Popen(cmd, stdout=subprocess.PIPE, \
stderr=subprocess.STDOUT)
def run(self):
'''
Yields:
-------
An audio signal per video frame.
'''
while (True):
try:
size = int(2 * self.__audio_fps / self.__video_fps)
data = self.__pipe.stdout.read(size)
if (len(data) < size):
break
yield numpy.fromstring(data, dtype="int16")
except IOError as e:
print('Error encoutered while reading audio via ffmpeg: ' \
+ str(e))
breakThis somehow does not work properly, as the audio is dumped out with some noise frames at about 20s and repetitively occuring more often at later timestamps.
Do you guys have any suggestions what I am missing in calling ffmpeg ?
Thanks !
-
Using Pipe for input and output on FFMPEG ?
2 mars 2015, par SugrueI want to use ffmpeg to convert video packets to mjpeg, and ideally, I want to pipe in the gob packet and receive the output via pipe also.
I’m using a C# process to call ffmpeg like this :
-f h264 -i pipe : -an -f mjpeg -q:v 1 pipe :
I pipe in the source data stream using the process .StandardInput.BaseStream and get the returned data from .StandardOutput.BaseStream.
The issue is, FFmpeg doesn’t send data. It sits, apparently waiting. No errors. Nothing gets written to StandardOutput.
If I try each pipe on its own, it works fine. These work :
a) passing in a source file location and getting the returned frame data via pipe (bytes are written to StandardOutput)
b) passing in source bytes via pipe and asking Ffmpeg to save result to file
This doesn’t work :
c) piping in data, and getting data out via pipe.
From a previous answer from @nmaier to this question (Can I use ffmpeg to output jpegs to a memory stream instead of a file) I think pipe-in/pipe-out should work. But it doesn’t.
What am I doing wrong ?
Thanks.
-
Why is long video taking long time before VideoJS player gets metadata to start playing ?
7 mars 2015, par Tom JenkinsonDoes anyone know why it is taking so long before the
loadedmetadata
event is fired for longer videos ?Here is an example : https://www.la1tv.co.uk/player/124/260
I can see in developer tools that the file is still downloading when the event is fired, so it’s not like it’s having to download the whole file, it’s just having to get quite far though before the event is fired.
The ffmpeg command I am using to encode the video from java is :
RuntimeHelper.executeProgram(new String[] {config.getString("ffmpeg.location"), "-y", "-nostdin", "-timelimit", ""+config.getInt("ffmpeg.videoEncodeTimeLimit"), "-progress", ""+f.progressFile.getAbsolutePath(), "-i", source.getAbsolutePath(), "-vf", "scale=trunc(("+f.h+"*a)/2)*2:"+f.h, "-strict", "experimental", "-acodec", "aac", "-b:a", f.aBitrate+"k", "-ac", "2", "-ar", "48000", "-vcodec", "libx264", "-vprofile", "main", "-g", "48", "-b:v", f.vBitrate+"k", "-maxrate", f.vBitrate+"k", "-bufsize", f.vBitrate*2+"k", "-preset", "medium", "-crf", "16", "-vsync", "vfr", "-af", "aresample=async=1000", "-movflags", "+faststart", "-r", f.fr+"", "-f", "mp4", f.outputFile.getAbsolutePath()}, workingDir, null, null);
which can be found here.
It has the
faststart
flag set and I thought this meant the metadata would be inserted right at the beginning of the file ?Could it be an issue with the encode settings ?
Thanks !