
Recherche avancée
Médias (3)
-
Elephants Dream - Cover of the soundtrack
17 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Image
-
Valkaama DVD Label
4 octobre 2011, par
Mis à jour : Février 2013
Langue : English
Type : Image
-
Publier une image simplement
13 avril 2011, par ,
Mis à jour : Février 2012
Langue : français
Type : Video
Autres articles (111)
-
Gestion des droits de création et d’édition des objets
8 février 2011, parPar défaut, beaucoup de fonctionnalités sont limitées aux administrateurs mais restent configurables indépendamment pour modifier leur statut minimal d’utilisation notamment : la rédaction de contenus sur le site modifiables dans la gestion des templates de formulaires ; l’ajout de notes aux articles ; l’ajout de légendes et d’annotations sur les images ;
-
Dépôt de média et thèmes par FTP
31 mai 2013, parL’outil MédiaSPIP traite aussi les média transférés par la voie FTP. Si vous préférez déposer par cette voie, récupérez les identifiants d’accès vers votre site MédiaSPIP et utilisez votre client FTP favori.
Vous trouverez dès le départ les dossiers suivants dans votre espace FTP : config/ : dossier de configuration du site IMG/ : dossier des média déjà traités et en ligne sur le site local/ : répertoire cache du site web themes/ : les thèmes ou les feuilles de style personnalisées tmp/ : dossier de travail (...) -
Keeping control of your media in your hands
13 avril 2011, parThe vocabulary used on this site and around MediaSPIP in general, aims to avoid reference to Web 2.0 and the companies that profit from media-sharing.
While using MediaSPIP, you are invited to avoid using words like "Brand", "Cloud" and "Market".
MediaSPIP is designed to facilitate the sharing of creative media online, while allowing authors to retain complete control of their work.
MediaSPIP aims to be accessible to as many people as possible and development is based on expanding the (...)
Sur d’autres sites (10398)
-
UWP C# and Windows Runtime Component C++ Permission Denied error when opening file
29 décembre 2020, par Surya SolankiI have developed a UWP app in C# which contains a Windows Runtime Component C++ project. the app allows the user to choose an mp4 file and passes this file to the c++ code, which then utilizes ffmpeg libraries to retrieve the presentation time stamps of a video file and output them to a file.


the issue i'm facing is that the c++ code is not able to open the mp4 file when using the
avformat_open_input
function :

int PTSExtraction::parse_file(Platform::String^ filename)
{
 int ret = 0;
 AVPacket pkt = { 0 };


 std::wstring fileNameW(filename->Begin());
 std::string fileNameA(fileNameW.begin(), fileNameW.end());
 const wchar_t* w_chars = fileNameW.c_str();
 src_filename = fileNameA.c_str(); 

 if (avformat_open_input(&fmt_ctx, src_filename, NULL, NULL) < 0) {
 fprintf(stderr, "Could not open source file %s\n", src_filename);
 return 1; 
 }
 // rest of code 
}



the error received by
avformat_open_input
isPermission Denied
. I cannot even open a random text file in this function by doing :

ofstream output; 
output.open("output.txt");



I realize there are file system permissions that are blocking the C++ component of my uwp app from opening files. here are the things i have tried so far :


- 

- i have enabled broadFileSystemAccess in the Package.appxmanifest (https://blogs.windows.com/windowsdeveloper/2018/05/18/console-uwp-applications-and-file-system-access/) - in the Capabilities section of the Package.appxmanifest file I've allowed access to Location, Pictures Library, and Videos Library.
- I've checked the File System Privacy Settings on my computer and enabled my app to access the File System.
- I've tried moving the mp4 file to various locations (Documents, Pictures Library, Videos Library) to see if the C++ component has access to these locations.
- I've tried the solution from this post : Qt WinRT App cannot access file permission denied.










None of these allow the C++ component to open any files. i would really appreciate if anyone has a solution for this problem.


-
hls fails to play m3u8 playlist with videojs
9 novembre 2020, par charlieI created an hls stream from yuv frames with ffmpeg which appears to work just fine. It creates a playlist and updates that, and all .ts files as expected. However even videojs refuses to play it, and I really run out of ideas, probably missing the obvious ?


First, the m3u8 list which is continuously updated :


#EXTM3U
#EXT-X-VERSION:3
#EXT-X-TARGETDURATION:2
#EXT-X-MEDIA-SEQUENCE:190
#EXTINF:2.000000,
test190.ts
#EXTINF:2.000000,
test191.ts
#EXTINF:2.000000,
test192.ts
#EXTINF:2.000000,
test193.ts
#EXTINF:2.000000,
test194.ts



Those .ts files exist and have sizes of approx 250 kBytes.
Then, I open this standard videojs html file (residing in the same directory) :








 


 <h1>VSTream</h1>

 
 <source src="test.m3u8" type="application/x-mpegURL">
 
 
 <code class="echappe-js"><script src='http://stackoverflow.com/feeds/tag/video.min.js'></script>

<script src='http://stackoverflow.com/feeds/tag/videojs-http-streaming.min.js'></script>

 
<script>&#xA; var player = videojs(&#x27;my_video_1&#x27;);&#xA; </script>

 




I open this in Firefox (or Chrome, or Edge, none works) and use its debugger which in the console shows :




VIDEOJS : WARN : A plugin named "reloadSourceOnError" already exists.
You may want to avoid re-registering plugins ! video.min.js:12:977
Specified “type” attribute of “application/x-mpegURL” is not
supported. Load of media resource test.m3u8 failed. vstream.html All
candidate resources failed to load. Media load paused. vstream.html
XML Parsing Error : syntax error Location : file :///C :/test/test.m3u8
Line Number 1, Column 1 : 2 test.m3u8:1:1 MouseEvent.mozPressure is
deprecated. Use PointerEvent.pressure instead. video.min.js:12:9031
VIDEOJS : ERROR : (CODE:3 MEDIA_ERR_DECODE) Playback cannot continue. No
available working or supported playlists. Object code : 3, message :
"Playback cannot continue. No available working or supported
playlists." video.min.js:12:977




This doesn't make much sense to me. Why would it throw an XML parsing error for an m3u8 file ? Of course, the MEDIA_ERR_DECODE points in some direction, but the same problem persists with fMP4 files.


The relevant ffmpeg c++ code (format is "hls" and formatContext works well in other scenarios, gop is 2) :


AVDictionary* options = 0;
 if (fragmented)
 {
 // type
 if (codecID == AV_CODEC_ID_H264)
 av_dict_set (&options, "hls_segment_type", "fmp4", 0);
 else
 av_dict_set (&options, "hls_segment_type", "mpegts", 0);

 av_dict_set (&options, "hls_time", "2.0", 0);
 av_dict_set_int (&options, "hls_list_size", 5, 0);
 av_dict_set (&options, "hls_flags", "delete_segments", 0);
 }

 int ret = avformat_write_header (formatContext, &options);



...which returns success. Then writing frames


int ret = avcodec_send_frame (videoStream->codecContext, frame);
 av_init_packet (avPacket);
 AVRational timeBase = videoStream->getTimeBase ();
 avPacket->stream_index = streams.indexOf (videoStream);
 ret = avcodec_receive_packet (videoStream->codecContext, avPacket);
 avPacket->duration = av_rescale_q (1, videoStream->codecContext->time_base, videoStream->getTimeBase ());
 pts += avPacket->duration;
 avPacket->pts = pts;
 avPacket->dts = pts; // AV_NOPTS_VALUE;
 ret = av_interleaved_write_frame (formatContext, avPacket);



(videoStream here is an internal object representing the avstream).
I've omitted error checks for clarity. All return values show success.
Thanks for any help on this !


-
Running ffmpeg via PHP
11 mars 2020, par FionaFSo the end goal is to have a php script that, given a list of images, will automatically create a slideshow video with transitions and text overlays and maybe an audio track as well.
I’m competent in coding PHP but not experienced in command line stuff.
We have a dedicated server and I got hosting company to install ffmpeg for me.
So I thought I’d start simple and slowly build up to ultimate goal. But I’m really struggling. I’ve spent a couple of days trying all sorts of things with very little success.
I found this post with some excellent examples https://superuser.com/questions/833232/create-video-with-5-images-with-fadein-out-effect-in-ffmpeg but I can’t get any of them to work. Which makes me think that I’m doing something fundamentally wrong.
So this does work for me - I get a nice little 30 sec video slideshow of 6 images displaying for 5 secs each :
$ffmpeg="/usr/bin/ffmpeg";
exec($ffmpeg.' -f concat -safe 0 -i input.txt -c:v libx264 -r 30 -pix_fmt yuv420p -y out.mp4 2>&1', $output);
var_dump($output);and this is input.txt
file /home/webvivre/public_html/videos/test/i1.jpg
duration 5
file /home/webvivre/public_html/videos/test/i2.jpg
duration 5
file /home/webvivre/public_html/videos/test/i3.jpg
duration 5
file /home/webvivre/public_html/videos/test/i4.jpg
duration 5
file /home/webvivre/public_html/videos/test/i5.jpg
duration 5
file /home/webvivre/public_html/videos/test/i6.jpg
duration 5But this (basically taken from example in link above - have only changed image names and ffmpeg location) doesn’t work for me :
$code="/usr/bin/ffmpeg -y -loop 1 -i i1.jpg -loop 1 -i i2.jpg -loop 1 -i i3.jpg -filter_complex \" [0:v]zoompan=z='min(zoom+0.0015,1.5)':d=125,trim=duration=5,blend=all_expr='A*(if(gte(T,0.5),1,T/0.5))+B*(1-(if(gte(T,0.5),1,T/0.5)))',setpts=PTS-STARTPTS[v0]; [1:v]zoompan=z='min(zoom+0.0015,1.5)':d=125,trim=duration=5,blend=all_expr='A*(if(gte(T,0.5),1,T/0.5))+B*(1-(if(gte(T,0.5),1,T/0.5)))',setpts=PTS-STARTPTS[v1]; [2:v]zoompan=z='min(zoom+0.0015,1.5)':d=125,trim=duration=5,blend=all_expr='A*(if(gte(T,0.5),1,T/0.5))+B*(1-(if(gte(T,0.5),1,T/0.5)))',setpts=PTS-STARTPTS[v2]; [v0][v1][v2] concat=n=3:v=1:a=0, format=yuv420p[v]\" -map '[v]' -c:v libx264 -pix_fmt yuvj420p -q:v 1 out.mp4 2>&1";
exec($code,$output);
var_dump($output);This is the output :
array(25) { [0]=> string(67) "ffmpeg version 2.8.15 Copyright (c) 2000-2018 the FFmpeg developers" [1]=> string(56) " built with gcc 4.8.5 (GCC) 20150623 (Red Hat 4.8.5-36)" [2]=> string(1147) " configuration: --prefix=/usr --bindir=/usr/bin --datadir=/usr/share/ffmpeg --incdir=/usr/include/ffmpeg --libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64 --optflags='-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic' --extra-ldflags='-Wl,-z,relro ' --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libvo-amrwbenc --enable-version3 --enable-bzlib --disable-crystalhd --enable-gnutls --enable-ladspa --enable-libass --enable-libcdio --enable-libdc1394 --enable-libfdk-aac --enable-nonfree --disable-indev=jack --enable-libfreetype --enable-libgsm --enable-libmp3lame --enable-openal --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-libschroedinger --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libvorbis --enable-libv4l2 --enable-libx264 --enable-libx265 --enable-libxvid --enable-x11grab --enable-avfilter --enable-avresample --enable-postproc --enable-pthreads --disable-static --enable-shared --enable-gpl --disable-debug --disable-stripping --shlibdir=/usr/lib64 --enable-runtime-cpudetect" [3]=> string(40) " libavutil 54. 31.100 / 54. 31.100" [4]=> string(40) " libavcodec 56. 60.100 / 56. 60.100" [5]=> string(40) " libavformat 56. 40.101 / 56. 40.101" [6]=> string(40) " libavdevice 56. 4.100 / 56. 4.100" [7]=> string(40) " libavfilter 5. 40.101 / 5. 40.101" [8]=> string(40) " libavresample 2. 1. 0 / 2. 1. 0" [9]=> string(40) " libswscale 3. 1.101 / 3. 1.101" [10]=> string(40) " libswresample 1. 2.101 / 1. 2.101" [11]=> string(40) " libpostproc 53. 3.100 / 53. 3.100" [12]=> string(38) "[mjpeg @ 0x183c720] Changeing bps to 8" [13]=> string(32) "Input #0, image2, from 'i1.jpg':" [14]=> string(61) " Duration: 00:00:00.04, start: 0.000000, bitrate: 33777 kb/s" [15]=> string(128) " Stream #0:0: Video: mjpeg, yuvj420p(pc, bt470bg/unknown/unknown), 1000x750 [SAR 1:1 DAR 4:3], 25 fps, 25 tbr, 25 tbn, 25 tbc" [16]=> string(38) "[mjpeg @ 0x18427c0] Changeing bps to 8" [17]=> string(32) "Input #1, image2, from 'i2.jpg':" [18]=> string(61) " Duration: 00:00:00.04, start: 0.000000, bitrate: 41896 kb/s" [19]=> string(132) " Stream #1:0: Video: mjpeg, yuvj444p(pc, bt470bg/unknown/unknown), 1000x750 [SAR 300:300 DAR 4:3], 25 fps, 25 tbr, 25 tbn, 25 tbc" [20]=> string(38) "[mjpeg @ 0x1849fa0] Changeing bps to 8" [21]=> string(32) "Input #2, image2, from 'i3.jpg':" [22]=> string(61) " Duration: 00:00:00.04, start: 0.000000, bitrate: 34776 kb/s" [23]=> string(132) " Stream #2:0: Video: mjpeg, yuvj444p(pc, bt470bg/unknown/unknown), 1000x750 [SAR 300:300 DAR 4:3], 25 fps, 25 tbr, 25 tbn, 25 tbc" [24]=> string(81) "Cannot find a matching stream for unlabeled input pad 1 on filter Parsed_blend_10" }
And for reference, this is info provided to me by hosting company after installing ffmpeg for me :
svr01~ # ffmpeg
ffmpeg version 2.8.15 Copyright (c) 2000-2018 the FFmpeg developers
built with gcc 4.8.5 (GCC) 20150623 (Red Hat 4.8.5-36)
configuration: --prefix=/usr --bindir=/usr/bin --datadir=/usr/share/ffmpeg --incdir=/usr/include/ffmpeg --libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64 --optflags='-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic' --extra-ldflags='-Wl,-z,relro ' --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libvo-amrwbenc --enable-version3 --enable-bzlib --disable-crystalhd --enable-gnutls --enable-ladspa --enable-libass --enable-libcdio --enable-libdc1394 --enable-libfdk-aac --enable-nonfree --disable-indev=jack --enable-libfreetype --enable-libgsm --enable-libmp3lame --enable-openal --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-libschroedinger --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libvorbis --enable-libv4l2 --enable-libx264 --enable-libx265 --enable-libxvid --enable-x11grab --enable-avfilter --enable-avresample --enable-postproc --enable-pthreads --disable-static --enable-shared --enable-gpl --disable-debug --disable-stripping --shlibdir=/usr/lib64 --enable-runtime-cpudetect
libavutil 54. 31.100 / 54. 31.100
libavcodec 56. 60.100 / 56. 60.100
libavformat 56. 40.101 / 56. 40.101
libavdevice 56. 4.100 / 56. 4.100
libavfilter 5. 40.101 / 5. 40.101
libavresample 2. 1. 0 / 2. 1. 0
libswscale 3. 1.101 / 3. 1.101
libswresample 1. 2.101 / 1. 2.101
libpostproc 53. 3.100 / 53. 3.100
Hyper fast Audio and Video encoderIf someone could just shove me in the right direction to get the above working I’d be very grateful. I just know it’s going to end up being something really simple.