【问题标题】:MP4 video in IEIE 中的 MP4 视频
【发布时间】:2014-01-26 06:50:38
【问题描述】:

我有一个带有 mp4 和 ogg 源的 html5 视频标签。除了在 IE 11/10/9/...上之外,它在任何地方都运行良好,但如果我将 .mp4 文件直接打开到 IE 中,它会播放它。 在这里浏览后,我发现的主要建议是指定 mime-type 与

AddType video/ogg  .ogv
AddType video/mp4  .mp4
AddType video/webm .webm

并确保 gzip 未激活。但它仍然无法正常工作。该页面可以找到here

编辑 如答案中所述,这是一个编解码器问题。由于此视频是使用 ffmpeg 生成的,因此这是我更正的命令:

ffmpeg -r 10 -y -i ./path/to/%05d.jpg -vcodec libx264 -preset slow -crf 24 -pix_fmt yuv420p ./path/to/video.mp4

【问题讨论】:

    标签: html internet-explorer video html5-video mp4


    【解决方案1】:

    MP4 中的视频轨道使用了浏览器无法在视频元素中播放的编解码器(MPEG-4 Visual/MPEG-4 Part 2)。我想当您直接在浏览器中输入 URL 时,IE 正在使用 Windows Media Player 或其他一些插件来播放它。其他浏览器可以播放ogg版本。

    您应该使用 h264 编解码器重新编码 MP4。

    mediainfo video.mp4
    General
    Complete name                            : video.mp4
    Format                                   : MPEG-4
    Format profile                           : Base Media
    Codec ID                                 : isom
    File size                                : 27.4 MiB
    Duration                                 : 2mn 25s
    Overall bit rate                         : 1 581 Kbps
    Writing application                      : Lavf52.31.0
    
    Video
    ID                                       : 1
    Format                                   : MPEG-4 Visual
    Format profile                           : Simple@L1
    Format settings, BVOP                    : No
    Format settings, QPel                    : No
    Format settings, GMC                     : No warppoints
    Format settings, Matrix                  : Default (H.263)
    Codec ID                                 : 20
    Duration                                 : 2mn 25s
    Bit rate                                 : 1 580 Kbps
    Width                                    : 256 pixels
    Height                                   : 256 pixels
    Display aspect ratio                     : 1.000
    Frame rate mode                          : Constant
    Frame rate                               : 10.000 fps
    Color space                              : YUV
    Chroma subsampling                       : 4:2:0
    Bit depth                                : 8 bits
    Scan type                                : Progressive
    Compression mode                         : Lossy
    Bits/(Pixel*Frame)                       : 2.412
    Stream size                              : 27.4 MiB (100%)
    Writing library                          : Lavc52.20.1
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2013-05-23
      • 2013-10-29
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多