Recherche avancée

Médias (2)

Mot : - Tags -/doc2img

Autres articles (57)

  • XMP PHP

    13 mai 2011, par

    Dixit Wikipedia, XMP signifie :
    Extensible Metadata Platform ou XMP est un format de métadonnées basé sur XML utilisé dans les applications PDF, de photographie et de graphisme. Il a été lancé par Adobe Systems en avril 2001 en étant intégré à la version 5.0 d’Adobe Acrobat.
    Étant basé sur XML, il gère un ensemble de tags dynamiques pour l’utilisation dans le cadre du Web sémantique.
    XMP permet d’enregistrer sous forme d’un document XML des informations relatives à un fichier : titre, auteur, historique (...)

  • Use, discuss, criticize

    13 avril 2011, par

    Talk to people directly involved in MediaSPIP’s development, or to people around you who could use MediaSPIP to share, enhance or develop their creative projects.
    The bigger the community, the more MediaSPIP’s potential will be explored and the faster the software will evolve.
    A discussion list is available for all exchanges between users.

  • MediaSPIP en mode privé (Intranet)

    17 septembre 2013, par

    À partir de la version 0.3, un canal de MediaSPIP peut devenir privé, bloqué à toute personne non identifiée grâce au plugin "Intranet/extranet".
    Le plugin Intranet/extranet, lorsqu’il est activé, permet de bloquer l’accès au canal à tout visiteur non identifié, l’empêchant d’accéder au contenu en le redirigeant systématiquement vers le formulaire d’identification.
    Ce système peut être particulièrement utile pour certaines utilisations comme : Atelier de travail avec des enfants dont le contenu ne doit pas (...)

Sur d’autres sites (7917)

  • ffmpeg - add music to an audiobook, and loop the music [closed]

    23 novembre 2024, par Rhys

    I found these example, and they all work. But I cannot overlay 2 audios and loop the shortest audio until the longest audio is finished.

    


    Audio to match Video Length

    


    ffmpeg -i VIDEO1.mp4 -stream_loop -1 -i bgmusic.mp3 -shortest -c:v copy -c:a aac -map 0:v:0 -map 1:a:0 output.mp4


    


    Loop Audio

    


    ffmpeg -i audio.mp3 -filter_complex "aloop=loop=-1:size=10" output_loop.mp3


    


    Overlay 2 Audios

    


    ffmpeg -y -i bgmusic.mp3 -i audio.mp3 -filter_complex "[0:0]volume=1.0[a];[1:0]volume=1.0[b];[a][b]amix=inputs=2:duration=longest" -c:a libmp3lame output.mp3


    


    Here is my attempt.

    


    ffmpeg -y -i audio.mp3 -stream_loop -1 -i bgmusic.mp3 -shortest -filter_complex "[0:0]volume=1.0[a];[1:0]volume=1.0[b];[a][b]amix=inputs=2:duration=longest" -c:a libmp3lame output.mp3


    


    But this example is looping bgmusic.mp3 forever ... and audio.mp3 is stopping after the song finishes

    


    how can I get to audios to play togeather, but the shortest audio loops until the longest audio is finished ?

    


  • I need my music bot to play on multiple servers at the same time

    12 mars 2024, par Ondosh

    I'm writing my music bot in Python and I want it to be able to play music on multiple servers at once. Now the attempt to play on several servers looks like this : I start music on the first server, go to the second and start other music there, but the one that was requested on the first one is playing.
Know my code is :

    


    from nextcord.ext import commands
import nextcord, random
import yt_dlp
import datetime
import lazy_queue as lq

FFMPEG_OPTIONS = {
    "before_options": "-reconnect 1 -reconnect_streamed 1 -reconnect_delay_max 5",
    'options': '-vn'}

YDL_OPTIONS = {
    'format': 'bestaudio/best',
    'extractaudio': True,
    'noplaylist': True,
    'keepvideo': False,
    'postprocessors': [{
        'key': 'FFmpegExtractAudio',
        'preferredcodec': 'mp3',
        'preferredquality': '320'
    }]
}

bot.remove_command("help")
songs_queue = lq.Queue()
loop_flag = False

@bot.command()
async def add(ctx, *url):
    url = ' '.join(url)
    with yt_dlp.YoutubeDL(YDL_OPTIONS) as ydl:
        try:
            info = ydl.extract_info(url, download=False)
        except:
            info = ydl.extract_info(f"ytsearch:{url}",
                                    download=False)['entries'][0]
    URL = info['url']
    name = info['title']
    time = str(datetime.timedelta(seconds=info['duration']))
    songs_queue.q_add([name, time, URL])
    embed = nextcord.Embed(description=f'Записываю [{name}]({url}) в очередь 📝',
                           colour=nextcord.Colour.red())
    await ctx.message.reply(embed=embed)


def step_and_remove(voice_client):
    if loop_flag:
        songs_queue.q_add(songs_queue.get_value()[0])
    songs_queue.q_remove()
    audio_player_task(voice_client)


def audio_player_task(voice_client):
    if not voice_client.is_playing() and songs_queue.get_value():
        voice_client.play(nextcord.FFmpegPCMAudio(
            executable="ffmpeg\\bin\\ffmpeg.exe",
            source=songs_queue.get_value()[0][2],
            **FFMPEG_OPTIONS),
            after=lambda e: step_and_remove(voice_client))


@bot.command()
async def play(ctx, *url):
    await join(ctx)
    await add(ctx, ' '.join(url))
    await ctx.message.add_reaction(emoji='🎸')
    voice_client = ctx.guild.voice_client
    audio_player_task(voice_client)
async def queue(ctx):
    if len(songs_queue.get_value()) > 0:
        only_names_and_time_queue = []
        for i in songs_queue.get_value():
            name = i[0]
            if len(i[0]) > 30:
                name = i[0][:30] + '...'
            only_names_and_time_queue.append(f'📀 `{name:<33}   {i[1]:>20}`\n')
        c = 0
        queue_of_queues = []
        while c < len(only_names_and_time_queue):
            queue_of_queues.append(only_names_and_time_queue[c:c + 10])
            c += 10
        embed = nextcord.Embed(title=f'ОЧЕРЕДЬ [LOOP: {loop_flag}]',
                               description=''.join(queue_of_queues[0]),
                               colour=nextcord.Colour.red())
        await ctx.send(embed=embed)
        for i in range(1, len(queue_of_queues)):
            embed = nextcord.Embed(description=''.join(queue_of_queues[i]),
                                   colour=nextcord.Colour.red())
            await ctx.send(embed=embed)
    else:
        await ctx.send('Очередь пуста')


    


    As far as I understand, I need to create variables that will be associated with the server ID, but I do not know how to do this.

    


  • FFmpeg - ducking music for voiceover (sidechain)

    7 décembre 2023, par kaushal

    I am trying to duck the background music from a voiceover input file using FFmpeg (I tried doing this using pydub with no success).

    


    The below command is predominantly working, except that it is truncating my background music file (main.mp3, over 3 min long) to the length of the voiceover file (taekwondo.mp3, about a min long). Any idea or suggestion on what can I change in below command so that the output file is full 3 min long, with background music ducked when the voiceover is playing. Once the voiceover completes, background music continues to play as normal.

    


    In below complex filter, this is what I'm doing :
adelay filter : to start voiceover playing after 5 seconds into background music
volume filter : Since my background music is too loud and voiceover is too low, I'm increasing voiceover volume by 1.5 times, and lowering background music volume to 0.7 times
sidechaincompress filter : Then I'm applying sidechain filter to duck background music whenever voiceover is playing, with usual threshold, ratio & release filters

    


    I've tried both amix & amerge, but results in same behaviour.

    


    ffmpeg -i main.mp3 -i taekwondo.mp3 -filter_complex "[1:a]adelay=5000|5000,volume=1.5[a];[0:a]volume=0.7[b];[a]asplit=2[sc][mix];[b][sc]sidechaincompress=threshold=0.05:ratio=20:level_sc=1:release=500:attack=1[compr];[compr][mix]amix" output.mp3