
Recherche avancée
Médias (91)
-
Collections - Formulaire de création rapide
19 février 2013, par
Mis à jour : Février 2013
Langue : français
Type : Image
-
Les Miserables
4 juin 2012, par
Mis à jour : Février 2013
Langue : English
Type : Texte
-
Ne pas afficher certaines informations : page d’accueil
23 novembre 2011, par
Mis à jour : Novembre 2011
Langue : français
Type : Image
-
The Great Big Beautiful Tomorrow
28 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Texte
-
Richard Stallman et la révolution du logiciel libre - Une biographie autorisée (version epub)
28 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Texte
-
Rennes Emotion Map 2010-11
19 octobre 2011, par
Mis à jour : Juillet 2013
Langue : français
Type : Texte
Autres articles (66)
-
Support audio et vidéo HTML5
10 avril 2011MediaSPIP utilise les balises HTML5 video et audio pour la lecture de documents multimedia en profitant des dernières innovations du W3C supportées par les navigateurs modernes.
Pour les navigateurs plus anciens, le lecteur flash Flowplayer est utilisé.
Le lecteur HTML5 utilisé a été spécifiquement créé pour MediaSPIP : il est complètement modifiable graphiquement pour correspondre à un thème choisi.
Ces technologies permettent de distribuer vidéo et son à la fois sur des ordinateurs conventionnels (...) -
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 (...) -
De l’upload à la vidéo finale [version standalone]
31 janvier 2010, parLe chemin d’un document audio ou vidéo dans SPIPMotion est divisé en trois étapes distinctes.
Upload et récupération d’informations de la vidéo source
Dans un premier temps, il est nécessaire de créer un article SPIP et de lui joindre le document vidéo "source".
Au moment où ce document est joint à l’article, deux actions supplémentaires au comportement normal sont exécutées : La récupération des informations techniques des flux audio et video du fichier ; La génération d’une vignette : extraction d’une (...)
Sur d’autres sites (7145)
-
Core : Update elementValue method to deal with type="number" fields
29 avril 2014, par jamierytlewskiCore : Update elementValue method to deal with type="number" fields
The HTML5 draft defines, for type="number" inputs : "The value
sanitization algorithm is as follows : If the value of the element is not
a valid floating-point number, then set it to the empty string instead."
If the constraint validation considers the input invalid, return false
as the value, instead of the empty string, for the number and digit
methods to output their messages.This would break in browsers that support type="number", but not the
constraint validation API. I don’t know of any existing browser where
that applies.Fixes #858
Fixes #922
Closes #1093 -
Estimating number of frames and fps in opencv
11 mai 2021, par mrgloomI have some .mp4 video, ffmpeg shows me this info :


Duration: 00:00:07.02, start: 0.000000, bitrate: 18001 kb/s
 Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuvj420p(pc, bt709/bt709/iec61966-2-1, progressive), 886x1920, 14299 kb/s, 22.54 fps, 60 tbr, 600 tbn, 1200 tbc (default)
 Metadata:
 rotate : 270
 creation_time : 2021-04-30T13:56:51.000000Z
 handler_name : Core Media Video
 encoder : 'avc1'
 Side data:
 displaymatrix: rotation of 90.00 degrees



So as I understand it should be 7.02 sec * 22.54 fps 158 frames


When I try to read it in opencv :


def print_info_cap_reading(video_filepath):
 cap = cv2.VideoCapture(video_filepath)

 fps = cap.get(cv2.CAP_PROP_FPS)
 n_frames = int(cap.get(cv2.CAP_PROP_FRAME_COUNT))

 print('fps:', round(fps, 2))
 print('n_frames', n_frames)

 counter = 0
 while True:
 ret, frame = cap.read()
 if ret == False:
 break
 counter += 1

 print('counter:', counter)



It shows me


# fps: 22.54
# n_frames 199
# counter: 175



When I tried to convert it to separate frames via ffmpeg it produce 422 frames :


ffmpeg -i source1.mp4 tmp/img%03d.jpg



So I wonder :


- 

- Why fps is float value and not int value ?
- What is the right way to estimate fps and number of frames ?
- Why cv2.CAP_PROP_FRAME_COUNT in opencv and actually reading frames produce different number of frames ?








Update :


-ignore_editlist 1
not helped, ffmpeg still produce 422 frames :

ffmpeg -i source1.mp4 tmp1/img%03d.jpg
 ffmpeg -i source1.mp4 -ignore_editlist 1 tmp2/img%03d.jpg



Here is some ffmpeg output :


Output #0, image2, to 'tmp1/img%03d.jpg':
 Metadata:
 major_brand : qt
 minor_version : 0
 compatible_brands: qt
 com.apple.quicktime.author: ReplayKitRecording
 encoder : Lavf58.45.100
 Stream #0:0(und): Video: mjpeg, yuvj420p(pc), 1920x886, q=2-31, 200 kb/s, 60 fps, 60 tbn, 60 tbc (default)
 Metadata:
 encoder : Lavc58.91.100 mjpeg
 creation_time : 2021-04-30T13:56:51.000000Z
 handler_name : Core Media Video
 Side data:
 cpb: bitrate max/min/avg: 0/0/200000 buffer size: 0 vbv_delay: N/A
 displaymatrix: rotation of -0.00 degrees
frame= 422 fps=224 q=24.8 Lsize=N/A time=00:00:07.03 bitrate=N/A dup=247 drop=0 speed=3.74x
video:13709kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown



Update :


mkdir tmp3 && ffmpeg -ignore_editlist 1 -i source1.mp4 tmp3/img%03d.jpg
produce even more frames - 529.

Output #0, image2, to 'tmp3/img%03d.jpg':
 Metadata:
 major_brand : qt
 minor_version : 0
 compatible_brands: qt
 com.apple.quicktime.author: ReplayKitRecording
 encoder : Lavf58.45.100
 Stream #0:0(und): Video: mjpeg, yuvj420p(pc), 1920x886, q=2-31, 200 kb/s, 60 fps, 60 tbn, 60 tbc (default)
 Metadata:
 encoder : Lavc58.91.100 mjpeg
 creation_time : 2021-04-30T13:56:51.000000Z
 handler_name : Core Media Video
 Side data:
 cpb: bitrate max/min/avg: 0/0/200000 buffer size: 0 vbv_delay: N/A
 displaymatrix: rotation of -0.00 degrees
frame= 529 fps=221 q=24.8 Lsize=N/A time=00:00:08.81 bitrate=N/A dup=330 drop=0 speed=3.68x
video:16178kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown



-
Extracting number of duplicate (or dropped) frames in ffmpeg via C/C++ API
20 septembre 2023, par userDtrmIs there a way to extract number of duplicated or dropped video frames during the decoding of a .mp4 or .ts file through ffmpeg's C/C++ API ?


This information is reported by ffmpeg when using the command line tool. However, I have a requirement that I need this information to be extracted in C/C++.