Recherche avancée

Médias (1)

Mot : - Tags -/copyleft

Autres articles (110)

  • Organiser par catégorie

    17 mai 2013, par

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

  • Récupération d’informations sur le site maître à l’installation d’une instance

    26 novembre 2010, par

    Utilité
    Sur le site principal, une instance de mutualisation est définie par plusieurs choses : Les données dans la table spip_mutus ; Son logo ; Son auteur principal (id_admin dans la table spip_mutus correspondant à un id_auteur de la table spip_auteurs)qui sera le seul à pouvoir créer définitivement l’instance de mutualisation ;
    Il peut donc être tout à fait judicieux de vouloir récupérer certaines de ces informations afin de compléter l’installation d’une instance pour, par exemple : récupérer le (...)

  • Qu’est ce qu’un éditorial

    21 juin 2013, par

    Ecrivez votre de point de vue dans un article. Celui-ci sera rangé dans une rubrique prévue à cet effet.
    Un éditorial est un article de type texte uniquement. Il a pour objectif de ranger les points de vue dans une rubrique dédiée. Un seul éditorial est placé à la une en page d’accueil. Pour consulter les précédents, consultez la rubrique dédiée.
    Vous pouvez personnaliser le formulaire de création d’un éditorial.
    Formulaire de création d’un éditorial Dans le cas d’un document de type éditorial, les (...)

Sur d’autres sites (7846)

  • OpenCV ffmpeg issues when running Windows 10 app on Windows 7

    1er novembre 2016, par David G.

    I need to maintain a desktop app written in C++, using Qt and OpenCV for some video processing. As far as I understood, the decoding part of OpenCV is delegated to ffmpeg in a separate DLL for licensing reasons.

    The development environment is on Windows 10, using QT Creator and MSVC12 64-bit as compiler. OpenCV version is 3.0, the official distribution. Here, everything runs fine, I am able to decode a video using VideoCapture::open().

    Issues arise when I try to run the application in a standalone fashion with all the required DLLs in the same folder as the .exe file. All cases below are 64-bit OSes.

    On a Windows 10 computer, not the same as the developement machine and no developer libraries present, the video decoding works fine. I have tested on a Windows 8 machine as well, no issues so far.

    On Windows 7, the things get tricky. The same video files that successfully load during the previous tests are not recognized by the app at all i.e. the isOpened call on VideoCapture returns false. For further testing, I stripped the opencv_ffmpeg300_64.dll file to narrow down the issue on Windows 10 and 8 ; as expected, without this DLL the app is no more able to open the same video files.

    It seems that the DLL is simply not recognized on Windows 7.

    • Did you encounter this type of issue and, maybe, have part of a solution ?
    • I would like to monitor which DLLs are loaded as the program runs and see possible "DLL not found" errors. Is it possible, especially on a machine that does not have the entire developement environment ?
    • Can building OpenCV on my own address the issue ?
    • Even further, would it be worth to port the development environment on Windows 7 and build from there ? This requires significant work due to the project itself.
  • ffmpeg error in subprocess.run but works in terminal

    6 juin 2023, par 8TM

    I'm creating my own MKV videos and I found a strange bug when I'm using subprocess module from python 3.11.2 to execute FFmpeg command.

    


    My FFmpeg command is running fine in terminal (ends with success) :

    


    ffmpeg -y \
-i input_video_stream.mkv \
-i input_audio_stream_1.ac3 \
-i input_audio_stream_2.ac3 \
-i input_audio_stream_3.ac3 \
-i input_audio_stream_4.ac3 \
-f srt -i input_subtitle_stream_1.srt \
-f srt -i input_subtitle_stream_2.srt \
-map 0 -map 1 -map 2 -map 3 -map 4 -map 5 -map 6 \
-c copy \
-metadata:s:a:0 language=eng -metadata:s:a:0 title="English1" \
-metadata:s:a:1 language=eng -metadata:s:a:1 title="English2" \
-metadata:s:a:2 language=eng -metadata:s:a:2 title="English3" \
-metadata:s:a:3 language=eng -metadata:s:a:3 title="English4" \
-metadata:s:s:0 language=eng -metadata:s:s:0 title="English1" -metadata:s:s:0 mimetype=application/x-ass \
-metadata:s:s:1 language=eng -metadata:s:s:1 title="English2" -metadata:s:s:1 mimetype=application/x-ass \
-disposition:a:0 default -disposition:s:s:0 default \
output_video_with_audio_and_subtitles.mkv


    


    But when I'm running it by in the same terminal (the same session and the same ffmpeg version) by python from subprocess.run(command) :

    


    subprocess.run([
    'ffmpeg', '-y',
    '-i', 'input_video_stream.mkv',
    '-i', 'input_audio_stream_1.ac3',
    '-i', 'input_audio_stream_2.ac3',
    '-i', 'input_audio_stream_3.ac3',
    '-i', 'input_audio_stream_4.ac3',
    '-f', 'srt', '-i', 'input_subtitle_stream_1.srt',
    '-f', 'srt', '-i', 'input_subtitle_stream_2.srt',
    '-map', '0', '-map', '1', '-map', '2', '-map', '3', '-map', '4', '-map', '5', '-map', '6',
    '-c', 'copy',
    '-metadata:s:a:0', 'language=eng', '-metadata:s:a:0', 'title="English1"', 
    '-metadata:s:a:1', 'language=eng', '-metadata:s:a:1', 'title="English2"', 
    '-metadata:s:a:2', 'language=eng', '-metadata:s:a:2', 'title="English3"', 
    '-metadata:s:a:3', 'language=eng', '-metadata:s:a:3', 'title="English4"', 
    '-metadata:s:s:0', 'language=eng', '-metadata:s:s:0', 'title="English1"', 
    '-metadata:s:s:0', 'mimetype=application/x-ass',
    '-metadata:s:s:1', 'language=eng', '-metadata:s:s:1', 'title="English2"', '-metadata:s:s:1', 'mimetype=application/x-ass', 
    '-disposition:a:0 default', '-disposition:s:s:0 default', 
    'output_video_with_audio_and_subtitles.mkv'
])



    


    it fails :

    


    
ffmpeg version 5.1.2-3 Copyright (c) 2000-2022 the FFmpeg developers
  built with gcc 12 (Debian 12.2.0-14)
  configuration : —prefix=/usr —extra-version=3 —toolchain=hardened —libdir=/usr/lib/x86_64-linux-gnu —incdir=/usr/include/x86_64-linux-gnu —arch=amd64 —enable-gpl —disable-stripping —enable-gnutls —enable-ladspa —enable-libaom —enable-libass —enable-libbluray —enable-libbs2b —enable-libcaca —enable-libcdio —enable-libcodec2 —enable-libdav1d —enable-libflite —enable-libfontconfig —enable-libfreetype —enable-libfribidi —enable-libglslang —enable-libgme —enable-libgsm —enable-libjack —enable-libmp3lame —enable-libmysofa —enable-libopenjpeg —enable-libopenmpt —enable-libopus —enable-libpulse —enable-librabbitmq —enable-librist —enable-librubberband —enable-libshine —enable-libsnappy —enable-libsoxr —enable-libspeex —enable-libsrt —enable-libssh —enable-libsvtav1 —enable-libtheora —enable-libtwolame —enable-libvidstab —enable-libvorbis —enable-libvpx —enable-libwebp —enable-libx265 —enable-libxml2 —enable-libxvid —enable-libzimg —enable-libzmq —enable-libzvbi —enable-lv2 —enable-omx —enable-openal —enable-opencl —enable-opengl —enable-sdl2 —disable-sndio —enable-libjxl —enable-pocketsphinx —enable-librsvg —enable-libmfx —enable-libdc1394 —enable-libdrm —enable-libiec61883 —enable-chromaprint —enable-frei0r —enable-libx264 —enable-libplacebo —enable-librav1e —enable-shared
  libavutil      57. 28.100 / 57. 28.100
  libavcodec     59. 37.100 / 59. 37.100
  libavformat    59. 27.100 / 59. 27.100
  libavdevice    59.  7.100 / 59.  7.100
  libavfilter     8. 44.100 /  8. 44.100
  libswscale      6.  7.100 /  6.  7.100
  libswresample   4.  7.100 /  4.  7.100
  libpostproc    56.  6.100 / 56.  6.100
Input #0, matroska,webm, from 'input_video_stream.mkv' :
  Metadata :
    ENCODER : Lavf59.27.100
  Duration : 00:44:19.94, start : 0.000000, bitrate : 22551 kb/s
  Stream #0:0 : Video : h264 (High), yuv420p(tv, bt709, progressive), 1920x1080 [SAR 1:1 DAR 16:9], 23.98 fps, 23.98 tbr, 1k tbn (default)
    Metadata :
      BPS : 22549589
      NUMBER_OF_FRAMES : 63631
      NUMBER_OF_BYTES : 7480665638
      _STATISTICS_WRITING_APP : mkvmerge v56.0.0 ('Strasbourg / St. Denis') 64-bit
      _STATISTICS_WRITING_DATE_UTC : 2023-05-15 08:21:43
      _STATISTICS_TAGS : BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
      DURATION : 00:44:19.942000000
[ac3 @ 0x55b374ee9e80] Estimating duration from bitrate, this may be inaccurate
Input #1, ac3, from 'input_audio_stream_1.ac3' :
  Duration : 00:44:19.89, start : 0.000000, bitrate : 448 kb/s
  Stream #1:0 : Audio : ac3, 48000 Hz, 5.1(side), fltp, 448 kb/s
[ac3 @ 0x55b37502ef80] Estimating duration from bitrate, this may be inaccurate
Input #2, ac3, from 'input_audio_stream_2.ac3' :
  Duration : 00:44:19.89, start : 0.000000, bitrate : 192 kb/s
  Stream #2:0 : Audio : ac3, 48000 Hz, stereo, fltp, 192 kb/s
[ac3 @ 0x55b374efc900] Estimating duration from bitrate, this may be inaccurate
Input #3, ac3, from 'input_audio_stream_3.ac3' :
  Duration : 00:43:19.18, start : 0.000000, bitrate : 384 kb/s
  Stream #3:0 : Audio : ac3, 48000 Hz, stereo, fltp, 384 kb/s
[ac3 @ 0x55b374fd60c0] Estimating duration from bitrate, this may be inaccurate
Input #4, ac3, from 'input_audio_stream_4.ac3' :
  Duration : 00:43:19.18, start : 0.000000, bitrate : 192 kb/s
  Stream #4:0 : Audio : ac3, 48000 Hz, stereo, fltp, 192 kb/s
Input #5, srt, from 'input_subtitle_stream_1.srt' :
  Duration : N/A, bitrate : N/A
  Stream #5:0 : Subtitle : subrip
Input #6, srt, from 'input_subtitle_stream_2.srt' :
  Duration : N/A, bitrate : N/A
  Stream #6:0 : Subtitle : subrip
[matroska @ 0x55b3751a1940] Invalid stream specifier : a:0 default.
    Last message repeated 1 times


    


    I know it's reporting something with audio ([matroska @ 0x55b3751a1940] Invalid stream specifier : a:0 default. Last message repeated 1 times) but it's probably problem with my ffmpeg command.

    


  • Enable Subtitle on FFmpeg Stream

    14 janvier 2020, par A Person

    I am trying to enable subtitle on my streams.

    The problem is that I do not have a subtitle track.

    The original IP stream that is coming has subtitles and I need to know how to enable it.

    I have looked at Set a subtitle language using ffmpeg

    and also read that I need to assign some sort of PID to the FFmpeg tag to enable it. However, I have been googling this and cannot seem to dins it.

    My code is :

    /c ffmpeg -hwaccel cuvid -y -i {udp} -vf "drawtext=fontfile={font}: fontsize=25:text='{ChannelName} %{localtime}': x=10: y=10: fontcolor=white: box=1: boxcolor=0x000000" -pix_fmt yuv420p -vsync 1 -crf 10 -c:v h264_nvenc -r 25 -threads 0  -b:v 1M -profile:v main -minrate 1M -maxrate 1M -bufsize 10M -sc_threshold 0 -c:a aac -b:a 128k -ac 2 -ar 44100 -af "aresample=async=1:min_hard_comp=0.100000:first_pts=0" -bsf:v h264_mp4toannexb -t 00:31:00 {output}\{ChannelName}_{year}_{monthno}_{day}__{Hours}_{Minutes}_{Seconds}.mp4 {FFLog}

    These are the variables :

    {udp} this is the UDP link e.g udp ://239...*:1234

    {font} this just points to the font file

    {ChannelName} holds the name of the stream

    {localtime} current time

    {FLOG} path to a log file to dumb the data