
Recherche avancée
Autres articles (23)
-
MediaSPIP Core : La Configuration
9 novembre 2010, parMediaSPIP Core fournit par défaut trois pages différentes de configuration (ces pages utilisent le plugin de configuration CFG pour fonctionner) : une page spécifique à la configuration générale du squelettes ; une page spécifique à la configuration de la page d’accueil du site ; une page spécifique à la configuration des secteurs ;
Il fournit également une page supplémentaire qui n’apparait que lorsque certains plugins sont activés permettant de contrôler l’affichage et les fonctionnalités spécifiques (...) -
Les formats acceptés
28 janvier 2010, parLes commandes suivantes permettent d’avoir des informations sur les formats et codecs gérés par l’installation local de ffmpeg :
ffmpeg -codecs ffmpeg -formats
Les format videos acceptés en entrée
Cette liste est non exhaustive, elle met en exergue les principaux formats utilisés : h264 : H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10 m4v : raw MPEG-4 video format flv : Flash Video (FLV) / Sorenson Spark / Sorenson H.263 Theora wmv :
Les formats vidéos de sortie possibles
Dans un premier temps on (...) -
Les statuts des instances de mutualisation
13 mars 2010, parPour des raisons de compatibilité générale du plugin de gestion de mutualisations avec les fonctions originales de SPIP, les statuts des instances sont les mêmes que pour tout autre objets (articles...), seuls leurs noms dans l’interface change quelque peu.
Les différents statuts possibles sont : prepa (demandé) qui correspond à une instance demandée par un utilisateur. Si le site a déjà été créé par le passé, il est passé en mode désactivé. publie (validé) qui correspond à une instance validée par un (...)
Sur d’autres sites (3072)
-
When MP4 files encoded with H264 are set to slices=n, where can I find out how many slices the current NALU is ?
17 novembre 2023, par Gaowan LiangI am doing an experiment on generating thumbnails for web videos. I plan to extract I-frames from the binary stream by simulating the working principle of the decoder, and add the PPS and SPS information of the original video to form the H264 raw information, which is then handed over to ffmpeg to generate images. I have almost solved many problems, and even wrote a demo to implement my function, but I can't find any information about where there is an identifier when multiple NALUs form one frame (strictly speaking, there is a little, but it can't solve my problem, I will talk about it later).


You can use the following command to generate the type of video I mentioned :


ffmpeg -i input.mp4 -c:v libx264 -x264-params slices=8 output.mp4



This will generate a video with 8 slices per frame. Since I will use this file later, I will also generate the H264 raw information file with the following command :


ffmpeg -i output.mp4 -vcodec copy -an output.h264



When I put it into the analysis program, I can see multiple IDR NALUs connected together, where the first_mb_in_slice in the Slice Header of the non-first IDR NALU is not 0 :



But when I go back to the mdat in MP4 and look at the NALU, all the first_mb_in_slice become 0 :



0x9a= 1001 1010, according to the exponential Golomb coding, first_mb_in_slice == 0( ueg(1B) == 0 ), slice_type == P frame (ueg(00110B) == 5), but using the same algorithm in the H264 raw file, the result is the same as the program gives.


Is there any other place where there is an identifier for this information ? Assuming I randomly get a NALU, can I know if this video is sliced or not, or is my operation wrong ?


PS : Putting only one NALU into the decoder is feasible, but only 1/8 of the image can be parsed



If you need a reference, the address of the demo program I wrote is : https://github.com/gaowanliang/web-video-thumbnailer


-
How to stream 24/7 on youtube (audio + video) with FFMPEG
29 septembre 2023, par Carter510I plan to create a 24/7 stream with a video and a musical background which is located in a
/Playlist
folder.
I would like the music playlist to be played randomly and if a piece of music is corrupted or cannot be played, the program moves on to the next one.

The problem is that with my command every time the music changes the stream stops.
Any suggestions ?


#!/bin/bash

VBR="4500k"
FPS="30"
QUAL="superfast"

YOUTUBE_URL="rtmp://a.rtmp.youtube.com/live2"
KEY="XXXX-XXXX-XXXX-XXXX"

VIDEO_SOURCE="fireplace.mkv"
AUDIO_FOLDER="/home/administrateur/Documents/Youtube/Playlist"

while true; do
 # Joue la vidéo en boucle
 ffmpeg -re -stream_loop -1 -i "$VIDEO_SOURCE" \
 -thread_queue_size 512 -i "$(find "$AUDIO_FOLDER" -type f -name "*.mp3" | shuf -n 1)" \
 -map 0:v:0 -map 1:a:0 \
 -map_metadata:g 1:g \
 -vcodec libx264 -pix_fmt yuv420p -preset $QUAL -r $FPS -g $(($FPS * 2)) -b:v $VBR \
 -acodec libmp3lame -ar 44100 -threads 6 -qscale:v 3 -b:a 320000 -bufsize 512k \
 -f flv "$YOUTUBE_URL/$KEY"
done



I would like the
fireplace.mkv
video to play without interruption, for the music to be chosen randomly without ever stopping. And if one of the songs cannot be played, it is skipped.

-
When assigning an IP via Docker container macvlan and sending video to that container, will the data be limited ?
11 septembre 2023, par leejhI created a macvlan network as shown below.


docker network create -d macvlan \
 --subnet=192.168.1.0/24 \
 --gateway=192.168.1.1 \
 -o parent=eno1 \
 macvlan_network



And the container was created as shown below.


The plan was to create a mistserver inside the container to send and receive video via IP.


docker run -d --name mistserver1 --restart=always -v mistserver_config:/config -v /home/ketivrar/detr2:/home/shared_folder --net=macvlan_network --ip 192.168.1.16 r0gger/mistserver



There is no problem when transmitting video in the directory using the Mist server.


An error occurs when transmitting video using ffmpeg as shown below.


ffmpeg -re -i test7_10.mp4 -c:v libx264 -preset medium -b:v 8000k -f flv rtmp://192.168.1.16/live/cam1



If you run the above command, the following error will occur and it will stop.


av_interleaved_write_frame(): Connection reset by peer58.73 bitrate=8053.7kbits/s dup=0 drop=4 speed=0.948x
[flv @ 0x5582ab9e6e00] Failed to update header with correct duration.
[flv @ 0x5582ab9e6e00] Failed to update header with correct filesize.
Error writing trailer of rtmp://192.168.1.2/live/cam1: Connection reset by peer
frame= 1845 fps= 29 q=33.0 Lsize= 57806kB time=00:00:58.86 bitrate=8044.2kbits/s dup=0 drop=4 speed=0.94x



I wonder what the reason is...


I created two streams on the Mist server and sent video to each stream simultaneously.


ffmpeg -re -i test7_10.mp4 -c:v libx264 -preset medium -b:v 8000k -f flv rtmp://192.168.1.16/live/cam1



ffmpeg -re -i test7_10.mp4 -c:v libx264 -preset medium -b:v 8000k -f flv rtmp://192.168.1.16/live/cam2



av_interleaved_write_frame(): Connection reset by peer29.46 bitrate=8135.7kbits/s dup=0 drop=2 speed=0.343x
[flv @ 0x55975fb05e00] Failed to update header with correct duration.
[flv @ 0x55975fb05e00] Failed to update header with correct filesize.
Error writing trailer of rtmp://192.168.1.16/live/cam1: Connection reset by peer
frame= 971 fps= 11 q=33.0 Lsize= 29395kB time=00:00:29.66 bitrate=8116.6kbits/s dup=0 drop=2 speed=0.34x



####


av_interleaved_write_frame(): Connection reset by peer25.06 bitrate=8313.0kbits/s dup=0 drop=1 speed=0.292x
[flv @ 0x55ce4a7ce340] Failed to update header with correct duration.
[flv @ 0x55ce4a7ce340] Failed to update header with correct filesize.
Error writing trailer of rtmp://192.168.1.16/live/rtsp: Connection reset by peer
frame= 853 fps=9.8 q=33.0 Lsize= 25857kB time=00:00:25.76 bitrate=8220.2kbits/s dup=0 drop=2 speed=0.297x




It seems to stop before the total size of the two reaches 60000.


This time, I sent the video using OBS.


I confirmed that the connection was disconnected and reconnected at a similar time as ffmpeg.


I think there is a size limit somewhere. Could you please tell me a solution or the exact problem ?


+++++


ffmpeg -re -i test7_10.mp4 -c:v libx264 -preset medium -b:v 4000k -f flv rtmp://192.168.1.16/live/cam1



->


[flv @ 0x56547e6f1e00] Failed to update header with correct duration.019.0kbits/s dup=0 drop=12 speed=0.982x
[flv @ 0x56547e6f1e00] Failed to update header with correct filesize.
frame= 5328 fps= 30 q=-1.0 Lsize= 87550kB time=00:02:57.93 bitrate=4030.8kbits/s dup=0 drop=12 speed=0.996x



success !


ffmpeg -re -i test7_10.mp4 -c:v libx264 -preset medium -b:v 5000k -f flv rtmp://192.168.1.16/live/cam1



->


av_interleaved_write_frame(): Connection reset by peer30.63 bitrate=5039.7kbits/s dup=0 drop=6 speed=0.965x
[flv @ 0x555ad97f7e00] Failed to update header with correct duration.
[flv @ 0x555ad97f7e00] Failed to update header with correct filesize.
Error writing trailer of rtmp://192.168.1.16/live/cam1: Connection reset by peer
frame= 2802 fps= 30 q=37.0 Lsize= 55876kB time=00:01:30.83 bitrate=5039.3kbits/s dup=0 drop=6 speed=0.962x



fail...


I only adjusted -b:v 5000k, but the results were mixed.


Are there any resource limits for each container ?


I didn't set it up separately.