
Recherche avancée
Médias (1)
-
The Slip - Artworks
26 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Texte
Autres articles (78)
-
Multilang : améliorer l’interface pour les blocs multilingues
18 février 2011, parMultilang est un plugin supplémentaire qui n’est pas activé par défaut lors de l’initialisation de MediaSPIP.
Après son activation, une préconfiguration est mise en place automatiquement par MediaSPIP init permettant à la nouvelle fonctionnalité d’être automatiquement opérationnelle. Il n’est donc pas obligatoire de passer par une étape de configuration pour cela. -
Publier sur MédiaSpip
13 juin 2013Puis-je poster des contenus à partir d’une tablette Ipad ?
Oui, si votre Médiaspip installé est à la version 0.2 ou supérieure. Contacter au besoin l’administrateur de votre MédiaSpip pour le savoir -
Emballe médias : à quoi cela sert ?
4 février 2011, parCe plugin vise à gérer des sites de mise en ligne de documents de tous types.
Il crée des "médias", à savoir : un "média" est un article au sens SPIP créé automatiquement lors du téléversement d’un document qu’il soit audio, vidéo, image ou textuel ; un seul document ne peut être lié à un article dit "média" ;
Sur d’autres sites (8100)
-
how to use gl-transition in ffmpeg ?
19 avril 2020, par ZeddI tried to use gl-transition with the following method.



https://github.com/transitive-bullshit/ffmpeg-gl-transition



But I followed the instructions many times without success.
I think it may be that this library is no longer maintained



Is there any other way to use gl-transition in the form of ffmpeg filter ?


-
streaming data with ffmpeg using pipe - stream never starts
9 novembre 2022, par tamirgIm fetching some video data, and trying to stream it using ffmpeg. what i do is create an ffmpeg process, set it to get info from '-', and then when i fetch the video data i write it to the process STDIN.


My issue is that the steaming procces sometimes starts, and sometimes doesnt start. it really seems random (will add the ffmpeg logs at the end).
But if i save the entire data into a file, and then use ffplay on that file, it works perfectly fine, all the time.


So im guessing something in the data is causing some issues with ffmpeg usage with pipe. The logs indicate that there are some issues with the DTS, but i dont know if thats the reason that stream never plays, and what can be done to fix that.


I cant really understand the issue from the logs, but maybe they indicate what is the issue exactly ?


logs :


When the stream proccess doesnt start and doesnt work, those are the logs :


[mpeg @ 0x7fc7b63ef840] Format mpeg probed with size=262144 and score=52
[mpeg @ 0x7fc7b63ef840] Before avformat_find_stream_info() pos: 6 bytes read:263756 seeks:0 nb_streams:0
[NULL @ 0x7fc7b63eec00] nal_unit_type: 32(VPS), nuh_layer_id: 0, temporal_id: 0
[NULL @ 0x7fc7b63eec00] nal_unit_type: 33(SPS), nuh_layer_id: 0, temporal_id: 0
[NULL @ 0x7fc7b63eec00] nal_unit_type: 34(PPS), nuh_layer_id: 0, temporal_id: 0
[NULL @ 0x7fc7b63eec00] nal_unit_type: 19(IDR_W_RADL), nuh_layer_id: 0, temporal_id: 0
[NULL @ 0x7fc7b63eec00] Decoding VPS
[NULL @ 0x7fc7b63eec00] Main profile bitstream
[NULL @ 0x7fc7b63eec00] Decoding SPS
[NULL @ 0x7fc7b63eec00] Main profile bitstream
[NULL @ 0x7fc7b63eec00] Decoding VUI
[NULL @ 0x7fc7b63eec00] Decoding PPS
[extract_extradata @ 0x7fc7b63f2140] nal_unit_type: 32(VPS), nuh_layer_id: 0, temporal_id: 0
[extract_extradata @ 0x7fc7b63f2140] nal_unit_type: 33(SPS), nuh_layer_id: 0, temporal_id: 0
[extract_extradata @ 0x7fc7b63f2140] nal_unit_type: 34(PPS), nuh_layer_id: 0, temporal_id: 0
[extract_extradata @ 0x7fc7b63f2140] nal_unit_type: 19(IDR_W_RADL), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7fc7b63eec00] nal_unit_type: 32(VPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7fc7b63eec00] nal_unit_type: 33(SPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7fc7b63eec00] nal_unit_type: 34(PPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7fc7b63eec00] Decoding VPS
[hevc @ 0x7fc7b63eec00] Main profile bitstream
[hevc @ 0x7fc7b63eec00] Decoding SPS
[hevc @ 0x7fc7b63eec00] Main profile bitstream
[hevc @ 0x7fc7b63eec00] Decoding VUI
[hevc @ 0x7fc7b63eec00] Decoding PPS
[hevc @ 0x7fc7b63eec00] nal_unit_type: 32(VPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7fc7b63eec00] nal_unit_type: 33(SPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7fc7b63eec00] nal_unit_type: 34(PPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7fc7b63eec00] Decoding VPS
[hevc @ 0x7fc7b63eec00] Main profile bitstream
[hevc @ 0x7fc7b63eec00] Decoding SPS
[hevc @ 0x7fc7b63eec00] Main profile bitstream
[hevc @ 0x7fc7b63eec00] Decoding VUI
[hevc @ 0x7fc7b63eec00] Decoding PPS
[mpeg @ 0x7fc7b63ef840] Non-increasing DTS in stream 1: packet 3 with DTS 150119711008467, packet 4 with DTS 150119711008467
[mpeg @ 0x7fc7b63ef840] Non-increasing DTS in stream 1: packet 5 with DTS 150119711008469, packet 6 with DTS 150119711008469
[hevc @ 0x7fc7b63eec00] nal_unit_type: 32(VPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7fc7b63eec00] nal_unit_type: 33(SPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7fc7b63eec00] nal_unit_type: 34(PPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7fc7b63eec00] nal_unit_type: 19(IDR_W_RADL), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7fc7b63eec00] Decoding VPS
[hevc @ 0x7fc7b63eec00] Main profile bitstream
[hevc @ 0x7fc7b63eec00] Decoding SPS
[hevc @ 0x7fc7b63eec00] Main profile bitstream
[hevc @ 0x7fc7b63eec00] Decoding VUI
[hevc @ 0x7fc7b63eec00] Decoding PPS



After the last log line, nothing happens, and no more log lines appear.


When the process actually starts and works fine, those are the logs :


[mpeg @ 0x7f5475d69840] Format mpeg probed with size=524288 and score=52
[mpeg @ 0x7f5475d69840] Before avformat_find_stream_info() pos: 6 bytes read:526296 seeks:0 nb_streams:0
[mpeg @ 0x7f5475d69840] Non-increasing DTS in stream 1: packet 2 with DTS 150120249571596, packet 3 with DTS 150120249571596
[mpeg @ 0x7f5475d69840] Non-increasing DTS in stream 1: packet 4 with DTS 150120249571598, packet 5 with DTS 150120249571598
[mpeg @ 0x7f5475d69840] Non-increasing DTS in stream 1: packet 5 with DTS 150120249571598, packet 6 with DTS 150120249571598
[NULL @ 0x7f5475d68c00] nal_unit_type: 32(VPS), nuh_layer_id: 0, temporal_id: 0
[NULL @ 0x7f5475d68c00] nal_unit_type: 33(SPS), nuh_layer_id: 0, temporal_id: 0
[NULL @ 0x7f5475d68c00] nal_unit_type: 34(PPS), nuh_layer_id: 0, temporal_id: 0
[NULL @ 0x7f5475d68c00] nal_unit_type: 19(IDR_W_RADL), nuh_layer_id: 0, temporal_id: 0
[NULL @ 0x7f5475d68c00] Decoding VPS
[NULL @ 0x7f5475d68c00] Main profile bitstream
[NULL @ 0x7f5475d68c00] Decoding SPS
[NULL @ 0x7f5475d68c00] Main profile bitstream
[NULL @ 0x7f5475d68c00] Decoding VUI
[NULL @ 0x7f5475d68c00] Decoding PPS
[extract_extradata @ 0x7f5475d6c140] nal_unit_type: 32(VPS), nuh_layer_id: 0, temporal_id: 0
[extract_extradata @ 0x7f5475d6c140] nal_unit_type: 33(SPS), nuh_layer_id: 0, temporal_id: 0
[extract_extradata @ 0x7f5475d6c140] nal_unit_type: 34(PPS), nuh_layer_id: 0, temporal_id: 0
[extract_extradata @ 0x7f5475d6c140] nal_unit_type: 19(IDR_W_RADL), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7f5475d68c00] nal_unit_type: 32(VPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7f5475d68c00] nal_unit_type: 33(SPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7f5475d68c00] nal_unit_type: 34(PPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7f5475d68c00] Decoding VPS
[hevc @ 0x7f5475d68c00] Main profile bitstream
[hevc @ 0x7f5475d68c00] Decoding SPS
[hevc @ 0x7f5475d68c00] Main profile bitstream
[hevc @ 0x7f5475d68c00] Decoding VUI
[hevc @ 0x7f5475d68c00] Decoding PPS
[hevc @ 0x7f5475d68c00] nal_unit_type: 32(VPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7f5475d68c00] nal_unit_type: 33(SPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7f5475d68c00] nal_unit_type: 34(PPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7f5475d68c00] Decoding VPS
[hevc @ 0x7f5475d68c00] Main profile bitstream
[hevc @ 0x7f5475d68c00] Decoding SPS
[hevc @ 0x7f5475d68c00] Main profile bitstream
[hevc @ 0x7f5475d68c00] Decoding VUI
[hevc @ 0x7f5475d68c00] Decoding PPS
[hevc @ 0x7f5475d68c00] nal_unit_type: 32(VPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7f5475d68c00] nal_unit_type: 33(SPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7f5475d68c00] nal_unit_type: 34(PPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7f5475d68c00] nal_unit_type: 19(IDR_W_RADL), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7f5475d68c00] Decoding VPS
[hevc @ 0x7f5475d68c00] Main profile bitstream
[hevc @ 0x7f5475d68c00] Decoding SPS
[hevc @ 0x7f5475d68c00] Main profile bitstream
[hevc @ 0x7f5475d68c00] Decoding VUI
[hevc @ 0x7f5475d68c00] Decoding PPS
[hevc @ 0x7f5475d68c00] nal_unit_type: 1(TRAIL_R), nuh_layer_id: 0, temporal_id: 0
 Last message repeated 1 times
[mpeg @ 0x7f5475d69840] Non-increasing DTS in stream 1: packet 10 with DTS 150120249571825, packet 11 with DTS 150120249571825
[hevc @ 0x7f5475d68c00] nal_unit_type: 1(TRAIL_R), nuh_layer_id: 0, temporal_id: 0
 Last message repeated 4 times
[mpeg @ 0x7f5475d69840] Non-increasing DTS in stream 1: packet 15 with DTS 150120249571844, packet 16 with DTS 150120249571844
[hevc @ 0x7f5475d68c00] nal_unit_type: 1(TRAIL_R), nuh_layer_id: 0, temporal_id: 0
 Last message repeated 7 times
[mpeg @ 0x7f5475d69840] Non-increasing DTS in stream 1: packet 25 with DTS 150120249571878, packet 26 with DTS 150120249571878
[hevc @ 0x7f5475d68c00] nal_unit_type: 1(TRAIL_R), nuh_layer_id: 0, temporal_id: 0
 Last message repeated 7 times
[mpeg @ 0x7f5475d69840] DTS discontinuity in stream 0: packet 23 with DTS 150120249572205, packet 24 with DTS 150120249610965
[hevc @ 0x7f5475d68c00] nal_unit_type: 1(TRAIL_R), nuh_layer_id: 0, temporal_id: 0
 Last message repeated 35 times
[hevc @ 0x7f5475d68c00] nal_unit_type: 32(VPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7f5475d68c00] nal_unit_type: 33(SPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7f5475d68c00] nal_unit_type: 34(PPS), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7f5475d68c00] nal_unit_type: 19(IDR_W_RADL), nuh_layer_id: 0, temporal_id: 0
[hevc @ 0x7f5475d68c00] Decoding VPS
[hevc @ 0x7f5475d68c00] Main profile bitstream
[hevc @ 0x7f5475d68c00] Decoding SPS
[hevc @ 0x7f5475d68c00] Main profile bitstream
[hevc @ 0x7f5475d68c00] Decoding VUI
[hevc @ 0x7f5475d68c00] Decoding PPS
[hevc @ 0x7f5475d68c00] nal_unit_type: 1(TRAIL_R), nuh_layer_id: 0, temporal_id: 0
 Last message repeated 8 times
[mpeg @ 0x7f5475d69840] max_analyze_duration 5000000 reached at 5056000 microseconds st:1
[mpeg @ 0x7f5475d69840] After avformat_find_stream_info() pos: 1428588 bytes read:1428588 seeks:0 frames:152
Input #0, mpeg, from 'pipe:':
 Duration: N/A, start: 1668002773.015456, bitrate: N/A



The main issue, is that it sometimes works, sometimes doesnt work.


The ffmpeg proccess is just created by using
asyncio.create_subprocess_exec


Every time i get a video data, i pass the data to the proccess by calling
ffmpeg_process.stdin.write(data)


I believe the issue is with the data, since with video data, the whole pipeline works for me. But i cannot understand from the ffmpeg logs what is the issue exactly.


-
FFMPEG trimming video (using select between) doesn't affect overall duration
5 mai 2022, par srb7Completely new to working with FFMPEG, what I'm trying to achieve is applying overlaying graphics at certain positions and times, and cutting out sections of a single input video.


I've worked out the overlaying graphics, so this code is working :


ffmpeg -i /Users/username/projectdir/static/video.mp4 \
 -i overlay.png -i overlay2.png \
 -filter_complex "[0:v][1:v] overlay=192:108:enable='between(t, 0, 5)'[ov0]; 
 [ov0] overlay=192:108:enable='between(t, 5, 10)'" \
 -pix_fmt yuv420p output_overlayed.mp4



But when I try to cut out sections using this code :


ffmpeg -i /Users/username/projectdir/static/video.mp4 \
 -i overlay.png -i overlay2.png \
 -filter_complex "[0:v][1:v] overlay=192:108:enable='between(t, 0, 5)'[ov0]; \
 [ov0] overlay=192:108:enable='between(t, 5, 10)', \
 select='between(t,0,5)+between(t,10,15)', \
 setpts='N/FRAME_RATE/TB'" \
 -pix_fmt yuv420p output_overlayed_trimmed.mp4



It seems to cut correctly, so the original video starts playing from 0 seconds until 5 seconds and then plays from 10 seconds in until 15 seconds and cuts out. But after the point where the video cuts out it's just a black screen for the duration of the video. I can't seem to get it to work so it affects the overall duration of the video.


(The values being passed in are just examples by the way, eg. I've got it to start an overlay 5 seconds in but also cut 5 seconds in)


I have the timestamps for when the overlays should appear on the non-trimmed video, so the overlaying should happen first and then the trimming. If the video is trimmed first then the overlays will appear at the wrong times.


An alternative way of achieving this that is currently working is by performing the first line of code (which just produces a new video file with the overlay) and then separately take this new file and perform the trimming independently :


ffmpeg -ss 0 -to 5 -i /Users/username/projectdir/static/output_overlayed.mp4 \
 -ss 15 -to 20 -i /Users/username/projectdir/static/output_overlayed.mp4 \
 -filter_complex "[0][1]concat=n=2:v=1:a=1" output_trimmed.mp4



But this means working with 2 separate files and then having to remove the first after the 2nd execution is complete. Ideally I'd combine them into one command which doesn't produce multiple files.


Would appreciate any help - thanks !