Recherche avancée

Médias (3)

Mot : - Tags -/image

Autres articles (96)

  • Encoding and processing into web-friendly formats

    13 avril 2011, par

    MediaSPIP automatically converts uploaded files to internet-compatible formats.
    Video files are encoded in MP4, Ogv and WebM (supported by HTML5) and MP4 (supported by Flash).
    Audio files are encoded in MP3 and Ogg (supported by HTML5) and MP3 (supported by Flash).
    Where possible, text is analyzed in order to retrieve the data needed for search engine detection, and then exported as a series of image files.
    All uploaded files are stored online in their original format, so you can (...)

  • Encodage et transformation en formats lisibles sur Internet

    10 avril 2011

    MediaSPIP transforme et ré-encode les documents mis en ligne afin de les rendre lisibles sur Internet et automatiquement utilisables sans intervention du créateur de contenu.
    Les vidéos sont automatiquement encodées dans les formats supportés par HTML5 : MP4, Ogv et WebM. La version "MP4" est également utilisée pour le lecteur flash de secours nécessaire aux anciens navigateurs.
    Les documents audios sont également ré-encodés dans les deux formats utilisables par HTML5 :MP3 et Ogg. La version "MP3" (...)

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

Sur d’autres sites (6089)

  • The problem of code that generated typescript (node-fluent-ffmpeg module)

    10 décembre 2022, par Steve Rock

    This is my typescript code :

    



    import { NestFactory } from '@nestjs/core';
import { AppModule } from './app.module';
import { FfmpegCommand } from 'fluent-ffmpeg'

async function bootstrap() {
  const app = await NestFactory.create(AppModule);
  let test

  try {
    test = new FfmpegCommand('./adventure.mkv');
  } catch (error) {
    console.log(error);

  }

  await app.listen(3000);
}

bootstrap();


    



    Generated Javascript code :

    



    "use strict";
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
    function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
    return new (P || (P = Promise))(function (resolve, reject) {
        function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
        function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
        function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
        step((generator = generator.apply(thisArg, _arguments || [])).next());
    });
};
Object.defineProperty(exports, "__esModule", { value: true });
const core_1 = require("@nestjs/core");
const app_module_1 = require("./app.module");
const fluent_ffmpeg_1 = require("fluent-ffmpeg");
function bootstrap() {
    return __awaiter(this, void 0, void 0, function* () {
        const app = yield core_1.NestFactory.create(app_module_1.AppModule);
        let test;
        try {
            test = new fluent_ffmpeg_1.FfmpegCommand('./adventure.mkv');
        }
        catch (error) {
            console.log(error);
        }
        yield app.listen(3000);
    });
}
bootstrap();
//# sourceMappingURL=main.js.map


    



    When I run this application I've next error :

    



    main.ts:12
message :"fluent_ffmpeg_1.FfmpegCommand is not a constructor"
stack :"TypeError : fluent_ffmpeg_1.FfmpegCommand is not a constructor\n at c :\nest\dist\src\main.js:20:20\n at Generator.next ()\n at fulfilled (c :\nest\dist\src\main.js:5:58)\n at process._tickCallback (internal/process/next_tick.js:68:7)\n at Function.Module.runMain (internal/modules/cjs/loader.js:834:11)\n at startup (internal/bootstrap/node.js:283:19)\n at bootstrapNodeJSCore (internal/bootstrap/node.js:622:3)"

    



    That's beacause this raw test = new fluent_ffmpeg_1.FfmpegCommand('./adventure.mkv'). When I change this on just test = new fluent_ffmpeg_1('./adventure.mkv') I haven't the error. Do you know how to fix it. If you know where are ffmpeg exapmles on typescript please share with me :)

    


  • FFMPEG - live stream with dynamic content

    6 octobre 2019, par Arturek

    I’m trying to create a live stream with changing data in real-time on youtube.

    Let’s say I want to show the current Bitcoin price in real-time. For instance, using python and sending requests to some public APIs, I can very easily get current prices of Bitcoin. But I have no idea how to create such a live stream, which will be automatically updated with fresh data.

    I know that I can use ffmpeg to stream on youtube, but how would I change the content of my stream ? I know how to create an image every n seconds with the current price, but then I don’t know how to update my live stream with this image.

    # To make sure you know what I mean, I created a basic sample.

    import requests
    import json
    import time

    createYtLiveStream()

    while(True):
     response = requests.get('https://api.coindesk.com/v1/bpi/currentprice.json').json()
     price = response['bpi']['USD']['rate']

     # Create an image with Bitcoin price inside
     img = convertTextToPng(price)

     # Update my live stream with this new image (I don't know how to do it)
     updateYtLiveStream(img)

     time.sleep(20)

    I want to do it on Ubuntu. Can you tell me how can I do it, please ?
    Thanks.

  • Youtube live stream with dynamic content

    6 octobre 2019, par Arturek

    I’m trying to create a live stream with changing data in real-time on youtube.

    Let’s say I want to show the current Bitcoin price in real-time. For instance, using python and sending requests to some public APIs, I can very easily get current prices of Bitcoin. But I have no idea how to create such a live stream, which will be automatically updated with fresh data.

    I know that I can use ffmpeg to stream on youtube, but how would I change the content of my stream ?

    # To make sure you know what I mean, I created a basic sample.

    import requests
    import json
    import time

    createYtLiveStream()

    while(True):
     response = requests.get('https://api.coindesk.com/v1/bpi/currentprice.json').json()
     price = response['bpi']['USD']['rate']

     updateYtLiveStream(price)

     time.sleep(20)

    I want to do it on Ubuntu. Can you tell me how can I do it, please ?
    Thanks.