Recherche avancée

Médias (0)

Mot : - Tags -/auteurs

Aucun média correspondant à vos critères n’est disponible sur le site.

Autres articles (13)

  • Other interesting software

    13 avril 2011, par

    We don’t claim to be the only ones doing what we do ... and especially not to assert claims to be the best either ... What we do, we just try to do it well and getting better ...
    The following list represents softwares that tend to be more or less as MediaSPIP or that MediaSPIP tries more or less to do the same, whatever ...
    We don’t know them, we didn’t try them, but you can take a peek.
    Videopress
    Website : http://videopress.com/
    License : GNU/GPL v2
    Source code : (...)

  • Le plugin : Podcasts.

    14 juillet 2010, par

    Le problème du podcasting est à nouveau un problème révélateur de la normalisation des transports de données sur Internet.
    Deux formats intéressants existent : Celui développé par Apple, très axé sur l’utilisation d’iTunes dont la SPEC est ici ; Le format "Media RSS Module" qui est plus "libre" notamment soutenu par Yahoo et le logiciel Miro ;
    Types de fichiers supportés dans les flux
    Le format d’Apple n’autorise que les formats suivants dans ses flux : .mp3 audio/mpeg .m4a audio/x-m4a .mp4 (...)

  • 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 (3992)

  • Merge commit ’6fe2641d6e410b7bc203138fa97e1118b411f16d’

    29 mars 2015, par Michael Niedermayer
    Merge commit ’6fe2641d6e410b7bc203138fa97e1118b411f16d’
    

    * commit ’6fe2641d6e410b7bc203138fa97e1118b411f16d’ :
    lavc : add profile define for DTS Express

    Conflicts :
    doc/APIchanges
    libavcodec/version.h

    See : 11fe56c8bbf39cd0c3edbf0cd404dea400ff7e0c
    Merged-by : Michael Niedermayer <michaelni@gmx.at>

    • [DH] doc/APIchanges
  • Discord bot not playing any audio

    7 mars 2023, par Markix

    I'm making a discord music bot with Discord.js v14, @discordjs/voice, and Typescript and I have this play command but it doesn't seem to be working. It successfully joins, throws no exceptions but... no audio.

    &#xA;

    This is my code :

    &#xA;

    import { CommandInteraction, SlashCommandBuilder } from "discord.js";&#xA;import { joinVoiceChannel, createAudioPlayer, getVoiceConnections, StreamType, AudioPlayerStatus } from "@discordjs/voice";&#xA;import { createAudioResource } from "@discordjs/voice";&#xA;import ytdl from &#x27;ytdl-core&#x27;;&#xA;&#xA;module.exports = {&#xA;    data: new SlashCommandBuilder()&#xA;        .setName(&#x27;play&#x27;)&#xA;        .setDescription(&#x27;Play př&#xED;kaz&#x27;)&#xA;        .addStringOption(option => &#xA;            option&#xA;                .setName("link")&#xA;                .setDescription("Youtube link!")&#xA;                .setRequired(false)&#xA;        ),&#xA;&#xA;async execute(interaction: CommandInteraction) {&#xA;        const link = interaction.options.get(&#x27;link&#x27;)?.value?.toString();&#xA;        const player = createAudioPlayer();&#xA;        const resource = createAudioResource(ytdl(`${link}`, { filter: "audioonly" }), { inlineVolume: 1.0, inputType: StreamType.WebmOpus });&#xA;&#xA;    player.play(resource);&#xA;&#xA;    const connection = joinVoiceChannel({&#xA;        channelId: "775815628619251743",&#xA;        guildId: "775761665786511370",&#xA;        adapterCreator: interaction.guild?.voiceAdapterCreator,&#xA;        selfMute?: false,&#xA;        selfDeaf: false&#xA;    });&#xA;&#xA;    const subscription = connection.subscribe(player);&#xA;    interaction.reply("Now playing: .-.");&#xA;}&#xA;

    &#xA;

    This is "dependencies" in my package.json

    &#xA;

      "dependencies": {&#xA;    "@discordjs/builders": "^1.2.0",&#xA;    "@discordjs/rest": "^1.5.0",&#xA;    "@discordjs/voice": "^0.14.0",&#xA;    "@types/express": "^4.17.14",&#xA;    "discord.js": "^14.4.0",&#xA;    "dotenv": "^16.0.2",&#xA;    "express": "^4.18.1",&#xA;    "ffmpeg": "^0.0.4",&#xA;    "ffmpeg-static": "^5.1.0",&#xA;    "libsodium-wrappers": "^0.7.11",&#xA;    "opusscript": "^0.0.8",&#xA;    "sequelize": "^6.23.2",&#xA;    "sqlite3": "^5.1.2",&#xA;    "ts-node": "^10.9.1",&#xA;    "ytdl-core": "^4.11.2"&#xA;  }&#xA;

    &#xA;

    (And yes I also have ffmpeg installed globally)

    &#xA;

    markix@pop-os-lenovo-laptop:~$ apt list --installed | grep -i ffmpeg &#xA;&#xA;WARNING: apt does not have a stable CLI interface. Use with caution in scripts.&#xA;&#xA;chromium-codecs-ffmpeg-extra/jammy,now 1:85.0.4183.83-0ubuntu2 amd64 [installed,upgradable to: 1:85.0.4183.83-0ubuntu2.22.04.1]&#xA;ffmpeg/jammy-security,jammy-updates,now 7:4.4.2-0ubuntu0.22.04.1 amd64 [installed,automatic]&#xA;

    &#xA;

    What am I doing wrong ?

    &#xA;

  • Promise chaining and resolution

    23 janvier 2019, par Shourya Sharma

    I am trying to convert videos one by one with the help of promises. i am using ffmpeg for conversion and multer for uploading multiple files.

    multer uploads multiple files at once after which i have to chain the conversions one by one. as of now it just converts the 1st file.

    i thought chaining of promises ..like in an array should work but i am confused if i can define new promises in an array as ffmpeg also returns a promise

    My router :

    const router = require('express').Router();
    const multer = require('multer');
    const ffmpeg = require('ffmpeg');

    let str;
    const storage = multer.diskStorage({
     destination: (req, file, cb) => {
       cb(null, './uploads');
     },
     filename: (req, file, cb) => {
       str = file.originalname.replace(/\.[^/.]+$/, "");
       str = str.replace(/[^a-z0-9+]+/gi, '_') + '.' + file.originalname.replace(/^.*\./, '');
       cb(null, str);
     }
    });

    const upload = multer({ storage: storage }).array('files', 12);

    router.post('/upload', (req, res, next) => {
     // req.files is an array of files
     // req.body will contain the text fields, if there were any
     function uploadFile() {
       return new Promise((resolve, reject) => {
         upload(req, res, (err) => {
           if (err) {
             res.send(err) // Pass errors to Express.
             reject(`Error: Something went wrong!`);
           } else if (req.files == undefined) {
             res.send(`No File selected.`);
             resolve();
           } else if (!err &amp;&amp; req.files.length > 0) {
             res.status(201).send(`${req.files.length} File(s): ${req.files} uploaded successfully.`);
             console.log('uploaded');
             resolve();
           }
         });
       });
     }

     uploadFile().then(() => {
       try {
         var process = new ffmpeg('./uploads/' + str);
         process.then(function (video) {
           console.log('The video is ready to be processed');
           video.addCommand('-hide_banner', '');
           video.addCommand('-y', '');
           video.addCommand('-c:a', 'aac');
           video.addCommand('-ar', '48000');
           video.addCommand('-c:v', 'h264');
           video.addCommand('-profile:v', 'main');
           video.addCommand('-crf', '20');
           video.addCommand('-sc_threshold', '0');
           video.addCommand('-g', '50');
           video.addCommand('-keyint_min', '50');
           video.addCommand('-hls_time', '4');
           video.addCommand('-hls_playlist_type', 'vod');
           video.addCommand('-vf', 'scale=-2:720');
           video.addCommand('-b:v', '1400k');
           video.addCommand('-maxrate', '1498k');
           video.addCommand('-bufsize', '2100k');
           video.addCommand('-b:a', '128k');
           video.save('./converted/' + str, function (error, file) {
             if (!error)
               console.log('Video file: ' + file);
           });
           }, function (err) {
             console.log('Error: ' + err);
           });
       } catch (e) {
         console.log(e.code);
         console.log(e.msg);
       }
     }).catch((err) => {
       console.log(Error, err);
     });
    });

    module.exports = router;