Metlivi Studio

Why a Portrait Clip Plays Sideways in One Player and Upright in Another

A portrait clip can contain sideways video frames plus an instruction telling the player to rotate them for display. One player follows that instruction; another ignores it. To fix the mismatch, first determine whether the orientation depends on metadata, then decide whether to preserve that instruction or export upright frames.

This guide is for creators who have one finished clip that looks correct in one application and sideways in another. The task is to make that same composition display upright in the intended destination, without accidentally adding another rotation or cropping the scene.

Why can the same file have two apparent orientations?

A video’s stored frame orientation and its intended display orientation can differ. Android’s official MediaMuxer documentation gives a concrete example: its orientation-setting method adds a rotation matrix to an MP4 without rotating the video frames themselves. The documentation explicitly says that some players may ignore that matrix. This explains how identical video content can appear upright in one player and sideways in another. MediaMuxer: setOrientationHint

Imagine an illustrative clip of a yellow watering can on a shelf. The stored image is 1920 pixels wide and 1080 pixels high, with the shelf running vertically. A quarter-turn display instruction makes the intended picture 1080 pixels wide and 1920 pixels high, with the shelf horizontal. A player that omits that instruction shows the sideways stored image.

Consequently, a reported width greater than height does not, by itself, prove that a portrait recording is wrong. You need to compare the stored geometry, the display instruction, and the visible scene.

What should you check before changing the clip?

Start by opening the exact same file in both players. Comparing an original recording with an exported copy introduces another variable: the export may have changed the orientation handling. Give the file a recognizable name and note which application shows it correctly.

Choose a visible reference that makes the intended result unambiguous. For the watering-can example, use three observations: the shelf should be horizontal, the can’s opening should face upward, and its handle should remain on the intended side. An asymmetric object helps you distinguish rotation from an unintended flip.

Use this decision aid to choose your next check. These are diagnostic starting points, rather than proof of a particular cause.

What you observe What to investigate next
The same file is upright in one player and sideways in another Whether playback depends on rotation metadata
Every player shows the same sideways picture Whether the frames need rotation or the display instruction is missing or incorrect
The original is upright, but an exported copy is sideways How the export handled orientation
The scene is upright but stretched, cropped, or surrounded by unwanted borders Frame shape, scaling, and framing before adding rotation

Keep the original while testing. Make each correction into a separately named copy so you can compare the result with the source rather than repeatedly modifying your only reference.

How can you inspect the stored orientation?

If you have FFmpeg’s tools installed, ffprobe can report the first video stream’s properties. Place your clip in the current working folder and name it portrait-input.mp4, or replace that filename in this command. It reads the file and prints information without creating an output video. FFprobe documents stream inspection through -show_streams. ffprobe Documentation

ffprobe -v error -select_streams v:0 -show_streams "portrait-input.mp4"

Look for width, height, and any display-matrix or rotation information in the output. Read the rotation information alongside the dimensions; neither alone establishes whether the composition is upright. Missing rotation information also does not establish the scene’s visual orientation. These commands are provided for your local inspection and were not executed against a sample clip here.

For a more direct visual comparison, FFplay can play the file with its default automatic rotation, then with that behavior disabled. Close the first playback window before running the second command. FFplay’s documentation confirms that automatic rotation follows file metadata and is enabled by default. ffplay Documentation: autorotate

ffplay "portrait-input.mp4"
ffplay -noautorotate "portrait-input.mp4"

If the first view is upright and the second is sideways, the comparison strongly indicates that the intended orientation depends on the display instruction. If both views agree, continue investigating the export and the destination player rather than assuming a metadata mismatch.

Should you change metadata or rotate the actual frames?

Choose according to where the clip must work. If the intended playback environment correctly honors the orientation instruction, retaining it may be sufficient. If the destination displays the underlying sideways picture, exporting frames that are already upright reduces reliance on that instruction. This is a practical inference from the documented difference between stored frames and playback rotation.

There is a processing tradeoff. FFmpeg distinguishes stream copying, which avoids decoding and encoding, from transcoding. Its documentation says that automatic rotation is applied during filtering when transcoding; with copying, the display metadata can instead be written to a supporting output container. A copy operation therefore should not be assumed to bake rotation into the image. ffmpeg Documentation

Before choosing an export method, state your intended result plainly: “The shelf is horizontal, the opening faces up, the complete can remains visible, and the finished frame is portrait.” That specification is more useful than choosing a rotation angle solely from a metadata number.

How do you correct the orientation without rotating twice?

Open a working copy in your chosen editor or converter and inspect its initial preview. If the application already displays the clip upright, adding a quarter-turn manually would change an already correct view. Your next task is to verify how its export represents that upright result.

If the preview is sideways, apply one quarter-turn in the direction that makes your visual references correct. For example, FFmpeg’s documented transpose filter distinguishes clock for a clockwise quarter-turn and cclock for a counterclockwise quarter-turn. These are image-filter directions; choose based on the visible result rather than transferring an angle between unrelated controls. FFmpeg Filters Documentation: transpose

On a Mac, QuickTime Player offers a straightforward visual correction: open the movie, choose View > Show Clips, select the clip, and use the Edit menu to rotate it left or right. Click Done when finished. Apple documents these editing steps, but the corrected preview still needs verification in your destination. Rotate or flip a clip in QuickTime Player on Mac

For a delivery copy intended to contain upright frames, use an export workflow that actually processes the video, then inspect the resulting file. Do not treat a player’s temporary viewing adjustment as evidence that the saved file has changed. Likewise, avoid adding a manual rotation filter on top of an automatic correction without checking the preview first.

Does making the frame portrait fix the composition?

Orientation and framing require separate decisions. In the illustrative 1920-by-1080 example, a quarter-turn produces a 1080-by-1920 arrangement by exchanging the two axes. Forcing the sideways image into a tall rectangle does not establish which way the watering can should face.

After correction, compare the edges of the scene with the original upright view. Is the spout complete? Does the shelf still meet the same edges? Has the handle moved to the opposite side? These questions reveal a crop, a framing change, or a flip that an “upright” check alone would miss.

If the scene is upright but important details are cut off, revisit the export’s framing choices. Do not keep rotating the clip to solve a problem whose visible symptom is missing content.

How do you verify the finished clip?

Check the saved output independently of the editor preview. Use this sequence as your acceptance test:

  1. Open the new output in the player that originally showed the problem.
  2. Open that same output in the player that previously showed it correctly.
  3. Compare a matching moment: shelf horizontal, opening upward, handle on the intended side.
  4. Check the beginning, middle, and end for consistent orientation and complete framing.
  5. If you intended to bake orientation into the frames, repeat the FFplay comparison with automatic rotation enabled and disabled. Both should show the intended upright scene.
  6. Test the actual destination’s processed playback if it creates another version of the uploaded file.

If the output still depends on automatic rotation, revisit how the export represents orientation. If it appears upright in both diagnostic views but sideways at the destination, investigate that destination’s processing and playback behavior using the verified output as your reference.

The correction is complete when the saved delivery file shows the intended upright scene in its actual destination, with the composition intact. Keep that verified copy distinct from the original so the result is easy to reproduce and compare.

Sources