Recherche avancée

Médias (1)

Mot : - Tags -/ogv

Autres articles (76)

  • Personnaliser en ajoutant son logo, sa bannière ou son image de fond

    5 septembre 2013, par

    Certains 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 ;

  • Amélioration de la version de base

    13 septembre 2013

    Jolie sélection multiple
    Le plugin Chosen permet d’améliorer l’ergonomie des champs de sélection multiple. Voir les deux images suivantes pour comparer.
    Il suffit pour cela d’activer le plugin Chosen (Configuration générale du site > Gestion des plugins), puis de configurer le plugin (Les squelettes > Chosen) en activant l’utilisation de Chosen dans le site public et en spécifiant les éléments de formulaires à améliorer, par exemple select[multiple] pour les listes à sélection multiple (...)

  • Emballe médias : à quoi cela sert ?

    4 février 2011, par

    Ce plugin vise à gérer des sites de mise en ligne de documents de tous types.
    Il crée des "médias", à savoir : un "média" est un article au sens SPIP créé automatiquement lors du téléversement d’un document qu’il soit audio, vidéo, image ou textuel ; un seul document ne peut être lié à un article dit "média" ;

Sur d’autres sites (9745)

  • Anomalie #2374 (Fermé) : request url too long

    17 octobre 2011, par Ben .

    la solution : define(’_CACHE_CONTEXTES_AJAX’,true) ; dans le mes_options.php duplicate #2123

  • How to slow down the ouput speed of ffmpeg while streaming to a RTMP server ?

    25 avril 2023, par Loc Bui Nhien

    I'm currently trying to process multipul short videos (each is about 0.5s long) to be stream on a RTMP server. However, the output/fps/speed when sending is too high (results printed here), making the server crashed very often.

    


    Here is the the code and settings that I'm using :

    


    import cv2
import ffmpeg
import av
import numpy as np
import os
import subprocess

url = "rtmp://..."
key = "..."
rtmp_url = url + "/" + key

cap = cv2.VideoCapture('traffic.mp4')

# gather video info to ffmpeg
fps = int(cap.get(cv2.CAP_PROP_FPS))
width = int(cap.get(cv2.CAP_PROP_FRAME_WIDTH))
height = int(cap.get(cv2.CAP_PROP_FRAME_HEIGHT))

# command and params for ffmpeg
command = ['ffmpeg',
           '-y',
           '-f', 'rawvideo',
           '-vcodec', 'rawvideo',
           '-pix_fmt', 'bgr24',
           '-s', "{}x{}".format(width, height),
           '-i', '-',
           '-r', '20',
           '-c:v', 'libx264',
           '-pix_fmt', 'yuv420p',
           '-preset', 'slow',
           '-f', 'flv',
           rtmp_url]

# using subprocess and pipe to fetch frame data
p = subprocess.Popen(command, stdin=subprocess.PIPE, shell=True)

received_video_path = 'ReceivedRecording'
while True:
    video_files = [filenames for filenames in sorted(os.listdir(received_video_path), reverse=True)]
    # Loop through the videos and concatenate them
    for filename in video_files[:len(video_files)-3]:
        video = cv2.VideoCapture(os.path.join(received_video_path,filename))

        # Loop through the frames of each video
        while True:
            ret, frame = video.read()
            if not ret:
                # End of video, move to next video
                video.release()
                break
            
            p.stdin.write(frame.tobytes())

        os.remove(os.path.join(received_video_path, filename))


    


    The same settings work fine with the webcam, but I can not control the speed and fps of it sending to the server. The stream on the server seems to work fine with a steady 20fps as intended.

    


  • why node-media-server not creating sub folders in server while implementing Live video with RTMP ?

    10 mars 2020, par Kadam Saikumar
    I tried this configuration in local it got works and it creates **./media/live/STREAM KEY** folder and storing video data (MP4 file).
       If i push the same code in server it doesnot create sub folders **live/STREAMKEY** and i am using node version 8 and linux server and ffmpeg 4.


    const nodeMediaServerConfig = {
         // logType: 3,
         rtmp: {
           port: 1935,
           chunk_size: 60000,
           gop_cache: true,
           ping: 60,
           ping_timeout: 30
         },
         http: {
           port: 8000,
           mediaroot: './media',
           allow_origin: '*'
         },
         trans: {
           ffmpeg: '/usr/bin/ffmpeg',
           tasks: [
             {
               app: 'live',
               ac: 'aac',
               mp4: true,
               mp4Flags: '[movflags=faststart]'
             }
           ]
         }
       };

       var nms = new NodeMediaServer(nodeMediaServerConfig);
       nms.run();

    ===============================================================================================
    If i create manually folders will it be useful in server ?