
Recherche avancée
Médias (1)
-
Carte de Schillerkiez
13 mai 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Texte
Autres articles (72)
-
Les autorisations surchargées par les plugins
27 avril 2010, parMediaspip core
autoriser_auteur_modifier() afin que les visiteurs soient capables de modifier leurs informations sur la page d’auteurs -
MediaSPIP Player : problèmes potentiels
22 février 2011, parLe lecteur ne fonctionne pas sur Internet Explorer
Sur Internet Explorer (8 et 7 au moins), le plugin utilise le lecteur Flash flowplayer pour lire vidéos et son. Si le lecteur ne semble pas fonctionner, cela peut venir de la configuration du mod_deflate d’Apache.
Si dans la configuration de ce module Apache vous avez une ligne qui ressemble à la suivante, essayez de la supprimer ou de la commenter pour voir si le lecteur fonctionne correctement : /** * GeSHi (C) 2004 - 2007 Nigel McNie, (...) -
Encoding and processing into web-friendly formats
13 avril 2011, parMediaSPIP automatically converts uploaded files to internet-compatible formats.
Video files are encoded in MP4, Ogv and WebM (supported by HTML5) and MP4 (supported by Flash).
Audio files are encoded in MP3 and Ogg (supported by HTML5) and MP3 (supported by Flash).
Where possible, text is analyzed in order to retrieve the data needed for search engine detection, and then exported as a series of image files.
All uploaded files are stored online in their original format, so you can (...)
Sur d’autres sites (4553)
-
ffmpeg append video with different dimensions
21 avril 2020, par friendlygiraffeI am cropping and adding subtitles to a video using the following :



ffmpeg -i inputfile.mov -lavfi "crop=720:720:280:360,subtitles=subs.srt:force_style='OutlineColour=&H100000000,BorderStyle=3,Outline=1,Shadow=0,MarginV=20,Fontsize=18'" -crf 1 -c:a copy output.mov



I have another video called credits.mp4 which has the same dimensions as the output.mov (after cropping). Can I do this during the above process, or would I have to use something like concat afterwards ?



Using bash in Terminal on a Mac


-
Why is my FastAPI process being suspended, and how can I avoid this ?
19 janvier, par blermenI'm working on a web app using FastAPI that uses ffmpeg to overlay audio onto video for the user. I'm running into an issue where, when I use subprocess.run(cmd), it automatically suspends the process running my FastAPI app. I can't figure out how to get the error logs to help deduce why this is, and I haven't found anything online talking about this.


@app.get("/overlay-audio/")
async def get_video(audio_file: str, forged_name: Annotated[str, Query()] = "default"):
 video_path = os.path.join(output_path, "sample.mp4")
 audio_path = os.path.join(output_path, audio_file)
 forged_path = os.path.join(output_path, forged_name + ".mp4")
 print("Video path: " + video_path)
 print("Audio path: " + audio_path)
 print("Output path: " + forged_path)

 # command to recreate
 # ffmpeg -i input.mp4 -i input.wav -c:v copy -map 0:v:0 -map 1:a:0 -c:a aac -b:a 192k output.mp4

 cmd = ["/opt/homebrew/bin/ffmpeg", 
 "-i", video_path,
 "-i", audio_path,
 "-c:v", "copy",
 "-map", "0:v:0",
 "-map", "1:a:0",
 "-c:a", "aac",
 "-b:a", "192k",
 forged_path]
 
 subprocess.run(cmd)
 
 return {"forged_vid": f"forged_{forged_name}"}


if __name__ == "__main__":
 uvicorn.run("main:app", host="127.0.0.1", port=8000, reload=True)



I've tried not writing output to the terminal, as I've read that could be a reason why it suspends using
result = subprocess.run(cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
, and I've also tried running it asynchronously to avoid blocking the event loop using

result = await asyncio.create_subprocess_exec(
 *cmd,
 stdout=subprocess.PIPE,
 stderr=subprocess.PIPE
 )



but nothing works. Any help or possible other ways to go about this would be greatly appreciated. Terminal output about the suspension : [1] + 12526 suspended (tty output) "/Users//Tech Projects/project/tts/videnv/bin/python"


-
Gnuplot how to set a variable to standard-input if not passed
27 août 2020, par DDSI have a gnuplot script (plot.script) that is invoked like


C:> ffmpeg -i '.\my_awesome_audio_file.wav' -filter_complex aformat=channel_layouts=mono -acodec pcm_s16le -ar 4000 -f data - | gnuplot -e "fileout='plot';fileformat='png';wid=500;" .\plot.script 



Now I'd want to default filein variable to stdin if it is not passed as argument. This because I want to be able to call this script as a 1-liner command with ffmpeg data generation and also as step-by-step procedure


My idea was to use


if(!exists('filein')){
filein = '-';
}



but this throws
warning: Skipping data file with no valid points


if i print the variable datafile I got
-
(I expected something like stdin).

this is the
plot.script
script :


if(!exists('filein')){
 filein = '-';
 }

if (!exists("hei")){
 hei = 4444;
 }
if (!exists("wid")){
 wid = 5555;
 }
if(!exists("fileformat")){
 fileformat = 'png';
 }
if(!exists("fileout")){
 fileout = 'risultato';
 }
 
fileout = fileout . '.' . fileformat;
 
if(!exists("dataformat")){
 dataformat = '%int16';
 }
if(fileformat eq 'png'){
 set terminal png transparent size larghezza,altezza;
 
 }else{
 set terminal fileformat size wid,hei;
 }
 set output fileout;
 unset key;
 unset tics;
 unset border;
 set lmargin 0;
 set rmargin 0;
 set tmargin 0;
 set bmargin 0;


print filein;
plot filein binary filetype=bin format=dataformat endian=little array=1:0 with lines linecolor "0x009900";



But I also want to call this command-by-command :
generate the data-file :


c:> ffmpeg -i '.\my_awesome_audio_file.wav' -filter_complex aformat=channel_layouts=mono -acodec pcm_s16le -ar 4000 -f data audio.dat



plot the data :


c:> gnuplot -e "filein='audio.dat';fileout='plot';fileformat='png';wid=500;" .\plot.script