
Recherche avancée
Médias (2)
-
Exemple de boutons d’action pour une collection collaborative
27 février 2013, par
Mis à jour : Mars 2013
Langue : français
Type : Image
-
Exemple de boutons d’action pour une collection personnelle
27 février 2013, par
Mis à jour : Février 2013
Langue : English
Type : Image
Autres articles (62)
-
Websites made with MediaSPIP
2 mai 2011, parThis page lists some websites based on MediaSPIP.
-
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. -
MediaSPIP v0.2
21 juin 2013, parMediaSPIP 0.2 est la première version de MediaSPIP stable.
Sa date de sortie officielle est le 21 juin 2013 et est annoncée ici.
Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
Comme pour la version précédente, 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 (...)
Sur d’autres sites (9340)
-
OpenCV reading from live camera creates a short video that moves quickly
17 novembre 2022, par user19019404I am reading in a live vide stream from a CCTV camera. The camera is set to 5 fps, another is set to 25fps and another to 30fps. Irrespective of the FPS that the camera is set, I can record 5 minutes but end up with a 30 second recorded clip where everyone is running around the scene.


My code is the 'typical' read in video and write video code that you would find online such as (code below simplified for readability) :


import cv2

video = cv2.VideoCapture(live RTSP address of camera)

if (video.isOpened() == False):
 print("Error reading video file")
else:
 frame_width = video.get(cv2.CAP_PROP_FRAME_WIDTH)
 frame_height = video.get(cv2.CAP_PROP_FRAME_HEIGHT)
 frame_fps = video.get(cv2.CAP_PROP_FPS)
 size = (frame_width, frame_height)
 result = cv2.VideoWriter('filename.avi',cv2.VideoWriter_fourcc(*'MJPG'),frame_fps , size)

 while(True):
 ret, frame = video.read()
 if ret == True:
 result.write(frame)
 cv2.imshow('Frame', frame)
 if cv2.waitKey(1) & 0xFF == ord('s'):
 break
 else:
 break
 video.release()
 result.release()
 cv2.destroyAllWindows()
print("The video was successfully saved with new fps")



I have tried playing with the FPS by reading in the FPS from the live camera and using the same FPS in the video write, but all that results is a video that is a fraction of the real time and with people zooming around the scene. So watching a 5 minute smooth video results in a 20 second recorded video with everyone zooming around.


Is this something that I need to fix in the writing of the video or do I need a second pass with ffmpeg to readjust the video ?


Much appreciated


Update, corrected the code above and :
When printing the frames read and the frame written the numbers are the same, showing that each frame that is read is being written (so I am not losing frames along the way thereby writing half the amount of frames).


-
How Can I capture and record a live stream using ffmpeg ? (Without any encoding or transcoding)
25 février 2015, par Sina DavaniHow Can I capture and record a live stream using ffmpeg ? (Without any encoding or transcoding)
I have a program written using ffmpeg. It captures a live stream and then plays it on the display (a simple video player).
What I need now is the ability to save the input stream in a file on the disk so it could be played later using a standard video player.
Can anyone please give me a simple example that would show how it is done ? When I am writing the captured packets from the input stream directly in to a file ; at the end the file is corrupted and it is unusable. I did try to set the header for the file ; but that didn’t work either. -
FFMPEG Streaming updated image in loop to FB Live Video
24 décembre 2016, par Aakash GuptaI am trying to stream image to fb live video using this command :
ffmpeg -loop 1 -re -i "input.jpg" -pix_fmt yuv420p -profile:v baseline -s 720x480 -bufsize 6000k -vb 400k -maxrate 1500k -deinterlace -t 60 -vcodec libx264 -preset veryfast -g 30 -r 30 -f flv "rtmp_link"
This command works perfectly for one single input file. But the problem is that I want ffmpeg to stream the latest and updated version of "input.jpg" file because my app is updating this "input.jpg" after every 2-3 seconds but the image that is streamed is the older version, not the updated one.
If I try to restart this loop, then streaming stops for approx. 4-5 seconds which is sufficient enough for FB live video to consider that streaming has been stopped and it then ends the live video.
So, is it possible to use the latest available version of input file for streaming in this loop ? I don’t know much about FFMPEG and I tried to search this issue but all in vain.