
Recherche avancée
Médias (1)
-
The Great Big Beautiful Tomorrow
28 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Texte
Autres articles (54)
-
La file d’attente de SPIPmotion
28 novembre 2010, parUne file d’attente stockée dans la base de donnée
Lors de son installation, SPIPmotion crée une nouvelle table dans la base de donnée intitulée spip_spipmotion_attentes.
Cette nouvelle table est constituée des champs suivants : id_spipmotion_attente, l’identifiant numérique unique de la tâche à traiter ; id_document, l’identifiant numérique du document original à encoder ; id_objet l’identifiant unique de l’objet auquel le document encodé devra être attaché automatiquement ; objet, le type d’objet auquel (...) -
Des sites réalisés avec MediaSPIP
2 mai 2011, parCette page présente quelques-uns des sites fonctionnant sous MediaSPIP.
Vous pouvez bien entendu ajouter le votre grâce au formulaire en bas de page. -
HTML5 audio and video support
13 avril 2011, parMediaSPIP uses HTML5 video and audio tags to play multimedia files, taking advantage of the latest W3C innovations supported by modern browsers.
The MediaSPIP player used has been created specifically for MediaSPIP and can be easily adapted to fit in with a specific theme.
For older browsers the Flowplayer flash fallback is used.
MediaSPIP allows for media playback on major mobile platforms with the above (...)
Sur d’autres sites (6391)
-
Converting ffmpeg loudnorm first pass dcf summary report output to data.frame R
23 décembre 2022, par ChrisFollowing from operations on a video with ffmpeg, a
loudnorm
first pass report for purely audio files is produced

names(aud_proc_df)
[1] "in_files" "proc_out" "filter"

cmds_loudness_report <- with(aud_proc_df, sprintf("ffmpeg -hide_banner -i %s -af loudnorm=I=-23:TP=-2:LRA=7:print_format=summary -f null /dev/null 2>&1 | tail -n 12 >> loudness_rpt_all.txt", in_files)) # linux specific notation
lapply(cmds_loudness_report, system)



reading this as a .csv rather than .dcf


loudness_df_csv <- read.csv('loudness_rpt_all.txt', header = FALSE, sep =':')
head(loudness_df_csv)
 V1 V2
1 Input Integrated -24.7 LUFS
2 Input True Peak -1.6 dBTP
3 Input LRA 17.9 LU
4 Input Threshold -37.8 LUFS
5 Output Integrated -23.4 LUFS
6 Output True Peak -2.0 dBTP
#data
structure(list(V1 = c("Input Integrated", "Input True Peak", 
"Input LRA", "Input Threshold", "Output Integrated", "Output True Peak", 
"Output LRA", "Output Threshold", "Normalization Type", "Target Offset", 
"Input Integrated", "Input True Peak", "Input LRA", "Input Threshold", 
"Output Integrated", "Output True Peak", "Output LRA", "Output Threshold", 
"Normalization Type", "Target Offset"), V2 = c(" -24.7 LUFS", 
" -1.6 dBTP", " 17.9 LU", " -37.8 LUFS", 
" -23.4 LUFS", " -2.0 dBTP", " 14.8 LU", " -36.2 LUFS", 
" Dynamic", " +0.4 LU", " -23.9 LUFS", " +0.2 dBTP", 
" 22.0 LU", " -37.6 LUFS", " -23.6 LUFS", " -2.0 dBTP", 
" 21.9 LU", " -37.0 LUFS", " Dynamic", " +0.6 LU"
)), row.names = c(NA, 20L), class = "data.frame")



then, for column notation portability between win and linux systems


df_names <- unique(loudness_df_csv$V1)
df_names2 <- gsub(' ', '_', df_names)



and then make a data.frame


loudnorm_rpt <- data.frame(loudness_df_csv$V2[which(loudness_df_csv$V1 == df_names[1])], loudness_df_csv$V2[which(loudness_df_csv$V1 == df_names[2])], loudness_df_csv$V2[which(loudness_df_csv$V1 == df_names[3])], loudness_df_csv$V2[which(loudness_df_csv$V1 == df_names[4])], loudness_df_csv$V2[which(loudness_df_csv$V1 == df_names[5])], loudness_df_csv$V2[which(loudness_df_csv$V1 == df_names[6])], loudness_df_csv$V2[which(loudness_df_csv$V1 == df_names[7])], loudness_df_csv$V2[which(loudness_df_csv$V1 == df_names[8])], loudness_df_csv$V2[which(loudness_df_csv$V1 == df_names[9])], loudness_df_csv$V2[which(loudness_df_csv$V1 == df_names[10])])
names(loudnorm_rpt) <- df_names2
rownames(loudnorm_rpt) <- c('A', 'B')



Should I just wrap this in a function or is there a dcf to data.frame function that I've missed ?


-
pyav / ffmpeg / libav select number of P-frames and B-frames
27 mai 2021, par user1315621I am streaming from an rtsp source. It looks like half of the frames received are key frames. Is there a way to reduce this percentage and have an higher number of P-frames and B-frames ? If possible, I would like to increase the number of P-frames (not the one of B-frames).
I am using
pyav
which is a Python wrapper forlibav
(ffmpeg
)

Code :


container = av.open(
 url, 'r',
 options={
 'rtsp_transport': 'tcp',
 'stimeout': '5000000',
 'max_delay': '5000000',
 }
)
stream = container.streams.video[0]
codec_context = stream.codec_context
codec_context.export_mvs = True
codec_context.gop_size = 25 

for packet in self.container.demux(video=0):
 for video_frame in packet.decode():
 print(video_frame.is_key_frame)



Output :


True
False
True
False
...



Note 1 : I can't edit the source. I can just edit the code used to stream the video.


Note 2 : same solution should apply to
pyav
,libavi
andffmpeg
.

Edit : it seems that B-frames are disabled :
codec_context.has_b_frames
isFalse


-
ffmpeg OSError : [WinError 6] The handle is invalid when converted to exe
13 septembre 2021, par thewaymanI am trying to merge a video file with an audio file, using FFmpeg. It work fine when I am testing it but when I make an exe file via pyinstaller and including the FFmpeg.exe inside there is a peculiar error I am getting.




OSError : [WinError 6] The handle is invalid




This only happens when I set the FFmpeg run(quiet=True) but when I set the quiet=False everything works fine. The only problem is it shows the output window of FFmpeg.


if getattr(sys, 'frozen', False):
 application_path = sys._MEIPASS
elif __file__:
 application_path = os.path.dirname(__file__)
ffmpegName = 'ffmpeg.exe'
ffmpegPath = os.path.join(application_path, ffmpegName)
video_stream = ffmpeg.input(file[0])
audio_stream = ffmpeg.input(file[1])
ffmpeg.output(audio_stream, video_stream, path).run(overwrite_output=True,
 cmd=ffmpegPath, quiet=True) #setting quiet=false everything works fine.



Can anyone explain what's happening here ?
(Note the code is running in a different thread.)