mp4视频旋转元数据删除

时间:2019-03-05 19:18:54

标签: video ffmpeg rotation metadata

使用ffmpeg删除旋转元数据是可行的,但是由于元数据:旋转:输出90仍然出现在输出部分,因此输出有些混乱。

ffmpeg version N-92663-g8affd75

似乎要保持旋转元数据:

Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'vid_20190302_162804987.mp4':
  Metadata:
    major_brand     : mp42
    minor_version   : 0
    compatible_brands: isommp42
    creation_time   : 2019-03-02T15:28:43.000000Z
    com.android.version: 6.0.1
  Duration: 00:00:32.40, start: 0.000000, bitrate: 17230 kb/s
    Stream #0:0(eng): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 1920x1080, 17003 kb/s, SAR 1:1 DAR 16:9, 28.98 fps, 29.33 tbr, 90k tbn, 180k tbc (default)
    Metadata:
      rotate          : 90
      creation_time   : 2019-03-02T15:28:43.000000Z
      handler_name    : VideoHandle
      encoder         : MOTO
    Side data:
      displaymatrix: rotation of -90.00 degrees
    Stream #0:1(eng): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 128 kb/s (default)
    Metadata:
      creation_time   : 2019-03-02T15:28:43.000000Z
      handler_name    : SoundHandle
Output #0, mp4, to '1.mp4':
  Metadata:
    major_brand     : mp42
    minor_version   : 0
    compatible_brands: isommp42
    com.android.version: 6.0.1
    encoder         : Lavf58.24.100
    Stream #0:0(eng): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 1920x1080 [SAR 1:1 DAR 16:9], q=2-31, 17003 kb/s, 28.98 fps, 29.33 tbr, 90k tbn, 90k tbc (default)
    Metadata:
      rotate          : 90
      creation_time   : 2019-03-02T15:28:43.000000Z
      handler_name    : VideoHandle
      encoder         : MOTO
    Side data:
      displaymatrix: rotation of -0.00 degrees
    Stream #0:1(eng): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 128 kb/s (default)
    Metadata:
      creation_time   : 2019-03-02T15:28:43.000000Z
      handler_name    : SoundHandle

但是幸运的是,在后续的ffmpeg(或ffprobe)中缺少旋转功能

0 个答案:

没有答案