
Recherche avancée
Médias (91)
-
Head down (wav version)
26 septembre 2011, par
Mis à jour : Avril 2013
Langue : English
Type : Audio
-
Echoplex (wav version)
26 septembre 2011, par
Mis à jour : Avril 2013
Langue : English
Type : Audio
-
Discipline (wav version)
26 septembre 2011, par
Mis à jour : Avril 2013
Langue : English
Type : Audio
-
Letting you (wav version)
26 septembre 2011, par
Mis à jour : Avril 2013
Langue : English
Type : Audio
-
1 000 000 (wav version)
26 septembre 2011, par
Mis à jour : Avril 2013
Langue : English
Type : Audio
-
999 999 (wav version)
26 septembre 2011, par
Mis à jour : Avril 2013
Langue : English
Type : Audio
Autres articles (100)
-
MediaSPIP 0.1 Beta version
25 avril 2011, parMediaSPIP 0.1 beta is the first version of MediaSPIP proclaimed as "usable".
The zip file provided here only contains the sources of MediaSPIP in its standalone version.
To get a working installation, you must manually install all-software dependencies on the server.
If you want to use this archive for an installation in "farm mode", you will also need to proceed to other manual (...) -
MediaSPIP version 0.1 Beta
16 avril 2011, parMediaSPIP 0.1 beta est la première version de MediaSPIP décrétée comme "utilisable".
Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
Pour avoir une installation fonctionnelle, il est nécessaire d’installer manuellement l’ensemble des dépendances logicielles sur le serveur.
Si vous souhaitez utiliser cette archive pour une installation en mode ferme, il vous faudra également procéder à d’autres modifications (...) -
Amélioration de la version de base
13 septembre 2013Jolie sélection multiple
Le plugin Chosen permet d’améliorer l’ergonomie des champs de sélection multiple. Voir les deux images suivantes pour comparer.
Il suffit pour cela d’activer le plugin Chosen (Configuration générale du site > Gestion des plugins), puis de configurer le plugin (Les squelettes > Chosen) en activant l’utilisation de Chosen dans le site public et en spécifiant les éléments de formulaires à améliorer, par exemple select[multiple] pour les listes à sélection multiple (...)
Sur d’autres sites (12980)
-
Can not add thumbnail image to MP4 using FFMPEG CLI
5 novembre 2019, par Youssof H.After searching for hours, about the easiest solution for adding a thumbnail to an MP4 using a CLI, I came back to the start "FFMPEG". Though I skipped it at first wishing I will get a working tool but no, I will stick to "FFMPEG".
Even after updating the repository ==> Same issue.
I followed the exact code present at the official documentation that says :
ffmpeg -i path/to/in.mp4 -i path/to/IMAGE.png -map 0 -map 1 -c copy -c:v:1 png -disposition:v:1 attached_pic path/to/out.mp4
The following error log shows :
Stream mapping:
Stream #0:0 -> #0:0 (copy)
Stream #0:1 -> #0:1 (copy)
Stream #1:0 -> #0:2 (mjpeg (native) -> png (native))
Press [q] to stop, [?] for help
[swscaler @ 0x1fd0860] deprecated pixel format used, make sure you did set range correctly
[swscaler @ 0x1fd0860] No accelerated colorspace conversion found from yuv420p to rgb24.
[mp4 @ 0x1f747e0] track 1: codec frame size is not set
[mp4 @ 0x1f747e0] opus in MP4 support is experimental, add '-strict -2' if you want to use it.
Could not write header for output file #0 (incorrect codec parameters ?): Experimental feature
Error initializing output stream 0:2 --
Conversion failed!I have no idea how to fix this. I read the issues forum of the website but I did not find a similar issue. So I hope you guys will give a hand.
Any suggested edits will be taken into consideration.
Edit1 :
Test1 : I brought an image(thumbnail) from the video itself and ran the command.
Test2 : I brought a unique image(thumbnail) with different resolutions than the video yet the same error appears.
==>Useless
Edit2 :
First :
After fixing my command to be like this
ffmpeg -i path/to/in.mp4 -i path/to/IMAGE.png -map 0 -map 1 -c copy -c:v:1 png -disposition:v:1 attached_pic -strict -2 path/to/out.mp4
I viewed the thumbnail using VLC (video player) so it showed up at first. But when I replaced the video and the thumbnail image with others I ran the command it runned smoothly, untill I viewed thumbnail again using VLC it showed the old thumbnail image it seemed to be cached somewhere during "FFMPEG" process. I had to delete the folder and make a new one in order to update the new thumbnail, but again it "caches" the first thumbnail used and shows it in VLC.Is it an issue from VLC or the "FFMPEG" is doing something weird ?
Second :
After I had the thumbnail showing up in VLC I wanted to test this feature by sending it to a contact on WhatsApp but it didn’t show. After a little search, I realized it might be connected to "og:image" metadata. Is there a way to edit this using CLI ?
Third :
Further, the video embedded with a thumbnail doesn’t play on Windows nor on iPhone nor on Android. When I open this using windows media player it says
Windows Media Player cannot play the file. The Player might not support the file type or might not support the codec that was used to compress the file.
From here I think there is something I have to do with the codec.
Note : the thumbnail shows in Windows File Explorer (but can not play video)
Do you have any idea ?
-
Reading RTSP stream with FFMpeg library - how to use avcodec_open2 ?
29 avril 2015, par AbstractionWhile trying to read rtsp stream I get some problems, with code and documentation alike. Short description : whatever I do,
avcodec_open2
either fails (saying "codec type or id mismatches") orwidth
andheight
of codec context after the call are 0 (thus making further code useless). Stream itself can be opened normally by VLC player andav_dump_format()
displays correct info. My code is based on technique answer to this question.Long description : my code is in C#, but here is C++-equivalent of FFMpeg calls (I actually reduced my code to this minimum and problem persists) :
av_register_all();
avformat_network_init(); //return code ignored
AVFormatContext* formatContext = avformat_alloc_context();
if (avformat_open_input(&formatContext, stream_path, null, null) != 0) {
return;
}
if (avformat_find_stream_info(formatContext, null) < 0) {
return;
}
int videoStreamIndex = 0;
for (int i = 0; i < formatContext->nb_streams; ++i) {
AVStream* s = formatContext->streams[i];
if (s->codec == null) continue;
AVCodecContext c = *(s->codec);
if (c.codec_type == AVMEDIA_TYPE_VIDEO) videoStreamIndex = i;
}
//start reading packets from stream and write them to file
//av_read_play(formatContext); //return code ignored
//this call would print "method PLAY failed: 455 Method Not Valid in This State"
//seems to be the case that for rtsp stream it isn't needed
AVCodec* codec = null;
codec = avcodec_find_decoder(AV_CODEC_ID_H264);
if (codec == null) {
return;
}
AVCodecContext* codecContext = avcodec_alloc_context3(null);
avcodec_get_context_defaults3(codecContext, codec);//return code ignored
avcodec_copy_context(codecContext, formatContext->streams[videoStreamIndex]->codec); //return code ignored
av_dump_format(formatContext, videoStreamIndex, stream_path, 0);
if (avcodec_open2(codecContext, codec, null) < 0) {
return;
}The code actually uses DLL version of FFMpeg library ; avcodec-55.dll and avformat-55.dll are used.
Documentation says something weird about which calls can be made in which succession (that
copy_context
should be called beforeget_context_defaults
), current code is left close as possible to technique version. As written, it results in non-zero return fromavcodec_open2
with "codec type or id mismatches" message. Changing the order does little good : nowavcodec_open2
executes successfully, but bothcodecContext->width
andcodecContext->height
are 0 afterwards.Also documentation doesn’t mention which is default value for the third argument of
avcodec_open2
should be, but source code seems to taking into account thatoptions
can be NULL.Output of
av_dump_format
is as follows :Input #0, rtsp, from 'rtsp://xx.xx.xx.xx:xx/video.pro1':
Metadata:
title : QStream
comment : QStreaming Media
Duration: N/A, start: 0.000000, bitrate: 64 kb/s
Stream #0:0: Video: h264 (Baseline), yuvj420p(pc), 1920x1080, 30 fps, 25 tbr, 90k tbn, 60 tbc
Stream #0:1: Audio: pcm_mulaw, 8000 Hz, 1 channels, s16, 64 kb/s -
Modifying incorrect h.264 dimension in existing video file
11 juin 2015, par RichyJAfter searching a lot, I’m more confused than ever !! To summarise :
I recorded a video using my HTC One M8, using 1920x1088 resolution, and it came out fine. The next day, for some reason, in the settings I changed to 1920x1080 and the next video was weird - green bar across the top, diagonal green lines throughout and odd colour stripes. The underlying image was fine, although there seem to be some ’frame jumps’ at times. Unfortunately, this second video contained a section I would like to keep, so I’m trying to fix it...
I’ve learned a bit about AVC/H.264, but it’s pretty confusing. Essentially, I wonder whether I can just change the ’1080’ in the file info to ’1088’ and salvage the footage - there’s no audio to worry about. I read that since 1080 is not directly divisible by 16, most encoders actually do 1088 then the player discards the remaining 8 lines at playback time. I wonder whether this is the root of the problem ? I tried to get into NALs, SPS/PPS etc, but couldn’t really fathom whether this was even relevant to my problem. A hex search didn’t even find anything that looked like the NALs given as examples elsewhere :
What does this NAL header data mean ?
Fetching dimensions of a video
I’ve loaded both files into a Hex editor and compared as best I can (around the moov and avcC parts), but haven’t fixed it yet. One of the single byte changes I made and saved to a new ’test’ file brought up additional info in the mediainfo program, showing that the original recording was at 1088 - this hadn’t been there before, but it still played wrongly. I found info regarding the encoding of height and width (units-1 * 16) but couldn’t work out how to use this info in practice.
I tried ffmpeg and dumping to raw video, but couldn’t make this play at all as a yuv file.
So, my question is, will I be able to change just one byte (or a few) in the file, to make it read as 1088 to the player, or am I looking in totally the wrong direction ?!? Is this even possible ? As I say, the actual images look intact throughout, just the colours are wrong and the lines are there, so I believe it’s something to do with YCrCb problems, but at this point, I’m lost...
I know this isn’t specifically about programming, but the above links were all from this site, so thought it might be OK to ask here. Any help would be much appreciated !!
I’ve recreated the conditions and done 2 short clips at 1080 and 1088 for you to see the problem but as I’m new, I can’t post them here yet. They’re on my Photobucket page if you are willing to look at them (hope this isn’t breaking the rules !!). The blueish line at the bottom is the windowsill...