Skip to content

I was looking to upgrade ffmpeg to version 8.0, but I found that it couldn't retrieve the rotation parameters for videos shot with a mobile phone. This issue persists even after upgrading to version 8.1.1. #152

Description

@soulcure

In ffmpeg 8.0.0, the rotation parameters (side_data_list) for videos shot by a mobile phone cannot be retrieved, while in ffmpeg 8.1.1, the rotation parameters (side_data_list) can be retrieved correctly.

➜ ~ ffprobe -v error -hide_banner -select_streams v:0 -show_streams -print_format json -i /Users/xxx/Desktop/input.mp4
{
"streams": [
{
"index": 1,
"codec_name": "h264",
"codec_long_name": "H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10",
"profile": "High",
"codec_type": "video",
"codec_tag_string": "avc1",
"codec_tag": "0x31637661",
"mime_codec_string": "avc1.640034",
"width": 3840,
"height": 2160,
"coded_width": 3840,
"coded_height": 2160,
"has_b_frames": 0,
"pix_fmt": "yuv420p",
"level": 52,
"color_range": "tv",
"color_space": "bt709",
"color_transfer": "bt709",
"color_primaries": "bt709",
"chroma_location": "left",
"field_order": "progressive",
"is_avc": "true",
"nal_length_size": "4",
"id": "0x2",
"r_frame_rate": "60/1",
"avg_frame_rate": "678000/11329",
"time_base": "1/90000",
"start_pts": 0,
"start_time": "0.000000",
"duration_ts": 509805,
"duration": "5.664500",
"bit_rate": "62387864",
"bits_per_raw_sample": "8",
"nb_frames": "339",
"extradata_size": 35,
"disposition": {
"default": 1,
"dub": 0,
"original": 0,
"comment": 0,
"lyrics": 0,
"karaoke": 0,
"forced": 0,
"hearing_impaired": 0,
"visual_impaired": 0,
"clean_effects": 0,
"attached_pic": 0,
"timed_thumbnails": 0,
"non_diegetic": 0,
"captions": 0,
"descriptions": 0,
"metadata": 0,
"dependent": 0,
"still_image": 0,
"multilayer": 0
},
"tags": {
"creation_time": "2025-05-06T07:00:11.000000Z",
"language": "eng",
"handler_name": "VideoHandle"
},
"side_data_list": [
{
"side_data_type": "Display Matrix",
"displaymatrix": "\n00000000: 0 65536 0\n00000001: -65536 0 0\n00000002: 0 0 1073741824\n",
"rotation": -90
}
]
}
]
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions