Recherche avancée

Médias (0)

Mot : - Tags -/diogene

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

Autres articles (97)

  • MediaSPIP 0.1 Beta version

    25 avril 2011, par

    MediaSPIP 0.1 beta is the first version of MediaSPIP proclaimed as "usable".
    The zip file provided here only contains the sources of MediaSPIP in its standalone version.
    To get a working installation, you must manually install all-software dependencies on the server.
    If you want to use this archive for an installation in "farm mode", you will also need to proceed to other manual (...)

  • HTML5 audio and video support

    13 avril 2011, par

    MediaSPIP uses HTML5 video and audio tags to play multimedia files, taking advantage of the latest W3C innovations supported by modern browsers.
    The MediaSPIP player used has been created specifically for MediaSPIP and can be easily adapted to fit in with a specific theme.
    For older browsers the Flowplayer flash fallback is used.
    MediaSPIP allows for media playback on major mobile platforms with the above (...)

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

  • How to record video from old webcam using ffmpeg on Linux ?

    5 février 2015, par Moomin

    After couple of hours I finally accepted my absolute lack of knowledge and decided to post this question here.
    I’m trying to record video from an old external USB webcam (Media-Tech MT400 -> 0c45:6029) with ffmpeg but without much success.

    First thing I’ve tried was to run to try something that works for the built-in webcam) :

    ffmpeg -f v4l2 -i /dev/video1 test.avi

    But that returned a following error :

    Cannot find a proper format for codec 'none' (id 0), pixel format 'none' (id -1)

    Here is what I get from v4l2-ctl -d /dev/video1/ --all --list-formats-ext

    Driver Info (not using libv4l2):
           Driver name   : sonixb
           Card type     : USB camera
           Bus info      : usb-0000:04:00.0-1
           Driver version: 3.10.17
           Capabilities  : 0x85000001
                   Video Capture
                   Read/Write
                   Streaming
                   Device Capabilities
           Device Caps   : 0x05000001
                   Video Capture
                   Read/Write
                   Streaming
    Priority: 2
    Video input : 0 (sonixb: ok)
    Format Video Capture:
           Width/Height  : 352/288
           Pixel Format  : 'S910'
           Field         : None
           Bytes per Line: 352
           Size Image    : 126720
           Colorspace    : SRGB
    Streaming Parameters Video Capture:
           Frames per second: invalid (0/0)
           Read buffers     : 2



    ioctl: VIDIOC_ENUM_FMT
       Index       : 0
       Type        : Video Capture
       Pixel Format: 'S910'
       Name        : S910
               Size: Discrete 160x120
               Size: Discrete 176x144
               Size: Discrete 320x240
               Size: Discrete 352x288

       Index       : 1
       Type        : Video Capture
       Pixel Format: 'BA81'
       Name        : BA81
               Size: Discrete 160x120
               Size: Discrete 176x144

    Unfortunately that was not of much help to me, but I tried capturing webcam output with VLC and recording it which.... WORKED !

    I tried ffmpeg -i vlc-record[...].avi on VLC recording which returned following information :

    Input #0, avi, from 'vlc-record-2015-02-05-05h22m52s-v4l2____dev_video1-.avi':
     Duration: 00:00:01.58, start: 0.000000, bitrate: 26937 kb/s
       Stream #0:0: Video: rawvideo (I420 / 0x30323449), yuv420p, 352x288, 27671 kb/s, 22.10 tbr, 22.10 tbn, 22.10 tbc

    I thought that was enough information (rawvideo and yuv420p) led to run ffmpeg with following arguments (I have found yuv4 using ffmpeg -formats)

    ffmpeg -f rawvideo -vcodec yuv4 -i /dev/video1 test.avi

    The result was only slightly better than one that I saw after my first attempt :

    [IMGUTILS @ 0x7fff497d3920] Picture size 0x0 is invalid
    [rawvideo @ 0x9c4720] Could not find codec parameters for stream 0 (Video: yuv4, yuv420p, -4 kb/s): unspecified size
    Consider increasing the value for the 'analyzeduration' and 'probesize' options
    /dev/video1: could not find codec parameters

    Again after some searching and several tries I added ’-video_size cif` option and.... it WORKED !!!!

    Well, not really...

    Input #0, rawvideo, from '/dev/video1':
     Duration: N/A, start: 0.000000, bitrate: 30412 kb/s
       Stream #0:0: Video: yuv4, yuv420p, 352x288, 30412 kb/s, 25 tbr, 25 tbn, 25 tbc
    Output #0, avi, to 'test.avi':
     Metadata:
       ISFT            : Lavf55.19.104
       Stream #0:0: Video: mpeg4 (FMP4 / 0x34504D46), yuv420p, 352x288, q=2-31, 200 kb/s, 25 tbn, 25 tbc
    Stream mapping:
     Stream #0:0 -> #0:0 (yuv4 -> mpeg4)
    Press [q] to stop, [?] for help
    frame=   13 fps=6.3 q=24.8 Lsize=    1064kB time=00:00:00.52 bitrate=16759.3kbits/s    
    video:1058kB audio:0kB subtitle:0 global headers:0kB muxing overhead 0.554114%

    LED on webcam turned on as during capturing video with VLC but all that was recorded was TV-like noise.

    So here I am after 7 hours - still without work solution - asking for your help.

    Thanks in advance.

  • Unknown V4L2 pixel format equivalent for yuva420p with ffmpeg and v4l2loopback

    7 février 2019, par Kim

    I am trying to use filter_complex from ffmpeg to stich several video input together into one output.

    I use v4l2loopback to create a virtual video device :

    sudo modprobe v4l2loopback video_nr=90

    In this example, i first try with only one camera :

    v4l2-ctl --device=/dev/video0 --info gives the following output :

    Driver Info (not using libv4l2):
           Driver name   : uvcvideo
           Card type     : HD USB Camera
           Bus info      : usb-0000:00:14.0-13.2
           Driver version: 4.10.17
           Capabilities  : 0x84200001
                   Video Capture
                   Streaming
                   Extended Pix Format
                   Device Capabilities
           Device Caps   : 0x04200001
                   Video Capture
                   Streaming
                   Extended Pix Format
    Priority: 2
    Video input : 0 (Camera 1: ok)
    Format Video Capture:
           Width/Height      : 640/480
           Pixel Format      : 'YUYV'
           Field             : None
           Bytes per Line    : 1280
           Size Image        : 614400
           Colorspace        : sRGB
           Transfer Function : Default
           YCbCr Encoding    : Default
           Quantization      : Default
           Flags             :
    Crop Capability Video Capture:
           Bounds      : Left 0, Top 0, Width 640, Height 480
           Default     : Left 0, Top 0, Width 640, Height 480
           Pixel Aspect: 1/1
    Selection: crop_default, Left 0, Top 0, Width 640, Height 480
    Selection: crop_bounds, Left 0, Top 0, Width 640, Height 480
    Streaming Parameters Video Capture:
           Capabilities     : timeperframe
           Frames per second: 30.000 (30/1)
           Read buffers     : 0
                        brightness (int)    : min=0 max=15 step=1 default=8 value=8
                          contrast (int)    : min=0 max=15 step=1 default=8 value=8
                        saturation (int)    : min=0 max=15 step=1 default=7 value=7
                               hue (int)    : min=-10 max=10 step=1 default=0value=0
    white_balance_temperature_auto (bool)   : default=1 value=1
                             gamma (int)    : min=1 max=10 step=1 default=7 value=7
                              gain (int)    : min=0 max=0 step=0 default=0 value=0
              power_line_frequency (menu)   : min=0 max=2 default=2 value=2
         white_balance_temperature (int)    : min=2800 max=6500 step=1 default=2800 value=2800 flags=inactive
                         sharpness (int)    : min=0 max=15 step=1 default=6 value=6
            backlight_compensation (int)    : min=0 max=1 step=1 default=0 value=0
                     exposure_auto (menu)   : min=0 max=3 default=3 value=3
                 exposure_absolute (int)    : min=4 max=5000 step=1 default=625 value=625 flags=inactive
                    focus_absolute (int)    : min=0 max=21 step=1 default=16 value=16 flags=inactive
                        focus_auto (bool)   : default=1 value=1

    Then i use this command to ouput /dev/video0 to /dev/video90 on the left side with a specific resolution :

    ffmpeg -loglevel verbose -y \
     -f v4l2 -thread_queue_size 512 -i /dev/video0 \
     -filter_complex "nullsrc=size=960x240 [base]; \
             [0:v] format=pix_fmts=yuva420p, setpts=PTS-STARTPTS, scale=320x240 [left]; \
             [base][left] overlay=shortest=1" \
     -f v4l2 /dev/video90

    Which results in the following error :

    [v4l2 @ 0x55fa67d02f60] Unknown V4L2 pixel format equivalent for yuva420p
    Could not write header for output file #0 (incorrect codec parameters ?): Invalid argument
    Error initializing output stream 0:0 --
    Conversion failed!

    Full logs :

    ffmpeg version 3.4.4-1~16.04.york0 Copyright (c) 2000-2018 the FFmpeg developers
     built with gcc 5.4.0 (Ubuntu 5.4.0-6ubuntu1~16.04.10) 20160609
     configuration: --prefix=/usr --extra-version='1~16.04.york0' --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --enable-gpl --disable-stripping --enable-avresample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librubberband --enable-librsvg --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzmq --enable-libzvbi --enable-omx --enable-openal --enable-opengl --enable-sdl2 --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libopencv --enable-libx264 --enable-shared
     WARNING: library configuration mismatch
     avcodec     configuration: --prefix=/usr --extra-version='1~16.04.york0'--toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --enable-gpl --disable-stripping --enable-avresample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librubberband --enable-librsvg --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzmq --enable-libzvbi --enable-omx --enable-openal --enable-opengl --enable-sdl2 --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libopencv --enable-libx264 --enable-shared --enable-version3 --disable-doc --disable-programs --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libtesseract --enable-libvo_amrwbenc
     libavutil      55. 78.100 / 55. 78.100
     libavcodec     57.107.100 / 57.107.100
     libavformat    57. 83.100 / 57. 83.100
     libavdevice    57. 10.100 / 57. 10.100
     libavfilter     6.107.100 /  6.107.100
     libavresample   3.  7.  0 /  3.  7.  0
     libswscale      4.  8.100 /  4.  8.100
     libswresample   2.  9.100 /  2.  9.100
     libpostproc    54.  7.100 / 54.  7.100
    [video4linux2,v4l2 @ 0x55fa67cfca00] fd:5 capabilities:84200001
    [video4linux2,v4l2 @ 0x55fa67cfca00] Querying the device for the current frame size
    [video4linux2,v4l2 @ 0x55fa67cfca00] Setting frame size to 640x480
    Input #0, video4linux2,v4l2, from '/dev/video0':
     Duration: N/A, start: 273229.829138, bitrate: 147456 kb/s
       Stream #0:0: Video: rawvideo, 1 reference frame (YUY2 / 0x32595559), yuyv422, 640x480, 147456 kb/s, 30 fps, 30 tbr, 1000k tbn, 1000k tbc
    [Parsed_nullsrc_0 @ 0x55fa67d00680] size:960x240 rate:25/1 duration:-1.000000 sar:1/1
    [Parsed_scale_3 @ 0x55fa67d02240] w:320 h:240 flags:'bilinear' interl:0
    Stream mapping:
     Stream #0:0 (rawvideo) -> format
     overlay -> Stream #0:0 (rawvideo)
    Press [q] to stop, [?] for help
    [Parsed_nullsrc_0 @ 0x55fa67cfc760] size:960x240 rate:25/1 duration:-1.000000 sar:1/1
    [Parsed_scale_3 @ 0x55fa67d055c0] w:320 h:240 flags:'bilinear' interl:0
    [graph 0 input from stream 0:0 @ 0x55fa67d06a40] w:640 h:480 pixfmt:yuyv422 tb:1/1000000 fr:30/1 sar:0/1 sws_param:flags=2
    [auto_scaler_0 @ 0x55fa67d05d80] w:iw h:ih flags:'bilinear' interl:0
    [Parsed_format_1 @ 0x55fa67d04360] auto-inserting filter 'auto_scaler_0' between the filter 'graph 0 input from stream 0:0' and the filter 'Parsed_format_1'
    [auto_scaler_0 @ 0x55fa67d05d80] w:640 h:480 fmt:yuyv422 sar:0/1 -> w:640 h:480 fmt:yuva420p sar:0/1 flags:0x2
    [Parsed_format_1 @ 0x55fa67d04360] TB:0.000001 FRAME_RATE:30.000000 SAMPLE_RATE:nan
    [Parsed_scale_3 @ 0x55fa67d055c0] w:640 h:480 fmt:yuva420p sar:0/1 -> w:320 h:240 fmt:yuva420p sar:0/1 flags:0x2
    [Parsed_overlay_4 @ 0x55fa67d05e80] main w:960 h:240 fmt:yuva420p overlay w:320 h:240 fmt:yuva420p
    [Parsed_overlay_4 @ 0x55fa67d05e80] [framesync @ 0x55fa67d05fa8] Selected 1/1000000 time base
    [Parsed_overlay_4 @ 0x55fa67d05e80] [framesync @ 0x55fa67d05fa8] Sync level 2
    [v4l2 @ 0x55fa67d02f60] Unknown V4L2 pixel format equivalent for yuva420p
    Could not write header for output file #0 (incorrect codec parameters ?): Invalid argument
    Error initializing output stream 0:0 --
    Conversion failed!

    What I tried and didn’t work :

    • use -f h264 for the output, which ends in a av_interleaved_write_frame(): Invalid argument error
  • Headless Selenium not Recording Video

    12 mai 2015, par TIMBERings

    I’m using the Headless gem to create a headless session using xvfb and to record the session using ffmpeg. I’m not able to save the video created by the headless gem. I’m including the relevant snippets of my code and the output.

    Code

    $LOGGER.info("----------Starting test: #{@test_name}----------")

    if Utilities.linux? && ENV['DRIVER'] != 'sauce'
     @headless = Headless.new ({dimension: '1600x1200x16',
                       pid_file_path: "#{Utilities.get_root_directory}/tmp/headless_ffmpeg_#{@display}.pid",
                       tmp_file_path: "#{Utilities.get_root_directory}/tmp/headless_ffmpeg_#{@display}.mov",
                       log_file_path: "#{Utilities.get_root_directory}/tmp/headless_ffmpeg_#{@display}.txt"})
     @headless.start
     @headless.video.start_capture
     $LOGGER.info 'Creating headless session.'
    end
    $browser = DefaultWatir.initiate_browser(@test_name)

    if Utilities.linux? && ENV['DRIVER'] != 'sauce'
     $LOGGER.info "Starting video recording"
     @headless.video.start_capture
    end

    .........          .........
    ......... TEST RUN .........
    .........          .........

    $LOGGER.info "----------Ending test: #{@test_name}----------"
    puts "\n\n"

    $browser.close if $browser
    save_video if @headless

    def video_path
     return "#{Utilities.get_root_directory}/video/#{@test_name}_#{Time.now.to_s.gsub(' ', '-')}"
    end

    def save_video
     if Utilities.linux?  && ENV['DRIVER'] != 'sauce'
       unless self.instance_variable_get(:@exception).nil? && !$has_errors
         saved_video_path = video_path
         Dir.mkdir("#{Utilities.get_root_directory}/video") unless Dir.exists?("#{Utilities.get_root_directory}/video")
         $LOGGER.info "Video path = #{saved_video_path}"
         begin
           $LOGGER.info 'before save'
           @headless.video.stop_and_save(saved_video_path)
           $LOGGER.info 'after save'
         rescue ex
           $LOGGER.info 'Video save had exception.'
           puts ex.message
           puts ex.backtrace.join("\n\t")
         end
         $LOGGER.info "Video saved at: #{saved_video_path}"
       else
         @headless.video.stop_and_discard
       end
       @headless.destroy
     end
    end

    Output

    [INFO - 2015-03-06 21:58:37 +0000] - ----------Starting test : Example Test----------

    [INFO - 2015-03-06 21:58:37 +0000] - Creating headless session.

    [INFO - 2015-03-06 21:58:40 +0000] - Starting video recording

    [INFO - 2015-03-06 22:02:04 +0000] - ----------Ending test : Example Test----------

    INFO - 2015-03-06 22:02:05 +0000] - Video path = /var/lib/jenkins/workspace/end_to_end_firefox/selenium-tests/video/PoolPlayToSingleEliminationOneDivision_2015-03-06-22:02:05-+0000

    [INFO - 2015-03-06 22:02:05 +0000] - before save

    [INFO - 2015-03-06 22:02:05 +0000] - after save

    [INFO - 2015-03-06 22:02:05 +0000] - Video saved at : /var/lib/jenkins/workspace/end_to_end_firefox/selenium-tests/video/PoolPlayToSingleEliminationOneDivision_2015-03-06-22:02:05-+0000