Recherche avancée

Médias (1)

Mot : - Tags -/iphone

Autres articles (96)

  • MediaSPIP 0.1 Beta version

    25 avril 2011, par

    MediaSPIP 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 (...)

  • (Dés)Activation de fonctionnalités (plugins)

    18 février 2011, par

    Pour gérer l’ajout et la suppression de fonctionnalités supplémentaires (ou plugins), MediaSPIP utilise à partir de la version 0.2 SVP.
    SVP permet l’activation facile de plugins depuis l’espace de configuration de MediaSPIP.
    Pour y accéder, il suffit de se rendre dans l’espace de configuration puis de se rendre sur la page "Gestion des plugins".
    MediaSPIP est fourni par défaut avec l’ensemble des plugins dits "compatibles", ils ont été testés et intégrés afin de fonctionner parfaitement avec chaque (...)

  • ANNEXE : Les plugins utilisés spécifiquement pour la ferme

    5 mars 2010, par

    Le site central/maître de la ferme a besoin d’utiliser plusieurs plugins supplémentaires vis à vis des canaux pour son bon fonctionnement. le plugin Gestion de la mutualisation ; le plugin inscription3 pour gérer les inscriptions et les demandes de création d’instance de mutualisation dès l’inscription des utilisateurs ; le plugin verifier qui fournit une API de vérification des champs (utilisé par inscription3) ; le plugin champs extras v2 nécessité par inscription3 (...)

Sur d’autres sites (7851)

  • convert a normal video to youtube short

    28 mai 2022, par Un1xCr3w

    hello i have videos with width of 1920px and height of 1080 and i wanna crop it at the center and create a youtube short with it

    


    iam using youtube dl wrap node js library
here is my code example

    


    var ffmpeg = require("fluent-ffmpeg");
const fs = require("fs");
let rawdata = fs.readFileSync("./json-files/small.json");
let clips = JSON.parse(rawdata);

function convertIt(fileName) {
  return new Promise((resolve, reject) => {
    ffmpeg(`./media-new/${fileName}`)
      .size("480x640")
      .aspect("9:16")
      .autopad()
      .videoBitrate("4000k")
      .on("end", function () {
        console.log("file has been converted succesfully");
        resolve("foo");
      })
      .on("error", function (err) {
        console.log("an error happened: " + err.message);
        reject(err);
      })
      // save to file
      .save(`./lib/${fileName}`);
  });
}

async function convertToShorts() {
  for (const iterator of clips) {
    await convertIt(`${iterator.id}.mp4`);
  }
}

convertToShorts();


    


  • youtube-dl doesn't see ffmpeg in the executable

    30 novembre 2019, par Михаил Муратов

    I am writing a program to download music and videos via youtube-dl in python. Next, I pack the script into an executable file via pyinstaller.

    The problem is that youtube-dl (in the executable) doesn’t see ffmpeg and ffprobe, even though I add them to the spec file.

    As far as I know youtube-dl has the ffmpeg_location parameter, but that’s only in the console version. Maybe it is also for python ? But I didn’t find any information about it.

    How do I solve the problem ?


    command to create executable :

    pyinstaller --upx-dir=c:\users\exe-builder c:\users\exe-builder\youtubedownloader\main.spec

    .spec file :

    # -*- mode: python -*
    block_cipher = None

    a = Analysis(['C:\\Users\\Exe-Builder\\YoutubeDownloader\\main.py'],
                pathex=['C:\\Users\\Exe-Builder\\YoutubeDownloader'],
                binaries=[],
                datas=[],
                hiddenimports=[],
                hookspath=[],
                runtime_hooks=[],
                excludes=[],
                win_no_prefer_redirects=False,
                win_private_assemblies=False,
                cipher=block_cipher,
                noarchive=False)

    a.binaries += [('ffmpeg.exe','C:\\Users\\Exe-Builder\\YoutubeDownloader\\ffmpeg.exe', "Binary"),
                  ('ffprobe.exe','C:\\Users\\Exe-Builder\\YoutubeDownloader\\ffprobe.exe', "Binary")]

    pyz = PYZ(a.pure, a.zipped_data,
                cipher=block_cipher)
    exe = EXE(pyz,
             a.scripts,
             a.binaries,
             a.zipfiles,
             a.datas,
             [],
             name='MediaDownloader',
             debug=False,
             bootloader_ignore_signals=False,
             strip=False,
             upx=True,
             upx_exclude=['vcruntime140.dll'],
             runtime_tmpdir=None,
             console=True)

    very small example :

    import youtube_dl

    url = 'https://www.youtube.com/watch?v=MIk55C1s0ns'
    outtmpl = '\\%(title)s.%(ext)s'
    ydl_opts = {'format': 'bestaudio/best',
               'outtmpl': outtmpl,
               'postprocessors': [{'key': 'FFmpegExtractAudio',
                                   'preferredcodec': 'mp3',
                                   'preferredquality': '128'}]}

    with youtube_dl.YoutubeDL(ydl_opts) as ydl:
       info_dict = ydl.extract_info(url, download=True)

    error message :

    youtube_dl.utils.DownloadError: ERROR: ffprobe/avprobe and ffmpeg/avconv not found. Please install one.

  • PiCamera stream to youtube with ffmpeg and capture image every second

    9 octobre 2020, par MisterGray

    I'm sending a livestream with a Python script on a Raspberry Pi 4 to Youtube with ffmpeg.

    


    Additionally I want to check the stream for movements. Therefore I want to compare two frames with each other. Since this is relatively computationally intensive, I wanted to limit myself to "only" compare single frames every second.

    


    The camera.capture() command, however, seems to take very long, so the stream hangs again and again.

    


    What is the best way to get a raw frame during the stream ?

    


    Is there a better alternative to detect movements while creating a stream with ffmpeg ?

    


    #!/usr/bin/env python3
import subprocess
from picamera.array import PiRGBArray
from picamera import PiCamera
import time
import cv2
import numpy as np

YOUTUBE = 'rtmp://a.rtmp.youtube.com/live2/'
KEY = 'MyYoutubeKey'
stream_cmd = 'ffmpeg -re -ar 44100 -ac 2 -acodec pcm_s16le -f s16le -ac 2 -i /dev/zero -f h264 -i - -vcodec copy -acodec aac -ab 128k -g 50 -strict experimental -f flv ' + YOUTUBE + KEY

avg = None
stream_pipe = subprocess.Popen(stream_cmd, shell=True, stdin=subprocess.PIPE)
resolution = (1280,720)
with PiCamera(resolution = resolution) as camera:

    rawCapture = PiRGBArray(camera, size = resolution)

    camera.framerate = 25
    camera.vflip = True
    camera.hflip = True
    camera.start_recording(stream_pipe.stdin, format='h264', bitrate = 6000000)
    while True:
        camera.wait_recording(1)

        # this command takes a long time to finish
        frame = camera.capture(stream_pipe.stdin, 'rgb')

        """
        further calculations
        """

        rawCapture.truncate(0)

    camera.stop_recording()
    stream_pipe.stdin.close()
    stream_pipe.wait()