Recherche avancée

Médias (1)

Mot : - Tags -/net art

Autres articles (27)

  • Des sites réalisés avec MediaSPIP

    2 mai 2011, par

    Cette 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.

  • Les autorisations surchargées par les plugins

    27 avril 2010, par

    Mediaspip core
    autoriser_auteur_modifier() afin que les visiteurs soient capables de modifier leurs informations sur la page d’auteurs

  • Automated installation script of MediaSPIP

    25 avril 2011, par

    To overcome the difficulties mainly due to the installation of server side software dependencies, an "all-in-one" installation script written in bash was created to facilitate this step on a server with a compatible Linux distribution.
    You must have access to your server via SSH and a root account to use it, which will install the dependencies. Contact your provider if you do not have that.
    The documentation of the use of this installation script is available here.
    The code of this (...)

Sur d’autres sites (6376)

  • ffmpeg waits to close the pipe in order to start processing data

    15 juin 2022, par Mahmoud Ferig

    I'm struggling with this issue.
Here I am trying to stream video using ffmpeg from images and audio file this code below works fine but it is start streaming after stdin closed, I would expect ffmpeg to start processing the pipe input as it is received, and immediately output the result.

    


    p = subprocess.Popen(
    [
        'ffmpeg',
        '-y',
        '-re',
        '-f', 'image2pipe',
        '-vcodec', 'mjpeg',
        '-framerate', '15',
        '-analyzeduration', '2147483647',
        '-probesize', '2147483647',
        '-i', '-',
        '-vn', '-i', audio_path,
        '-c:v', 'libx264',
        '-pix_fmt', 'yuv420p',
        '-preset', 'ultrafast',
        '-c:a', 'aac',
        '-f', 'flv',
        rtmp_url
    ],
    stdin=subprocess.PIPE,
    stdout=subprocess.PIPE
)

time.sleep(2)

i = 0
while True:
    current_images = [name for name in os.listdir(img_dir) if os.path.isfile(os.path.join(img_dir, name))]
    current_images = sorted(current_images)
    if i > fnum-1:
        print("frame read failed")
        break
    try:
        img = cv2.imread(os.path.join(img_dir, current_images[i]))
        success, buffer = cv2.imencode('.jpg', img)
        frame = buffer.tobytes()
        p.stdin.write(frame)
        i += 1
    except:
        time.sleep(2)
        pass

p.stdin.close()
p.wait()


    


    Why is ffmpeg waiting to close the pipe to start processing ? Can it be configured to start a live transcoding of the received stream ?

    


    Do you know how can I convince ffmpeg to start producing output immediately ?

    


    Thank you !

    


  • Create poster with overlay and scale

    16 juillet 2017, par timgavin

    I’m working on creating a thumbnail from a video and adding an overlay. The following is working great ; it outputs a JPG with the PNG overlay.

    ffmpeg -ss 15 -i input.mp4 -i play-button.png \
    -filter_complex overlay='(main_w-overlay_w)/2:(main_h-overlay_h)/2' \
    -vframes 1 poster.jpg

    However, I’d like to scale the thumbnail down, so I tried adding scale='min(640\, iw):-1'

    ffmpeg -ss 15 -i input.mp4 -i play-button.png \
    -filter_complex overlay='(main_w-overlay_w)/2:(main_h-overlay_h)/2' \
    -vframes 1 scale='min(640\, iw):-1' poster.jpg

    But when doing that I receive errors

    Unable to find a suitable output format for
    'scale=min(640\, iw):-1' scale=min(640\, iw):-1: Invalid argument

    I’ve tried qscale and adding image2, and playing around with a lot of different options but just can’t find the one that works.

    Edit

    This is what I was previously using to create my poster image, I just needed to add an overlay. But when trying to combine the two it all fell apart.

    ffmpeg -ss 15 -i input.mp4 -f image2 -vf scale='min(640\, iw):-1' \
    vframes 1 poster.jpg
  • Evolution #3603 : Ergonomie des onglets de sélection des plugins

    24 novembre 2015, par RastaPopoulos ♥

    Je suis d’accord que dans de nombreux cas, au lieu d’avoir une interface pleines d’options à choisir / cocher / cumuler, il est plus lisible d’avoir 3 ou 4 cas d’utilisation réels dont on sait qu’ils sont utiles, et n’avoir que ça. Évidemment il faut bien réfléchir alors pour être sûr que ne vont pas apparaitre d’autres cas utiles, qui feraient augmenter le nombre d’onglets. Mais là on est dans une interface très précise, qui ne s’occupent que des plugins, c’est à priori pas un truc qui peut augmenter, où des fonctionnalités peuvent apparaitre ou être ajoutées.

    Et au passage, du coup, au niveau ergonomique, ce sont VRAIMENT sémantiquement des onglets (alors que des "filtres" affichés graphiquement sous forme d’onglets, ce n’était pas du tout pertinent au niveau ergo).