
Recherche avancée
Médias (1)
-
Carte de Schillerkiez
13 mai 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Texte
Autres articles (40)
-
Mise à jour de la version 0.1 vers 0.2
24 juin 2013, parExplications des différents changements notables lors du passage de la version 0.1 de MediaSPIP à la version 0.3. Quelles sont les nouveautés
Au niveau des dépendances logicielles Utilisation des dernières versions de FFMpeg (>= v1.2.1) ; Installation des dépendances pour Smush ; Installation de MediaInfo et FFprobe pour la récupération des métadonnées ; On n’utilise plus ffmpeg2theora ; On n’installe plus flvtool2 au profit de flvtool++ ; On n’installe plus ffmpeg-php qui n’est plus maintenu au (...) -
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 ) (...)
Sur d’autres sites (5220)
-
Quicktime cannot play recorded mp4 video file
17 septembre 2014, par DudeI have an mp4 related issue. I’m not very good in video processing related stuff. We have a problem with an image file that is recorded via HTTP Live Streaming (HLS) from a live stream. The HLS chunks are just put together and saved on the file system as .mp4 file. This file cannot be played with Apple QuickTime. VLC can play it. But it is a requirement that it can be played with QuickTime.
However, I found a solution that works. When I use the ffmpeg command -reset_timestamps, the video file can be played with QuickTime. I also see which parameter changes. It’s the start value.
Before use of the command :
ffmpeg -i recorded_file.mp4
ffmpeg version 1.2.4 Copyright (c) 2000-2013 the FFmpeg developers
built on Jan 9 2014 09:06:57 with Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn)
configuration: --prefix=/usr/local/Cellar/ffmpeg/1.2.4 --enable-shared --enable-pthreads --enable-gpl --enable-version3 --enable-nonfree --enable-hardcoded-tables --enable-avresample --enable-vda --cc=clang --host-cflags= --host-ldflags= --enable-libx264 --enable-libfaac --enable-libmp3lame --enable-libxvid
libavutil 52. 18.100 / 52. 18.100
libavcodec 54. 92.100 / 54. 92.100
libavformat 54. 63.104 / 54. 63.104
libavdevice 54. 3.103 / 54. 3.103
libavfilter 3. 42.103 / 3. 42.103
libswscale 2. 2.100 / 2. 2.100
libswresample 0. 17.102 / 0. 17.102
libpostproc 52. 2.100 / 52. 2.100
[h264 @ 0x7fcb7b015a00] non-existing SPS 2 referenced in buffering period
[h264 @ 0x7fcb7b015a00] non-existing PPS referenced
[h264 @ 0x7fcb7b015a00] non-existing SPS 2 referenced in buffering period
[h264 @ 0x7fcb7b015a00] non-existing PPS 0 referenced
[h264 @ 0x7fcb7b015a00] decode_slice_header error
[h264 @ 0x7fcb7b015a00] no frame!
[mpegts @ 0x7fcb7b004a00] max_analyze_duration 5000000 reached at 5013333 microseconds
[mpegts @ 0x7fcb7b004a00] Could not find codec parameters for stream 2 (Unknown: none ([21][0][0][0] / 0x0015)): unknown codec
Consider increasing the value for the 'analyzeduration' and 'probesize' options
[NULL @ 0x7fcb7b016a00] start time is not set in estimate_timings_from_pts
Input #0, mpegts, from 'recorded_file.mp4':
Duration: 00:25:00.01, start: 68428.580933, bitrate: 1499 kb/s
Program 1
Stream #0:0[0x100]: Video: h264 (High) ([27][0][0][0] / 0x001B), yuv420p, 1024x576 [SAR 1:1 DAR 16:9], 25 fps, 25 tbr, 90k tbn, 50 tbc
Stream #0:1[0x101]: Audio: aac ([15][0][0][0] / 0x000F), 48000 Hz, stereo, fltp, 124 kb/s
Stream #0:2[0x102]: Unknown: none ([21][0][0][0] / 0x0015)Use of the command :
ffmpeg -i recorded_file.mp4 output.mp4 -reset_timestamps 0
File after use of the command :
ffmpeg -i output.mp4
ffmpeg version 1.2.4 Copyright (c) 2000-2013 the FFmpeg developers
built on Jan 9 2014 09:06:57 with Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn)
configuration: --prefix=/usr/local/Cellar/ffmpeg/1.2.4 --enable-shared --enable-pthreads --enable-gpl --enable-version3 --enable-nonfree --enable-hardcoded-tables --enable-avresample --enable-vda --cc=clang --host-cflags= --host-ldflags= --enable-libx264 --enable-libfaac --enable-libmp3lame --enable-libxvid
libavutil 52. 18.100 / 52. 18.100
libavcodec 54. 92.100 / 54. 92.100
libavformat 54. 63.104 / 54. 63.104
libavdevice 54. 3.103 / 54. 3.103
libavfilter 3. 42.103 / 3. 42.103
libswscale 2. 2.100 / 2. 2.100
libswresample 0. 17.102 / 0. 17.102
libpostproc 52. 2.100 / 52. 2.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'output.mp4':
Metadata:
major_brand : isom
minor_version : 512
compatible_brands: isomiso2avc1mp41
encoder : Lavf54.63.104
Duration: 00:25:00.04, start: 0.021333, bitrate: 1358 kb/s
Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 1024x576 [SAR 1:1 DAR 16:9], 1224 kb/s, 25 fps, 25 tbr, 12800 tbn, 50 tbc
Metadata:
handler_name : VideoHandler
Stream #0:1(und): Audio: aac (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 127 kb/s
Metadata:
handler_name : SoundHandlerA lot of the text output changes but the line with the duration, start and bitrate is interesting, as the start value is set to near zero.
Duration: 00:25:00.04, start: 0.021333, bitrate: 1358 kb/s
So to use this solution would be enough. The problem is, I cannot use ffmpeg in the solution that downloads the file (it’s for Android). So I try to find a way to do this in Java. However, as I have not much experience in Video processing, I can’t figure out, what this ffmpeg command does and therefore don’t know in which direction to look for a Java solution.
Is there a library that may do the same operation in Java or is there an easy way to do it myself in Java (like adjusting the file timestamp) ?
Thanks for you help !
EDIT : The whole console output is now shown, instead of just a part of it.
-
Stream input to stream output using avserver
13 janvier 2014, par Gustavo Sgarbi CamposI'm trying to use the avserver package to re-stream my ip camera's stream in order to be able to record this stream and access it remotelly without having to stream it twice from the camera, to avoid overloading the wireless network.
Following this link https://libav.org/avserver.html I came up with the following command :
avserver -f /etc/avserver.conf & avconv -i http://user:password@192.168.1.121/videostream.asf http://localhost:80/feed1.ffm
This gives me the following output
avserver version 0.8.3-6:0.8.3-6ubuntu2, Copyright (c) 2000-2012 the Libav developers
built on Oct 1 2012 15:03:26 with gcc 4.7.2
avconv version 0.8.3-6:0.8.3-6ubuntu2, Copyright (c) 2000-2012 the Libav developers
built on Oct 1 2012 15:03:26 with gcc 4.7.2
Mon Jan 13 20:13:44 2014 AVserver started.
[asf @ 0x153cac0] max_analyze_duration reached
[asf @ 0x153cac0] Estimating duration from bitrate, this may be inaccurate
Input #0, asf, from 'http://admin:gafit@192.168.1.121/videostream.asf':
Duration: N/A, start: 0.000000, bitrate: 32 kb/s
Stream #0.0: Video: mjpeg, yuvj422p, 320x240, 100 tbr, 1k tbn, 1k tbc
Stream #0.1: Audio: adpcm_ima_wav, 8000 Hz, 1 channels, s16, 32 kb/s
Incompatible pixel format 'yuvj422p' for codec 'mpeg1video', auto-selecting format 'yuv420p'
[buffer @ 0x153ec80] w:320 h:240 pixfmt:yuvj422p
[avsink @ 0x1544820] auto-inserting filter 'auto-inserted scaler 0' between the filter 'src' and the filter 'out'
[scale @ 0x1543460] w:320 h:240 fmt:yuvj422p -> w:320 h:240 fmt:yuv420p flags:0x4
[mp2 @ 0x1544aa0] Requested sampling rate unsupported using closest supported (16000)
Mon Jan 13 20:13:50 2014 Feed '/tmp/feed1.ffm.ffm' stream number does not match registered feed
Output #0, ffm, to 'http://localhost:80/feed1.ffm':
Metadata:
encoder : Lavf53.21.0
Stream #0.0: Video: mpeg1video, yuv420p, 320x240 [PAR 1:1 DAR 4:3], q=2-31, 200 kb/s, 1000k tbn, 60 tbc
Stream #0.1: Audio: mp2, 16000 Hz, 1 channels, s16, 128 kb/s
Stream mapping:
Stream #0:0 -> #0:0 (mjpeg -> mpeg1video)
Stream #0:1 -> #0:1 (adpcm_ima_wav -> mp2)
Press ctrl-c to stop encoding
Mon Jan 13 20:13:50 2014 127.0.0.1 - - [POST] "/feed1.ffm HTTP/1.1" 200 4096When I try to open this stream via VLC, using
http://192.168.1.15/test.asf
I get the following additional output
Mon Jan 13 20:17:39 2014 192.168.1.6 - - [GET] "/test.asf HTTP/1.1" 200 115s dup=12210 drop=0
Mon Jan 13 20:17:39 2014 Codec for stream 0 does not use global headers but container format requires global headers
Mon Jan 13 20:17:39 2014 Codec for stream 1 does not use global headers but container format requires global headersAnd I get nothing on VLC. I'm not quite sure what is going on or how to fix it, so any enlightning on this would be very welcome.
Thank you all in advance !
-
Malformed header from CGI script
13 janvier 2014, par user3188518This message is driving me crazy :
Malformed header from CGI script:
ffmpeg version 1.2.1 Copyright (c) 2000-2013 the FFmpeg developers
built on May 10 2013 16:31:05 with gcc 4.8.0 (GCC) 20130502 (prerelease)
configuration: --prefix=/usr --disable-debug --disable-static --enable-avresample --enable-dxva2 --enable-fontconfig --enable-gpl --enable-libass --enable-libbluray --enable-libfreetype --enable-libgsm --enable-libmodplug --enable-libmp3lame --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-librtmp --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libv4l2 --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libxvid --enable-postproc --enable-runtime-cpudetect --enable-shared --enable-vdpau --enable-version3 --enable-x11grab
libavutil 52. 18.100 / 52. 18.100
libavcodec 54. 92.100 / 54. 92.100
libavformat 54. 63.104 / 54. 63.104
libavdevice 54. 3.103 / 54. 3.103
libavfilter 3. 42.103 / 3. 42.103
libswscale 2. 2.100 / 2. 2.100
libswresample 0. 17.102 / 0. 17.102
libpostproc 52. 2.100 / 52. 2.100
Guessed Channel Layout for Input Stream #0.0 : stereo
Input #0, wav, from '/projekt/aplikacja/app/92ed9478ecfa4a4dfb176f417d4ef66c/2014-01-12-220148_sample_1.wav':
Duration: 00:02:35.62, bitrate: 1411 kb/s
Stream #0:0: Audio: pcm_s16le ([1][0][0][0] / 0x0001), 44100 Hz, stereo, s16, 1411 kb/s
Output #0, wav, to '/projekt/aplikacja/app/webroot/files/preview/2014-01-12-234038_52d327f6b2939.wav':
Metadata:
ISFT : Lavf54.63.104
Stream #0:0: Audio: pcm_s16le ([1][0][0][0] / 0x0001), 44100 Hz, stereo, 1411 kb/s
Stream mapping:
Stream #0:0 -> #0:0 (copy)
Press [q] to stop, [?] for help
size= 864kB time=00:00:05.01 bitrate=1411.3kbits/s
video:0kB audio:864kB subtitle:0 global headers:0kB muxing overhead 0.009042%
Status: 302
Location: http://www.example.org/
Content-type: text/htmlAfter executing this function :
public function createpreview(){
if ($this->request->is('post')) {
foreach($this->request->data['TrackId'] as $key => $value){
$TrackId[] = $key;
}
$this->Track->recursive = -1;
$view = $this->Track->find('all', array(
'conditions' => array(
"Track.id" => $TrackId
)));
ini_set('date.timezone', 'Europe/London');
foreach ($view as $v){
$comand_1 = 'ffmpeg -i '.APP.'92ed9478ecfa4a4dfb176f417d4ef66c'.DS. $v['Track']['filename'].' 2>&1';
$time_data = shell_exec($comand_1);
$search = '/Duration: (.*?),/';
$duration = preg_match($search, $time_data, $matches, PREG_OFFSET_CAPTURE, 3);
$time = explode('.', $matches[1][0]);
$time = explode(":", $time[0]);
$seconds = $time[0]*3600 + $time[1]*60 + $time[2];
if ($seconds >= 30){
$now = date('Y-m-d-His');
$prew_file_name = $now .'_'. uniqid().'.wav';
$comand_2 = 'ffmpeg -ss 00:00:25.000 -analyzeduration 99999999 -i '.APP.'92ed9478ecfa4a4dfb176f417d4ef66c'.DS. $v['Track']['filename'].' -t 5 -c:v copy -c:a copy '.WWW_ROOT.'files'.DS.'preview'.DS.$prew_file_name;
$t = shell_exec($comand_2);
$this->Track->updateAll(array('Track.preview' => "'.$prew_file_name.'"), array('Track.id' => $v['Track']['id']));
}
}
}
header('Location: http://www.example.org/');
// $this->redirect(array('controller'=>'albums', 'action'=>'menage_index'));
}As far as i know this shell_exec($comand_2) couses error (after i comment it out, it redirects me correctly).Googling this didn't gave me answers, the wierd part is previews aka shell_exec($comand_2) are made and fine, i just can't get it to redirect me. I tried non cake way but it doesn't work either.
What I'm doing wrong ?