Recherche avancée

Médias (1)

Mot : - Tags -/iphone

Autres articles (50)

  • Les autorisations surchargées par les plugins

    27 avril 2010, par

    Mediaspip core
    autoriser_auteur_modifier() afin que les visiteurs soient capables de modifier leurs informations sur la page d’auteurs

  • Support audio et vidéo HTML5

    10 avril 2011

    MediaSPIP utilise les balises HTML5 video et audio pour la lecture de documents multimedia en profitant des dernières innovations du W3C supportées par les navigateurs modernes.
    Pour les navigateurs plus anciens, le lecteur flash Flowplayer est utilisé.
    Le lecteur HTML5 utilisé a été spécifiquement créé pour MediaSPIP : il est complètement modifiable graphiquement pour correspondre à un thème choisi.
    Ces technologies permettent de distribuer vidéo et son à la fois sur des ordinateurs conventionnels (...)

  • De l’upload à la vidéo finale [version standalone]

    31 janvier 2010, par

    Le chemin d’un document audio ou vidéo dans SPIPMotion est divisé en trois étapes distinctes.
    Upload et récupération d’informations de la vidéo source
    Dans un premier temps, il est nécessaire de créer un article SPIP et de lui joindre le document vidéo "source".
    Au moment où ce document est joint à l’article, deux actions supplémentaires au comportement normal sont exécutées : La récupération des informations techniques des flux audio et video du fichier ; La génération d’une vignette : extraction d’une (...)

Sur d’autres sites (8710)

  • ffmpeg not converting entire video in java application

    12 décembre 2017, par Urvashi Soni

    My code converts a video into different formats (160p to 2160p). The codec of video with rotate tag 90 needs to be changed. below id the code for the same which works fine for all videos till date.

    log_wfm.debug("Changing the codec video for file [" + orgFileName + "] and name of source file ["
                       + srcFileName + "]");
               String codecFlipCommand = "ffmpeg -i " + orgFileName + " -c:v libx264 -preset ultrafast " + srcFileName;

               log_wfm.info("Executing command to change the codec of video!");
               fp = Runtime.getRuntime().exec(codecFlipCommand);

               inputStream = new BufferedReader(new InputStreamReader(fp.getInputStream()));
               outputStream = new BufferedReader(new InputStreamReader(fp.getErrorStream()));

               StringBuffer output = new StringBuffer();
               String line;
               while ((line = inputStream.readLine()) != null) {
                   output.append(line).append('\n');
               }
               log_wfm.debug("stdInputForCodecChange: " + output);

               output = new StringBuffer();
               while ((line = outputStream.readLine()) != null) {
                   output.append(line).append('\n');
               }
               log_wfm.debug("stdErrorForCodecChange: " + output);

    now have a file of size 1.5Gb. The video does not create the file with changed codec. The file till size 848.5 MB is created and then the program hangs (with no exception or error logs)
    Please suggest some way to finish this codec change process.
    The ffmpeg command converts the video, but via java application, the process hangs
    Logs While converting via commandLine :

    ffmpeg version N-83433-ge87a4a8 Copyright (c) 2000-2017 the FFmpeg developers built with gcc 6.3.1 (GCC) 20161221 (Red Hat 6.3.1-1)
     configuration: --prefix=/root/ffmpeg_build --extra-cflags=-I/root/ffmpeg_build/include --extra-ldflags='-L/root/ffmpeg_build/lib -ldl' --bindir=/root/bin --pkg-config-flags=--static --enable-gpl --enable-nonfree --enable-libfdk_aac --enable-libfreetype --enable-libmp3lame --enable-libopus --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265
     libavutil      55. 46.100 / 55. 46.100
     libavcodec     57. 75.100 / 57. 75.100
     libavformat    57. 66.101 / 57. 66.101
     libavdevice    57.  2.100 / 57.  2.100
     libavfilter     6. 73.100 /  6. 73.100
     libswscale      4.  3.101 /  4.  3.101
     libswresample   2.  4.100 /  2.  4.100
     libpostproc    54.  2.100 / 54.  2.100
    Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '/home/urvashi/test/SachinSagaGameLaunchEvent.mp4':
     Metadata:
       major_brand     : mp42
       minor_version   : 0
       compatible_brands: isommp42
       creation_time   : 2017-12-07T06:26:23.000000Z
       com.android.version: 7.1.1
    Duration: 00:14:16.02, start: 0.000000, bitrate: 14231 kb/s
       Stream #0:0(eng): Video: h264 (High) (avc1 / 0x31637661), yuv420p(tv, bt709), 1920x1080, 13971 kb/s, SAR 1:1 DAR 16:9, 29.94 fps, 29.92 tbr, 90k tbn, 180k tbc (default)
       Metadata:
         rotate          : 90
         creation_time   : 2017-12-07T06:26:23.000000Z
         handler_name    : VideoHandle
       Side data:
         displaymatrix: rotation of -90.00 degrees
       Stream #0:1(eng): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 256 kb/s (default)
       Metadata:
         creation_time   : 2017-12-07T06:26:23.000000Z
         handler_name    : SoundHandle
    [libx264 @ 0x4601a20] using SAR=1/1
    [libx264 @ 0x4601a20] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX FMA3 AVX2 LZCNT BMI2
    [libx264 @ 0x4601a20] profile Constrained Baseline, level 4.0
    [libx264 @ 0x4601a20] 264 - core 148 - H.264/MPEG-4 AVC codec - Copyleft 2003-2017 - http://www.videolan.org/x264.html - options: cabac=0 ref=1 deblock=0:0:0 analyse=0:0 me=dia subme=0 psy=1 psy_rd=1.00:0.00 mixed_ref=0 me_range=16 chroma_me=1 trellis=0 8x8dct=0 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=0 threads=6 lookahead_threads=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=0 weightp=0 keyint=250 keyint_min=25 scenecut=0 intra_refresh=0 rc=crf mbtree=0 crf=23.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=0
    Output #0, mp4, to '/home/urvashi/test/Manual_SachinSagaGameLaunchEvent.mp4':
     Metadata:
       major_brand     : mp42
       minor_version   : 0
       compatible_brands: isommp42
       com.android.version: 7.1.1
       encoder         : Lavf57.66.101
       Stream #0:0(eng): Video: h264 (libx264) ([33][0][0][0] / 0x0021), yuv420p, 1080x1920 [SAR 1:1 DAR 9:16], q=-1--1, 29.92 fps, 11488 tbn, 29.92 tbc (default)
       Metadata:
         handler_name    : VideoHandle
         creation_time   : 2017-12-07T06:26:23.000000Z
         encoder         : Lavc57.75.100 libx264
       Side data:
         cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: -1
       Stream #0:1(eng): Audio: aac (LC) ([64][0][0][0] / 0x0040), 48000 Hz, stereo, fltp, 128 kb/s (default)
       Metadata:
         creation_time   : 2017-12-07T06:26:23.000000Z
         handler_name    : SoundHandle
         encoder         : Lavc57.75.100 aac
    Stream mapping:
     Stream #0:0 -> #0:0 (h264 (native) -> h264 (libx264))
     Stream #0:1 -> #0:1 (aac (native) -> aac (native))
    Press [q] to stop, [?] for help Past duration 0.600212 too large   48193kB time=00:00:27.26 bitrate=14479.2kbits/s speed=2.07x
    Past duration 0.998863 too large
    frame=25611 fps= 55 q=-1.0 Lsize= 1721466kB time=00:14:16.04 bitrate=16473.7kbits/s dup=0 drop=17 speed=1.85x
    video:1707295kB audio:13453kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.041757%
    [libx264 @ 0x4601a20] frame I:103   Avg QP:22.16  size:242916
    [libx264 @ 0x4601a20] frame P:25508 Avg QP:25.17  size: 67557

    Thanks in Advance.

  • OpenCV3.3.1 fails to read a video

    1er janvier 2018, par Kasparov92

    Here is the code I use

    file_name = 'movie.avi'
    cap = cv2.VideoCapture(file_name)

    success, frame = cap.read()

    i = 0

    while success:
       i +=1
       success, frame = cap.read()

    print "Frames successfully read:", i

    And I am getting this error :

    Unable to stop the stream: Inappropriate ioctl for device

    (python:139873): GLib-GObject-CRITICAL **: g_object_set: assertion 'G_IS_OBJECT (object)' failed
       Frames successfully read: 0

    On this particular video, it fails to read ! I tried the same code on other videos and they work fine. I also tried the same piece of code with another laptop (same operating system : Ubuntu 16.04) and it works.

    Is it a codec issue ? if so why other videos could be loaded and read successfully ?

    EDIT 1 :

    I recompiled opencv using -DWITH_LIBV4L=ON after sudo apt-get install libv4l-dev and Now I am getting this error :

    Failed to query video capabilities: Inappropriate ioctl for device
    libv4l2: error getting capabilities: Inappropriate ioctl for device
    VIDEOIO ERROR: V4L: device /root/datasets/UCF-101/TableTennisShot/v_TableTennisShot_g22_c02.avi: Unable to query number of channels

    (python:173084): GLib-GObject-CRITICAL **: g_object_set: assertion 'G_IS_OBJECT (object)' failed
  • How can I retain 2x pixel density when encoding Retina screen capture with ffmpeg ?

    26 février 2018, par hfossli

    Whenever I use ffmpeg to encode a HiDPI/Retina screen recording, the video plays at 2x the size, so it looks fuzzy, because the pixel density is not retained.

    How can I retain the original pixel density of HiDPI screen recordings with ffmpeg ?

    How to reproduce :

    1. Use QuickTime Player to create a Screen Recording on a Retina Mac.
    2. Play the video you recorded in QuickTime Player using the ⌘1 Actual Size view. Notice that it’s playing 2:1 on your Retina Display, so the video looks sharp. It’s playing in half the space of the actual recorded pixels.
    3. Use ffmpeg to encode the video using a command like this :

      ffmpeg -i haha.mov -c:v libx264 -crf 23 haha-lg.mov
    4. Play the new ffmpeg-compressed video in QuickTime Player using the ⌘1 Actual Size view. Notice that it’s playing 1:1, so the video looks fuzzy.

    To clarify, the video does not look blurry because it was compressed. Rather, it looks blurry because the video is being played twice as big as it should be, at a 1:1 pixel density, instead of the required 2:1 pixel density, presumably because some metadata is being discarded when encoding.

    For the record, VLC plays both videos too big (blurry). So being able to play HiDPI videos seems to be a feature of QuickTime Player.

    Here is the detailed information ffmpeg shows for the original screen recording :

    Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'haha.mov':
     Metadata:
       major_brand     : qt  
       minor_version   : 0
       compatible_brands: qt  
       creation_time   : 2018-02-26T16:46:00.000000Z
       com.apple.quicktime.make: Apple
       com.apple.quicktime.model: iMac18,3
       com.apple.quicktime.software: Mac OS X 10.13.3 (17D102)
       com.apple.quicktime.creationdate: 2018-02-26T10:45:50-0600
     Duration: 00:00:04.35, start: 0.000000, bitrate: 10947 kb/s
       Stream #0:0(und): Video: h264 (Main) (avc1 / 0x31637661), yuv420p(tv, bt709), 1396x928 [SAR 1:1 DAR 349:232], 10701 kb/s, 60 fps, 60 tbr, 6k tbn, 12k tbc (default)
       Metadata:
         creation_time   : 2018-02-26T16:46:00.000000Z
         handler_name    : Core Media Data Handler
         encoder         : H.264

    And here is the information for the ffmpeg-compressed version :

    Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'haha-lg.mov':
     Metadata:
       major_brand     : qt  
       minor_version   : 512
       compatible_brands: qt  
       encoder         : Lavf57.83.100
     Duration: 00:00:04.35, start: 0.000000, bitrate: 1923 kb/s
       Stream #0:0(eng): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 1396x928 [SAR 1:1 DAR 349:232], 1783 kb/s, 60 fps, 60 tbr, 15360 tbn, 120 tbc (default)
       Metadata:
         handler_name    : DataHandler
         encoder         : Lavc57.107.100 libx264