
Recherche avancée
Médias (1)
-
The pirate bay depuis la Belgique
1er avril 2013, par
Mis à jour : Avril 2013
Langue : français
Type : Image
Autres articles (104)
-
Les tâches Cron régulières de la ferme
1er décembre 2010, parLa gestion de la ferme passe par l’exécution à intervalle régulier de plusieurs tâches répétitives dites Cron.
Le super Cron (gestion_mutu_super_cron)
Cette tâche, planifiée chaque minute, a pour simple effet d’appeler le Cron de l’ensemble des instances de la mutualisation régulièrement. Couplée avec un Cron système sur le site central de la mutualisation, cela permet de simplement générer des visites régulières sur les différents sites et éviter que les tâches des sites peu visités soient trop (...) -
MediaSPIP 0.1 Beta version
25 avril 2011, parMediaSPIP 0.1 beta is the first version of MediaSPIP proclaimed as "usable".
The zip file provided here only contains the sources of MediaSPIP in its standalone version.
To get a working installation, you must manually install all-software dependencies on the server.
If you want to use this archive for an installation in "farm mode", you will also need to proceed to other manual (...) -
Personnaliser en ajoutant son logo, sa bannière ou son image de fond
5 septembre 2013, parCertains thèmes prennent en compte trois éléments de personnalisation : l’ajout d’un logo ; l’ajout d’une bannière l’ajout d’une image de fond ;
Sur d’autres sites (13517)
-
wrap h.264 stream in mp.4 container and stream it with nodejs
30 mars 2017, par idoshI have a stream of h.264 data from a remote webcam. If i save it to a file i’m able to play it in VLC (meaning that the data arrives intact).
The final goal is to turn this stream into a virtual webcam. After looking around I found manyCam as a possible solution - therefor i want to serve the h.264 data on a local IP in MP4 format.
Two questions :
first, I’m trying to wrap the h.264 with the mp4 container using ffmpeg (using fluent-ffmpeg npm library that exposes the ffmpeg API to Nodejs).
Everything works well when i’m handling static files (not streams). e.g.`
var ffmpeg = rquire('fluent-ffmpeg')
var readH264 = fs.createReadStream('./vid.h264')
var proc = ffmpeg(readH264).clone().toFormat('mp4').output('./vid.mp4').run()`
But when I’m trying to feed a stream - it throws an error "ffmpeg exited with code 1 : could not write header for output file.."
`var wrtieMp4 = fs.createWriteStream('./vid.mp4')
var proc = ffmpeg(readH264).clone().toFormat('mp4').output(wrtieMp4).run()`How can i add it a header..?
Second, I’m a bit confused about the transport layer (rtp, rtsp, etc.). After creating the mp4 stream - wouldn’t it be sufficient to serve the stream with MIME type video/mp4 ? It seem to work fine with static file.
`let read = fs.createReadStream('./vid.mp4')
let server = http.createServer(function (req, res) {
res.writeHead(200, {'Content-type': "video/mp4"})
read.pipe(res)
}).listen(9000)`
-
Variable fps (frame per second) in cv2
17 octobre 2022, par SepideI use
cv2
for creating videos from different frames that I have. When I create the video, I cannot change the fps (frame per second). I want the video be slow at the beginning but fast towards the end, meaning small fps at the beginning but large ones towards the end. However, when I instantiatecv2.VideoWriter
I cannot change the fps anymore. What should I do ?

Replicable code


import numpy as np
import cv2, os
import matplotlib

image_size = 200
def create_image_array(image_size):
 image_array = np.random.randn(image_size, image_size)
 row = np.random.randint(0, image_size)
 image_array[row, :] = 100
 return image_array

frame_numbers = 200
for i in range(frame_numbers):
 image_array = create_image_array(image_size)
 matplotlib.image.imsave(f'./shots/frame_{i:03d}.png', image_array)

def make_a_video(shots_folder, video_path):

 shots_folder = 'shots'
 fps = 25
 images = [img for img in os.listdir(shots_folder) if img.endswith(".png")]

 images = sorted(images)[:]
 frame = cv2.imread(os.path.join(shots_folder, images[0]))
 height, width, layers = frame.shape

 video = cv2.VideoWriter(video_path, cv2.VideoWriter_fourcc(*'mp4v'), fps, (width, height))

 for image in images:
 video.write(cv2.imread(os.path.join(shots_folder, image)))

 cv2.destroyAllWindows()
 video.release()

shots_folder = 'shots'
video_path = 'video.mp4' 
make_a_video(shots_folder, video_path)



-
How to create a local audio livestream server with ffmpeg and python ? [closed]
10 novembre 2024, par FenekhuSimply put, this is what I'm trying to accomplish :

I navigate to something likehttp://localhost:8080/
in my browser and the browser shows a built-in audio player playing whatever the ffmpeg process is streaming. (Not just serving a local audio file.) (Built-in here meaning the page looks the same as if you had opened an mp3 file with your browser.)

At first I thought it would be easy, as ffmpeg has the ability to stream through different protocols. I seem to have misunderstood though, because while I can stream something over rtp with it, I can't access that from my browser. Some stackoverflow questions I found seem to imply that you can do this with the output options
-f mpegts http://localhost:8080
, but when I try this, ffmpeg freezes for a second, then I get these errors :

[tcp @ 00000210f70b0700] Connection to tcp://localhost:8080 failed: Error number -138 occurred
[out#0/mpegts @ 00000210f7080ec0] Error opening output http://localhost:8080: Error number -138 occurred
Error opening output file http://localhost:8080.
Error opening output files: Error number -138 occurred



but I have no problem with
-f rtp rtp://localhost:8080
. (Like I said though, I can't access that through the browser).

So I suspect I need something else to "pick up" the rtp stream and put it on an http server, but I haven't been able to find anything on that, probably because I just don't know the right thing to search. It seems like something that should be easily doable in Python, and that would be my preferred language to do it in over javascript, if possible.


Can anyone point me in the right direction ? Or let me know if I'm misunderstanding something ? Thanks.