
Recherche avancée
Médias (91)
-
MediaSPIP Simple : futur thème graphique par défaut ?
26 septembre 2013, par
Mis à jour : Octobre 2013
Langue : français
Type : Video
-
avec chosen
13 septembre 2013, par
Mis à jour : Septembre 2013
Langue : français
Type : Image
-
sans chosen
13 septembre 2013, par
Mis à jour : Septembre 2013
Langue : français
Type : Image
-
config chosen
13 septembre 2013, par
Mis à jour : Septembre 2013
Langue : français
Type : Image
-
SPIP - plugins - embed code - Exemple
2 septembre 2013, par
Mis à jour : Septembre 2013
Langue : français
Type : Image
-
GetID3 - Bloc informations de fichiers
9 avril 2013, par
Mis à jour : Mai 2013
Langue : français
Type : Image
Autres articles (87)
-
Ecrire une actualité
21 juin 2013, parPré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 ) (...) -
Organiser par catégorie
17 mai 2013, parDans MédiaSPIP, une rubrique a 2 noms : catégorie et rubrique.
Les différents documents stockés dans MédiaSPIP peuvent être rangés dans différentes catégories. On peut créer une catégorie en cliquant sur "publier une catégorie" dans le menu publier en haut à droite ( après authentification ). Une catégorie peut être rangée dans une autre catégorie aussi ce qui fait qu’on peut construire une arborescence de catégories.
Lors de la publication prochaine d’un document, la nouvelle catégorie créée sera proposée (...) -
Les tâches Cron régulières de la ferme
1er décembre 2010, parLa gestion de la ferme passe par l’exécution à intervalle régulier de plusieurs tâches répétitives dites Cron.
Le super Cron (gestion_mutu_super_cron)
Cette tâche, planifiée chaque minute, a pour simple effet d’appeler le Cron de l’ensemble des instances de la mutualisation régulièrement. Couplée avec un Cron système sur le site central de la mutualisation, cela permet de simplement générer des visites régulières sur les différents sites et éviter que les tâches des sites peu visités soient trop (...)
Sur d’autres sites (3761)
-
How to combine 100 video clips with transition using FFMPEG ? [closed]
17 octobre 2024, par Muhammad Lutfi RahmawanI've been working on project which involves FFMPEG to process video. The goal is to produce a video from several clips and combine them with transition to each clips. We've succeeded to create video from 20 clips and 19 transitions are applied to merge each clips. But when it comes to a larger amount of clips, say 50, it becomes be failed.


The first thing we do is split the original video into several clips based on user selection and this command is successful (log splitting). Then we combine the clips with transition using below command.


Here is the sample command of FFMPEG which failed :


ffmpeg -y -i /tmp/0.mp4 -i /tmp/1.mp4 -i /tmp/2.mp4 -i /tmp/3.mp4 -i /tmp/4.mp4 -i /tmp/5.mp4 -i /tmp/6.mp4 -i /tmp/7.mp4 -i /tmp/8.mp4 -i /tmp/9.mp4 -i /tmp/10.mp4 -i /tmp/11.mp4 -i /tmp/12.mp4 -i /tmp/13.mp4 -i /tmp/14.mp4 -i /tmp/15.mp4 -i /tmp/16.mp4 -i /tmp/17.mp4 -i /tmp/18.mp4 -i /tmp/19.mp4 -i /tmp/20.mp4 -i /tmp/21.mp4 -i /tmp/22.mp4 -i /tmp/23.mp4 -i /tmp/24.mp4 -i /tmp/25.mp4 -i /tmp/26.mp4 -i /tmp/27.mp4 -i /tmp/28.mp4 -i /tmp/29.mp4 -i /tmp/30.mp4 -i /tmp/31.mp4 -i /tmp/32.mp4 -i /tmp/33.mp4 -i /tmp/34.mp4 -i /tmp/35.mp4 -i /tmp/36.mp4 -i /tmp/37.mp4 -i /tmp/38.mp4 -i /tmp/39.mp4 -i /tmp/40.mp4 -i /tmp/41.mp4 -i /tmp/42.mp4 -i /tmp/43.mp4 -i /tmp/44.mp4 -i /tmp/45.mp4 -i /tmp/46.mp4 -i /tmp/47.mp4 -i /tmp/48.mp4 -i /tmp/49.mp4 -filter_complex "[0:v][1:v]xfade=transition=circlecrop:duration=0.5:offset=24.474[tv0];[0:a][1:a]acrossfade=d=0.5[ta0];[tv0][2:v]xfade=transition=circlecrop:duration=0.5:offset=31.674[tv1];[ta0][2:a]acrossfade=d=0.5[ta1];[tv1][3:v]xfade=transition=circlecrop:duration=0.5:offset=37.234[tv2];[ta1][3:a]acrossfade=d=0.5[ta2];[tv2][4:v]xfade=transition=circlecrop:duration=0.5:offset=55.348[tv3];[ta2][4:a]acrossfade=d=0.5[ta3];[tv3][5:v]xfade=transition=circlecrop:duration=0.5:offset=76.07[tv4];[ta3][5:a]acrossfade=d=0.5[ta4];[tv4][6:v]xfade=transition=circlecrop:duration=0.5:offset=82.622[tv5];[ta4][6:a]acrossfade=d=0.5[ta5];[tv5][7:v]xfade=transition=circlecrop:duration=0.5:offset=103.122[tv6];[ta5][7:a]acrossfade=d=0.5[ta6];[tv6][8:v]xfade=transition=circlecrop:duration=0.5:offset=114.502[tv7];[ta6][8:a]acrossfade=d=0.5[ta7];[tv7][9:v]xfade=transition=circlecrop:duration=0.5:offset=122.258[tv8];[ta7][9:a]acrossfade=d=0.5[ta8];[tv8][10:v]xfade=transition=circlecrop:duration=0.5:offset=130.094[tv9];[ta8][10:a]acrossfade=d=0.5[ta9];[tv9][11:v]xfade=transition=circlecrop:duration=0.5:offset=134.33[tv10];[ta9][11:a]acrossfade=d=0.5[ta10];[tv10][12:v]xfade=transition=circlecrop:duration=0.5:offset=141.85[tv11];[ta10][12:a]acrossfade=d=0.5[ta11];[tv11][13:v]xfade=transition=circlecrop:duration=0.5:offset=145.59[tv12];[ta11][13:a]acrossfade=d=0.5[ta12];[tv12][14:v]xfade=transition=circlecrop:duration=0.5:offset=154.314[tv13];[ta12][14:a]acrossfade=d=0.5[ta13];[tv13][15:v]xfade=transition=circlecrop:duration=0.5:offset=155.998[tv14];[ta13][15:a]acrossfade=d=0.5[ta14];[tv14][16:v]xfade=transition=circlecrop:duration=0.5:offset=164.924[tv15];[ta14][16:a]acrossfade=d=0.5[ta15];[tv15][17:v]xfade=transition=circlecrop:duration=0.5:offset=168.184[tv16];[ta15][17:a]acrossfade=d=0.5[ta16];[tv16][18:v]xfade=transition=circlecrop:duration=0.5:offset=174.796[tv17];[ta16][18:a]acrossfade=d=0.5[ta17];[tv17][19:v]xfade=transition=circlecrop:duration=0.5:offset=186.724[tv18];[ta17][19:a]acrossfade=d=0.5[ta18];[tv18][20:v]xfade=transition=circlecrop:duration=0.5:offset=191.23[tv19];[ta18][20:a]acrossfade=d=0.5[ta19];[tv19][21:v]xfade=transition=circlecrop:duration=0.5:offset=195.778[tv20];[ta19][21:a]acrossfade=d=0.5[ta20];[tv20][22:v]xfade=transition=circlecrop:duration=0.5:offset=198.118[tv21];[ta20][22:a]acrossfade=d=0.5[ta21];[tv21][23:v]xfade=transition=circlecrop:duration=0.5:offset=201.506[tv22];[ta21][23:a]acrossfade=d=0.5[ta22];[tv22][24:v]xfade=transition=circlecrop:duration=0.5:offset=204.422[tv23];[ta22][24:a]acrossfade=d=0.5[ta23];[tv23][25:v]xfade=transition=circlecrop:duration=0.5:offset=210.243[tv24];[ta23][25:a]acrossfade=d=0.5[ta24];[tv24][26:v]xfade=transition=circlecrop:duration=0.5:offset=215.417[tv25];[ta24][26:a]acrossfade=d=0.5[ta25];[tv25][27:v]xfade=transition=circlecrop:duration=0.5:offset=219.057[tv26];[ta25][27:a]acrossfade=d=0.5[ta26];[tv26][28:v]xfade=transition=circlecrop:duration=0.5:offset=221.277[tv27];[ta26][28:a]acrossfade=d=0.5[ta27];[tv27][29:v]xfade=transition=circlecrop:duration=0.5:offset=224.875[tv28];[ta27][29:a]acrossfade=d=0.5[ta28];[tv28][ta28][30:v][30:a][31:v][31:a][32:v][32:a][33:v][33:a][34:v][34:a][35:v][35:a][36:v][36:a][37:v][37:a][38:v][38:a][39:v][39:a][40:v][40:a][41:v][41:a][42:v][42:a][43:v][43:a][44:v][44:a][45:v][45:a][46:v][46:a][47:v][47:a][48:v][48:a][49:v][49:a]concat=n=21:v=1:a=1[v][a]" -map "[v]" -map "[a]" /tmp/export-clip-94989d271066ace00459-9ba57089-d833-4cef-beb7-3c847e9958af.mp4



The error is as follows :


ffmpeg version 7.1 Copyright (c) 2000-2024 the FFmpeg developers\n built with gcc 13 (Ubuntu 13.2.0-23ubuntu4)\n configuration: --disable-debug --disable-doc --disable-ffplay --enable-alsa --enable-cuda-llvm --enable-cuvid --enable-ffprobe --enable-gpl --enable-libaom --enable-libass --enable-libdav1d --enable-libfdk_aac --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libharfbuzz --enable-libkvazaar --enable-liblc3 --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-libplacebo --enable-librav1e --enable-librist --enable-libshaderc --enable-libsrt --enable-libsvtav1 --enable-libtheora --enable-libv4l2 --enable-libvidstab --enable-libvmaf --enable-libvorbis --enable-libvpl --enable-libvpx --enable-libvvenc --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzimg --enable-libzmq --enable-nonfree --enable-nvdec --enable-nvenc --enable-opencl --enable-openssl --enable-stripping --enable-vaapi --enable-vdpau --enable-version3 --enable-vulkan\n libavutil 59. 39.100 / 59. 39.100\n libavcodec 61. 19.100 / 61. 19.100\n libavformat 61. 7.100 / 61. 7.100\n libavdevice 61. 3.100 / 61. 3.100\n libavfilter 10. 4.100 / 10. 4.100\n libswscale 8. 3.100 / 8. 3.100\n libswresample 5. 3.100 / 5. 3.100\n libpostproc 58. 3.100 / 58. 3.100\n[mov,mp4,m4a,3gp,3g2,mj2 @ 0x56102f0e5580] moov atom not found\n[in#0 @ 0x56102f0ed480] Error opening input: Invalid data found when processing input\nError opening input file /tmp/0.mp4.\nError opening input files: Invalid data found when processing input\n



It stated that /tmp/0.mp4 has invalid data
moov atom not found


This only occurs when the number of clips > 20


Additional info :


- 

- I can run without any error in my local environment using Windows 11 (FFMPEG version N-114902-g277f051ff6-20240421)
- It fails on AWS Fargate environment using Ubuntu base image docker (FFMPEG version 7.1)






I hope I can get a solutive answer based on my case at least I get what is wrong with my approach


-
ffmpeg fialing with "could not find coded parameters"
21 octobre 2024, par Angelorunning ffmpeg -i in a C# console app using Process, for certain files, the process gets stuck and runs forever


var oInfo = new ProcessStartInfo("ffmpeg.exe", "-i 176d2819-f1da-44eb-b33b-94eb1448194b.mov");
 oInfo.UseShellExecute = false;
 oInfo.CreateNoWindow = true;
 oInfo.RedirectStandardOutput = true;
 oInfo.RedirectStandardError = true;

 string output = string.Empty;
 StreamReader srOutput = null;

 //run the process
 Process proc = Process.Start(oInfo);
 proc.WaitForExit();
 srOutput = proc.StandardError;
 output = srOutput.ReadToEnd();
 proc.Close();



running from command line


ffmpeg.exe -i 176d2819-f1da-44eb-b33b-94eb1448194b.mov, getting an error as included in the below output


could not find codec parameters for stream 1 (Audio : none (apac / 0x63617061), 48000 Hz, 4 channels, 382 kb/s) : unknown codec
Consider increasing the value for the 'analyzeduration' (0) and 'probesize' (5000000) options
[aist#0:1/none @ 0000029b0e1b0040] Guessed Channel Layout : 4.0
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '176d2819-f1da-44eb-b33b-94eb1448194b.mov'


ffmpeg version N-117538-g9ce63e65d6-20241015 Copyright (c) 2000-2024 the FFmpeg developers
 built with gcc 14.2.0 (crosstool-NG 1.26.0.120_4d36f27)
 configuration: --prefix=/ffbuild/prefix --pkg-config-flags=--static --pkg-config=pkg-config --cross-prefix=x86_64-w64-mingw32- --arch=x86_64 --target-os=mingw32 --enable-gpl --enable-version3 --disable-debug --disable-w32threads --enable-pthreads --enable-iconv --enable-zlib --enable-libfreetype --enable-libfribidi --enable-gmp --enable-libxml2 --enable-lzma --enable-fontconfig --enable-libharfbuzz --enable-libvorbis --enable-opencl --disable-libpulse --enable-libvmaf --disable-libxcb --disable-xlib --enable-amf --enable-libaom --enable-libaribb24 --enable-avisynth --enable-chromaprint --enable-libdav1d --enable-libdavs2 --enable-libdvdread --enable-libdvdnav --disable-libfdk-aac --enable-ffnvcodec --enable-cuda-llvm --enable-frei0r --enable-libgme --enable-libkvazaar --enable-libaribcaption --enable-libass --enable-libbluray --enable-libjxl --enable-libmp3lame --enable-libopus --enable-librist --enable-libssh --enable-libtheora --enable-libvpx --enable-libwebp --enable-libzmq --enable-lv2 --enable-libvpl --enable-openal --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenh264 --enable-libopenjpeg --enable-libopenmpt --enable-librav1e --enable-librubberband --enable-schannel --enable-sdl2 --enable-libsoxr --enable-libsrt --enable-libsvtav1 --enable-libtwolame --enable-libuavs3d --disable-libdrm --enable-vaapi --enable-libvidstab --enable-vulkan --enable-libshaderc --enable-libplacebo --enable-libvvenc --enable-libx264 --enable-libx265 --enable-libxavs2 --enable-libxvid --enable-libzimg --enable-libzvbi --extra-cflags=-DLIBTWOLAME_STATIC --extra-cxxflags= --extra-libs=-lgomp --extra-ldflags=-pthread --extra-ldexeflags= --cc=x86_64-w64-mingw32-gcc --cxx=x86_64-w64-mingw32-g++ --ar=x86_64-w64-mingw32-gcc-ar --ranlib=x86_64-w64-mingw32-gcc-ranlib --nm=x86_64-w64-mingw32-gcc-nm --extra-version=20241015
 libavutil 59. 43.100 / 59. 43.100
 libavcodec 61. 22.100 / 61. 22.100
 libavformat 61. 9.100 / 61. 9.100
 libavdevice 61. 4.100 / 61. 4.100
 libavfilter 10. 6.100 / 10. 6.100
 libswscale 8. 6.100 / 8. 6.100
 libswresample 5. 4.100 / 5. 4.100
 libpostproc 58. 4.100 / 58. 4.100
[mov,mp4,m4a,3gp,3g2,mj2 @ 000001b447c84e40] Could not find codec parameters for stream 1 (Audio: none (apac / 0x63617061), 48000 Hz, 4 channels, 382 kb/s): unknown codec
Consider increasing the value for the 'analyzeduration' (0) and 'probesize' (5000000) options
[aist#0:1/none @ 000001b44a6bf880] Guessed Channel Layout: 4.0
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '176d2819-f1da-44eb-b33b-94eb1448194b.mov':
 Metadata:
 major_brand : qt
 minor_version : 0
 compatible_brands: qt
 creation_time : 2024-10-14T07:34:17.000000Z
 com.apple.quicktime.full-frame-rate-playback-intent: 0
 com.apple.quicktime.make: Apple
 com.apple.quicktime.model: iPhone 16 Pro Max
 com.apple.quicktime.software: 18.0.1
 com.apple.quicktime.creationdate: 2024-10-14T16:18:36+1100
 com.apple.photos.originating.signature: AQMNJRMQrKK7im+Kjhixx6TqQyYm
 Duration: 00:00:32.60, start: 0.000000, bitrate: 15064 kb/s
 Stream #0:0[0x1](und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 130 kb/s (default)
 Metadata:
 creation_time : 2024-10-14T07:34:17.000000Z
 handler_name : Core Media Audio
 vendor_id : [0][0][0][0]
 Stream #0:1[0x2](und): Audio: none (apac / 0x63617061), 48000 Hz, 4.0, 382 kb/s
 Metadata:
 creation_time : 2024-10-14T07:34:17.000000Z
 handler_name : Core Media Audio
 vendor_id : [0][0][0][0]
 Stream #0:2[0x3](und): Video: h264 (High) (avc1 / 0x31637661), yuv420p(tv, bt709, progressive), 1920x1080, 14464 kb/s, 30 fps, 30 tbr, 600 tbn (default)
 Metadata:
 creation_time : 2024-10-14T07:34:17.000000Z
 handler_name : Core Media Video
 vendor_id : [0][0][0][0]
 encoder : H.264
 Stream #0:3[0x4](und): Data: none (mebx / 0x7862656D), 0 kb/s (default)
 Metadata:
 creation_time : 2024-10-14T07:34:17.000000Z
 handler_name : Core Media Metadata
 Stream #0:4[0x5](und): Data: none (mebx / 0x7862656D), 0 kb/s (default)
 Metadata:
 creation_time : 2024-10-14T07:34:17.000000Z
 handler_name : Core Media Metadata
 Stream #0:5[0x6](und): Data: none (mebx / 0x7862656D), 21 kb/s (default)
 Metadata:
 creation_time : 2024-10-14T07:34:17.000000Z
 handler_name : Core Media Metadata
 Stream #0:6[0x7](und): Data: none (mebx / 0x7862656D), 48 kb/s (default)
 Metadata:
 creation_time : 2024-10-14T07:34:17.000000Z
 handler_name : Core Media Metadata
 Stream #0:7[0x8](und): Data: none (mebx / 0x7862656D), 2 kb/s (default)
 Metadata:
 creation_time : 2024-10-14T07:34:17.000000Z
 handler_name : Core Media Metadata
 Stream #0:8[0x9](und): Data: none (mebx / 0x7862656D), 0 kb/s (default)
 Metadata:
 creation_time : 2024-10-14T07:34:17.000000Z
 handler_name : Core Media Metadata



This error does not happen on all files but only on a handful of files.


-
I created a Python code to capture live video using FFmpeg, but the output screen only shows noise
16 octobre 2024, par chun3 hyunThe code below is Python code that made my computer screen video capture in real time via ffmpeg.


When I run the code below, it goes well until a new window named 'Captured Frame' is created. But this 'Captured Frame' window doesn't show the full screen of my computer, and the gray screen is generating a lot of noise.


import cv2
import numpy as np
import subprocess

def frame_capture():
 # Set FFmpeg command (capture desired window or area)
 ffmpeg_command = [
 'ffmpeg',
 '-f', 'gdigrab', # Windows screen capture (using gdigrab)
 '-framerate', '30', # Setting the Frame Speed
 '-i', 'desktop', # What to capture (for example, full screen)
 '-pix_fmt', 'bgr0',
 '-vcodec', 'rawvideo', # Video codec settings
 '-tune', 'zerolatency',
 '-an', # Disable audio
 '-sn', # Disable Caption
 '-f', 'rawvideo', '-'
 ]

 # Running the FFmpeg process
 process = subprocess.Popen(ffmpeg_command, stdout=subprocess.PIPE, bufsize=10**8)

 while True:
 # Read Frame from FFmpeg (Resolution Example: 1920x1080)
 raw_frame = process.stdout.read(1920 * 1080 * 3) # 1920x1080 resolution, BGR format
 if not raw_frame:
 break # Shut down the loop when you can no longer receive frames

 # Converting frame data to a numpy array
 frame = np.frombuffer(raw_frame, np.uint8).reshape((1080, 1920, 3))

 # Add frame processing code here
 # Example: Showing a frame on the screen
 cv2.imshow('Captured Frame', frame)

 # Press the 'q' key to end
 if cv2.waitKey(1) & 0xFF == ord('q'):
 break

 # End of process and release of resources
 process.stdout.close()
 process.wait()
 cv2.destroyAllWindows()
frame_capture()



What could I have done wrong ? When I directly input the FFmpeg command in the Windows command prompt(knows as 'cmd') as shown below to save the video (in .mp4 format), I can see that the screen is output normally in the saved file. It seems that FFmpeg itself is installed correctly, but I don't know what the cause is.


hwnd=132554 -pix_fmt yuv420p -vf "scale=iw-mod(iw\,2):ih-mod(ih\,2)" -draw_mouse 1 -t 10 output.mp4



The handle number written above was the handle of the active Chrome window on my computer.


My ffmpeg version is 2024-10-10-git-0f5592cfc7-full_build-www.gyan.dev My Python version is 3.12.4
My Windows version and build are as specified below.
:Windows 11 Home, 10.0.22631


Capturing the computer screen with FFmpeg. I tried it, but the output screen shows only noise.