Recherche avancée

Médias (0)

Mot : - Tags -/flash

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

Autres articles (50)

  • 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

  • Contribute to documentation

    13 avril 2011

    Documentation is vital to the development of improved technical capabilities.
    MediaSPIP welcomes documentation by users as well as developers - including : critique of existing features and functions articles contributed by developers, administrators, content producers and editors screenshots to illustrate the above translations of existing documentation into other languages
    To contribute, register to the project users’ mailing (...)

  • Ajouter notes et légendes aux images

    7 février 2011, par

    Pour pouvoir ajouter notes et légendes aux images, la première étape est d’installer le plugin "Légendes".
    Une fois le plugin activé, vous pouvez le configurer dans l’espace de configuration afin de modifier les droits de création / modification et de suppression des notes. Par défaut seuls les administrateurs du site peuvent ajouter des notes aux images.
    Modification lors de l’ajout d’un média
    Lors de l’ajout d’un média de type "image" un nouveau bouton apparait au dessus de la prévisualisation (...)

Sur d’autres sites (7285)

  • Concatenate videos and add black frames between them with ffmpeg

    4 octobre 2024, par user3406207

    I have three videos that I am concatenating with ffmpeg. I would like to add a few black frames in between them. Although I've found a few hints on the web it has not worked for me yet. I have tried to generate an 'empty' video with just black frames with :

    



    ffmpeg -t 20 -s 1920x1080 -f rawvideo -pix_fmt rgb24 -r 25 -i c:\nul  E:\empty.avi


    



    and then concatenate with another one but doesn't work. I have tried a few other things without success. Any help would be greatly appreciated

    



    EDIT : also tried to add black frames before and after video with the following code, but no success :

    



    ffmpeg -f lavfi -i color=c=black:s=1920x1080:r=25:d=100 -i middle_video.avi -filter_complex 
"[0:v]trim=start_frame=1:end_frame=21[blackstart];
[0:v] trim=start_frame=1:end_frame=21 [blackend]; 
[blackstart] [1:v] [blackend] concat=n=3:v=1:a=0[out]" -map "[out]" -c:v qtrle -c:a -copy output.avi


    



    EDIT2 :
Output from ffprobe

    



    Metadata:
encoder: Lavf57.3.100
Duration: 00:00:10.05, start: 0.000000, bitrate: 43302 kb/s
Stream #0:0: Video: mpeg4 (Simple Profile) (FMP4 / 0x34504D46), yuv420p, 192
0x1080 [SAR 1:1 DAR 16:9], 43333 kb/s, 23.98 fps, 23.98 tbr, 23.98 tbn, 10k tbc
Stream #0:1: Audio: mp3 (U[0][0][0] / 0x0055), 48000 Hz, stereo, s16p, 128 k
b/s


    



    EDIT 3
Link to the report of the ffmpeg console output :
FFMPEG session report

    


  • ffmpeg to make black video with multiple audio and subtitles [closed]

    9 septembre 2024, par Tony M

    I want to use ffmpeg to make a video with only audio and subtitles in different languages. The video part can be a simple black background. I want to be able to switch between languages in video players like QuickTime.

    


    I've tried to get help from posts like this, but I couldn't figure out how to get it to work.

    


    To demonstrate that I've worked a long time on this, I'm showing what I've come up with below — but only steps (1) & (2) work. I can't get the subtitles step (3) to work.

    


    I've used ffmpeg for a long time, but never really understood it... I've only recently started to build my own commands, so the following probably looks awful to an expert :

    


      

    1. make a silent video using

      


      ffmpeg -loop 1 -i black.jpg -i silent.mp3 -acodec copy -shortest -vf scale=1000:136 silent.mov

      


    2. 


    


    where m.jpg is a 500x68 black image and m.mp3 has 5 min of silence

    


      

    1. add 3 language (italian, french, german) using

      


      ffmpeg -i silent.mov -i ita.mp3 -i fre.mp3 -i ger.mp3 -map 0:v -map 1:a -map 2:a -map 3:a -metadata:s:a:0 language=ita -metadata:s:a:1 language=fre -metadata:s:a:2 language=ger ita-fre-ger.mov

      


    2. 


    3. add subtitles using (doesn't work)

      


    4. 


    


    ffmpeg -i ita-fre-ger.mov -i ita.srt -i fre.srt -i ger.srt -map 0 -map 1 -map 2 -map 3 -c copy -c:s mov_text -metadata:s:s:0 language=ita -metadata:s:s:1 language=fre -metadata:s:s:2 language=ger final.mov

    


  • Xvfb records a black screen

    11 mai 2024, par Vivek

    I am trying a record a video by running xvfb inside a docker image. No matter what I do it gives me black screen.

    


    Screen size same in xvfb and ffmpeg and puppeteer.

    


    It will would really great if someone can help.

    


    
start-xvfb.sh
---------------------------------------------------------------------
# Start Xvfb
Xvfb :99 -screen 0 1280x720x24 &

# Set the display environment variable
export DISPLAY=:99

# Run the application (assuming it starts with npm start)
npm run dev


    


    Dockerfile

    


    FROM node:lts-alpine3.19

# Install dependencies using apk
RUN apk update && \
    apk add --no-cache \
    gnupg \
    ffmpeg \
    libx11 \
    libxcomposite \
    libxdamage \
    libxi \
    libxtst \
    nss \
    cups-libs \
    libxrandr \
    alsa-lib \
    pango \
    gtk+3.0 \
    xvfb \
    bash \
    curl \
    udev \
    ttf-freefont \
    chromium \
    chromium-chromedriver

# Set working directory
WORKDIR /app

# Copy package.json and install dependencies
COPY package.json .
RUN npm install --force

# Copy remaining source code
COPY . .

# Add a script to start Xvfb
COPY start-xvfb.sh /app/start-xvfb.sh
RUN chmod +x /app/start-xvfb.sh

# Expose the port
EXPOSE 4200
EXPOSE 3000

# Command to start Xvfb and run the application
CMD ["./start-xvfb.sh"]


    


    Below

    


    this is code code that launches puppeteer and from a nodejs application and create spawns a process for ffmpeg

    


    export class UnixBrowserRecorder implements Recorder {&#xA;&#xA;  url = &#x27;https://stackoverflow.com/questions/3143698/uncaught-syntaxerror-unexpected-token&#x27;; // Replace with your URL&#xA;  outputFilePath = `/app/output_video.mp4`; // Output file path within the container&#xA;  durationInSeconds = 6; // Duration of the video in seconds&#xA;  resolution = &#x27;1280x720&#x27;;&#xA;&#xA;  public async capture(): Promise<string> {&#xA;    const browser = await puppeteer.launch({&#xA;      args: [&#xA;        &#x27;--no-sandbox&#x27;, // Required in Docker&#xA;        &#x27;--disable-setuid-sandbox&#x27;, // Required in Docker&#xA;        &#x27;--disable-dev-shm-usage&#x27;, // Required in Docker&#xA;        &#x27;--headless&#x27;, // Run browser in headless mode&#xA;        &#x27;--disable-gpu&#x27;, // Disable GPU acceleration&#xA;        `--window-size=${this.resolution}` // Set window size&#xA;      ],&#xA;      executablePath: &#x27;/usr/bin/chromium&#x27; // Specify the path to Chromium executable&#xA;    });&#xA;&#xA;    const page = await browser.newPage();&#xA;    await page.goto(this.url);&#xA;&#xA;    await page.screenshot({&#xA;      "type": "png", // can also be "jpeg" or "webp" (recommended)&#xA;      "path": `/app/screenshot.png`,  // where to save it&#xA;      "fullPage": true,  // will scroll down to capture everything if true&#xA;    });&#xA;&#xA;    //ffmpeg -video_size `DISPLAY=:5 xdpyinfo | grep &#x27;dimensions:&#x27;|awk &#x27;{print $2}&#x27;` -framerate 30 -f x11grab -i :5.0&#x2B;0,0 output.mpg&#xA;&#xA;    const ffmpegProcess = spawn(&#x27;ffmpeg&#x27;, [&#xA;      &#x27;-video_size&#x27;, this.resolution,&#xA;      &#x27;-framerate&#x27;, &#x27;30&#x27;,&#xA;      &#x27;-f&#x27;, &#x27;x11grab&#x27;,&#xA;      &#x27;-i&#x27;, &#x27;:99&#x27;, // Use display :99 (assuming Xvfb is running on this display)&#xA;      &#x27;-t&#x27;, this.durationInSeconds.toString(),&#xA;      &#x27;-c:v&#x27;, &#x27;libx264&#x27;,&#xA;      &#x27;-loglevel&#x27;, &#x27;debug&#x27;,&#xA;      &#x27;-pix_fmt&#x27;, &#x27;yuv420p&#x27;,&#xA;      this.outputFilePath&#xA;    ]);&#xA;&#xA;    // Log ffmpeg output&#xA;    ffmpegProcess.stdout.on(&#x27;data&#x27;, data => {&#xA;      console.log(`ffmpegProcess stdout: ${data}`);&#xA;    });&#xA;&#xA;    ffmpegProcess.stderr.on(&#x27;data&#x27;, data => {&#xA;      console.error(`ffmpegProcess stderr: ${data}`);&#xA;    });&#xA;&#xA;    // Handle ffmpegProcess process exit&#xA;    ffmpegProcess.on(&#x27;close&#x27;, code => {&#xA;      console.log(`ffmpeg process exited with code ${code}`);&#xA;    });&#xA;&#xA;    // Wait for the duration to complete&#xA;    await new Promise(resolve => setTimeout(resolve, this.durationInSeconds * 1000));&#xA;&#xA;    // Close the FFmpeg stream and process&#xA;    ffmpegProcess.stdin.end();&#xA;    // Close Puppeteer&#xA;    await page.close();&#xA;    await browser.close();&#xA;&#xA;    return "Video generated successfully";&#xA;  }&#xA;}&#xA;</string>

    &#xA;

    enter image description here

    &#xA;