
Recherche avancée
Médias (1)
-
Bug de détection d’ogg
22 mars 2013, par
Mis à jour : Avril 2013
Langue : français
Type : Video
Autres articles (24)
-
La sauvegarde automatique de canaux SPIP
1er avril 2010, parDans le cadre de la mise en place d’une plateforme ouverte, il est important pour les hébergeurs de pouvoir disposer de sauvegardes assez régulières pour parer à tout problème éventuel.
Pour réaliser cette tâche on se base sur deux plugins SPIP : Saveauto qui permet une sauvegarde régulière de la base de donnée sous la forme d’un dump mysql (utilisable dans phpmyadmin) mes_fichiers_2 qui permet de réaliser une archive au format zip des données importantes du site (les documents, les éléments (...) -
La file d’attente de SPIPmotion
28 novembre 2010, parUne file d’attente stockée dans la base de donnée
Lors de son installation, SPIPmotion crée une nouvelle table dans la base de donnée intitulée spip_spipmotion_attentes.
Cette nouvelle table est constituée des champs suivants : id_spipmotion_attente, l’identifiant numérique unique de la tâche à traiter ; id_document, l’identifiant numérique du document original à encoder ; id_objet l’identifiant unique de l’objet auquel le document encodé devra être attaché automatiquement ; objet, le type d’objet auquel (...) -
Les vidéos
21 avril 2011, parComme les documents de type "audio", Mediaspip affiche dans la mesure du possible les vidéos grâce à la balise html5 .
Un des inconvénients de cette balise est qu’elle n’est pas reconnue correctement par certains navigateurs (Internet Explorer pour ne pas le nommer) et que chaque navigateur ne gère en natif que certains formats de vidéos.
Son avantage principal quant à lui est de bénéficier de la prise en charge native de vidéos dans les navigateur et donc de se passer de l’utilisation de Flash et (...)
Sur d’autres sites (2577)
-
Making youtube-dl download mp3's faster
12 novembre 2017, par sciencelordIt takes a long time to download mp3 songs using youtube-dl, and it takes even longer when downloading a bunch of mp3 songs. Is there a way to make it significantly faster ? I don’t mind reducing quality. I’ve been using the command below.
youtube-dl --extract-audio --audio-format "mp3" --output "%(title)s.%(ext)s" "https://www.youtube.com/watch?v={videoid}
I also took a look at this post :
ffmpeg command for faster encoding at a decent bitrate with smaller file sizeBut I wasn’t sure how to change the above command using the ffmpeg modifications.
Thanks !
-
Download MP4 Video In Specific Folder In server With CURL
14 novembre 2017, par AlishI’m Trying To Download
.MP4 Extension
File WithPHP Code In Specific Folder
My Code Working Fine For .MP4 Extension Only But I Can’t Download This URL MP4 Video With This CodeI’m Trying This Code
function download ($url, $location){
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_SSLVERSION,3);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
$data = curl_exec ($ch);
$error = curl_error($ch);
curl_close ($ch);
$file = fopen($location, "wb");
fwrite($file, $data);
fclose($file);
return 'done';
}
?>
<form method="post" action="<?php echo $_SERVER['PHP_SELF'];?>">
Video URL (Only With .MP4 Extension):
<input type="text" placeholder="Video URL Here" required="required" /><br />
Video ID Number:
<input type="text" placeholder="Video ID Nmber eg:1,2,3" required="required" /><br />
<input type="submit" />
</form>
<?php
@$url = $_POST['url'];
@$ID = $_POST['id'];
$SCRIPT_DIR = dirname(__FILE__);
$TEMP_DIR = $SCRIPT_DIR . '/videos/';
$location = $TEMP_DIR . $ID . '.mp4';
if(isset($_POST['url'])){
echo download($url, $location);
} -
No such file or directory when running an ffmpeg command from script
23 novembre 2017, par A_MatarI have been trying to run this
ffmpeg
command from python script to generate video of certain length from a static image but I keep getting No such file or directory error !
Here is my code :import subprocess
def generate_white_vid (duration):
ffmpeg_create_vid_from_static_img = 'ffmpeg -loop 1 -i /same_path/WhiteBackground.jpg -c:v libx264 -t %f -pix_fmt yuv420p -vf scale=1920:1080 /same_path/white_vid2.mp4' % duration
print ffmpeg_create_vid_from_static_img
pp = subprocess.Popen(ffmpeg_create_vid_from_static_img)
pp.communicate()
generate_white_vid(0.5)However when I run the same exact command :
ffmpeg -loop 1 -i /same_path/WhiteBackground.jpg -t 0.500000 -pix_fmt yuv420p -vf scale=1920:1080 /same_path/white_vid2.mp4
from the cli, it works just fine. Where am I missing up ?
Here is the full trace :Traceback (most recent call last):
File "gen.py", line 10, in <module>
generate_white_vid(0.5)
File "gen.py", line 7, in generate_white_vid
pp = subprocess.Popen(ffmpeg_create_vid_from_static_img)
File "/home/ubuntu/anaconda2/lib/python2.7/subprocess.py", line 390, in __init__
errread, errwrite)
File "/home/ubuntu/anaconda2/lib/python2.7/subprocess.py", line 1024, in _execute_child
raise child_exception
OSError: [Errno 2] No such file or directory
</module>When I use a list to pass the
ffmpeg
commands parameters as followingffmpeg_create_vid_from_static_img = ['ffmpeg', '-loop', '1', '-i', '/same_path/WhiteBackground.jpg', '-c:v', 'libx264', '-t', duration, '-pix_fmt', 'yuv420p', '-vf', 'scale=1920:1080', '/same_path/white_vid.mp4']
, I get a type error :TypeError Traceback (most recent call last)
in <module>()
----> 1 generate_white_vid(0.5)
in generate_white_vid(duration)
3 ffmpeg_create_vid_from_static_img = ['ffmpeg', '-loop', '1', '-i', '/home/ubuntu/matar/multispectral/WhiteBackground.jpg', '-c:v', 'libx264', '-t', duration, '-pix_fmt yuv420p', '-vf', 'scale=1920:1080', '/home/ubuntu/matar/multispectral/white_vid.mp4']
4 print ffmpeg_create_vid_from_static_img
----> 5 pp = subprocess.Popen(ffmpeg_create_vid_from_static_img)
6 pp.communicate()
/home/ubuntu/anaconda2/lib/python2.7/subprocess.pyc in __init__(self, args, bufsize, executable, stdin, stdout, stderr, preexec_fn, close_fds, shell, cwd, env, universal_newlines, startupinfo, creationflags)
388 p2cread, p2cwrite,
389 c2pread, c2pwrite,
--> 390 errread, errwrite)
391 except Exception:
392 # Preserve original exception in case os.close raises.
/home/ubuntu/anaconda2/lib/python2.7/subprocess.pyc in _execute_child(self, args, executable, preexec_fn, close_fds, cwd, env, universal_newlines, startupinfo, creationflags, shell, to_close, p2cread, p2cwrite, c2pread, c2pwrite, errread, errwrite)
1022 raise
1023 child_exception = pickle.loads(data)
-> 1024 raise child_exception
1025
1026
TypeError: execv() arg 2 must contain only strings
</module>