Recherche avancée

Médias (1)

Mot : - Tags -/publicité

Autres articles (60)

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

  • Ecrire une actualité

    21 juin 2013, par

    Présentez les changements dans votre MédiaSPIP ou les actualités de vos projets sur votre MédiaSPIP grâce à la rubrique actualités.
    Dans le thème par défaut spipeo de MédiaSPIP, les actualités sont affichées en bas de la page principale sous les éditoriaux.
    Vous pouvez personnaliser le formulaire de création d’une actualité.
    Formulaire de création d’une actualité Dans le cas d’un document de type actualité, les champs proposés par défaut sont : Date de publication ( personnaliser la date de publication ) (...)

  • Publier sur MédiaSpip

    13 juin 2013

    Puis-je poster des contenus à partir d’une tablette Ipad ?
    Oui, si votre Médiaspip installé est à la version 0.2 ou supérieure. Contacter au besoin l’administrateur de votre MédiaSpip pour le savoir

Sur d’autres sites (8266)

  • downloading and concatenating parts of videos from youtube

    17 octobre 2018, par amit

    I’m trying to create a video quiz, that will contain small parts of other videos, concatenated together (with the purpose, that people will identify from where these short snips are taken from).

    For this purpose I created a file that contain the URL of the video, the starting time of the "snip", and its length. for example :

    https://www.youtube.com/watch?v=5-j6LLkpQYY   00:00   01:00
    https://www.youtube.com/watch?v=b-DqO_D1g1g   14:44   01:20
    https://www.youtube.com/watch?v=DPAgWKseVhg   12:53   01:00

    Meaning that the first part should take the video from the first URL from its beginning and last for a minute, the second part should be taken from the second URL starting from 14:44 (minutes:seconds) and last one minute and 20 seconds and so forth.

    Then all these parts should be concatenated to a single video.

    I’m trying to write a script (I use ubuntu and fluent in several scripting languages) that does that, and I tried to use youtube-dl command line package and ffmpeg, but I couldn’t find the right options to achieve what I need.

    Any suggestions will be appreciated.

  • Download youtube video duration using youtube-dl PHP and ffmpeg

    21 juin 2017, par user3285828

    Is there any more efficient way to download youtube videos at a specific start and end time using youtube-dl and ffmpeg in PHP.

    I currently have this, which does work, it first downloads the whole video to an mp3 file, and then crops that file to the range I set using ffmpeg, but when I only want 30 seconds or so of a 20 minute video, waiting for the full video to download doesn’t seem the best way to do it.

    <?php
    require __DIR__ . '/vendor/autoload.php';

    use YoutubeDl\YoutubeDl;

    $dl = new YoutubeDl([
       'extract-audio' => true,
       'audio-format' => 'mp3',
       'audio-quality' => 0, // best
       'output' => 'videoname.%(ext)s',
    ]);
    $dl->setDownloadPath('C:\youtubevideos');
    $video = $dl->download('https://www.youtube.com/watch?v=oDAw7vW7H0c');

    $start = 60; // Start 60 seconds in to the video
    $duration = 30; // Get 30 seconds after $start
    $fullVideo = "C:\youtubevideos\videoname.mp3";
    $shortVideo = "C:\youtubevideos\short\shortversion.mp3"; // create 30 seconds
    exec("ffmpeg -ss $start -i $fullVideo -t $duration -c copy $shortVideo");
    exec("DEL $fullVideo");

    I am using youtube dl PHP https://github.com/norkunas/youtube-dl-php

  • Creating a PowerShell Streamer Function w/youtube-dl, ffmpeg & ffplay

    11 juillet 2017, par Adam Chilcott

    My question is in regards to combining youtube-dl, ffmpeg, ffplay and PowerShell to handle video URLs.

    Some examples I’ve seen have piped a binary stream from youtube-dl to an external player using the Windows Command Prompt as demonstrated :

    youtube-dl --output - "https://youtube.com/mygroovycontent" | mpc-hc.exe /play /close -

    This works fine in Command Prompt as it does not mangle the binary stream. If you try and run the same command in PowerShell it doesn’t handle the binary stream so well and modifies the output, making it unreadable to the external player.

    In light of this I’ve written the following PowerShell function to get around this issue. It tries to mirror a similar function I’ve written in Bash (See : https://github.com/adamchilcott/.dotfiles/blob/master/.bash_functions.d/streamer.sh)

    The reason I’ve handled youtube-dl, ffmpeg and ffplay seperately is that defining the ffmpeg binary location in youtube-dl as an external program creates some issues when passing it in PowerShell.

    I was hoping that someone could take a look at my script and provide some feedback on what I have done here and if it can be improved upon or if a better implementation is already available ?

    Best,

    Adam.

    BEGIN POWERSHELL

    Function streamer
    {

    Param
    (
    [string] $streamURL
    )

    Begin
    {
    }

    Process
    {
    $streamDir = "$env:TEMP\YTD.d"

    $ytdBin = "Z:\PortableApps\CommandLineApps\youtube-dl\youtube-dl.exe"
    $streamExtractor = &$ytdBin --no-warnings --get-url $streamURL

    $ffmpegBin = "Z:\PortableApps\CommandLineApps\ffmpeg-20170702-c885356-win64-static\bin\ffmpeg.exe"
    $ffplayBin = "Z:\PortableApps\CommandLineApps\ffmpeg-20170702-c885356-win64-static\bin\ffplay.exe"

    if
    (
    -not (Test-Path -Path $streamDir -PathType Any)
    )

    {
    New-Item $streamDir -type directory -ErrorAction SilentlyContinue
    }

    Start-Process -FilePath $ffmpegBin -ArgumentList "-loglevel quiet -i $streamExtractor -c copy $streamDir\streamContainer.m2ts" -NoNewWindow -ErrorAction SilentlyContinue

    Do
    {
    Start-Sleep -Seconds 1
    }

    Until
    (
    (Get-Item $streamDir\streamContainer.m2ts -ErrorAction SilentlyContinue).Length -gt 256kb
    )

    &$ffplayBin -loglevel quiet $streamDir\streamContainer.m2ts

    if
    (
    (Test-Path -Path $streamDir -PathType Any) -eq $true -and (Get-Process -Name ffplay -ErrorAction SilentlyContinue) -eq $null
    )

    {

    Do
    {
    Stop-Process -Name ffmpeg -ErrorAction SilentlyContinue
    }

    Until
    (
    (Get-Process -Name ffmpeg -ErrorAction SilentlyContinue) -eq $null
    )

    Remove-Item $streamDir -Recurse -ErrorAction SilentlyContinue
    }
    }

    End
    {
    }

    }

    streamer -streamURL https://www.youtube.com/watch?v=9uFXw7vKz14

    END POWERSHELL