Video Rotator
Rotate or flip videos by 90°, 180°, 270°, or mirror horizontally/vertically.
Video Rotator rotates or flips videos by 90°, 180°, 270°, mirror horizontal, or mirror vertical — pixels are re-rendered on the GPU (WebCodecs). A Hardware-Accelerated alert notes local processing; keep the tab open until rotation completes. Output is always MP4 named {basename}.mp4 with audio preserved.
Five toggle buttons under Rotation select the transform (default Rotate 90° CW). Rotate Video disables if the browser lacks VideoEncoder/VideoDecoder. Dimensions swap on 90°/270°; mirrors keep size.
How it works
mediabunny Conversion decodes each VideoSample and draws it onto an OffscreenCanvas with translate/rotate (±π/2, π) or scale(-1,1)/scale(1,-1) for mirrors, then returns a new VideoSample with the original timestamp. Audio passes through (audio: {}); output uses Mp4OutputFormat + BufferTarget → video/mp4.
An alternate FFmpeg transpose/hflip arg builder exists in the feature but the UI path requires WebCodecs. Rotation is baked into pixels, not metadata-only rotation.
How to use
- Open Video Rotator and read the Hardware-Accelerated alert.
- Drop a video (hint: MP4, WebM, MOV — any video format).
- Preview the source; click Remove to swap files.
- Select one Rotation button: Rotate 90° CW (default), Rotate 180°, Rotate 270° CW, Mirror Horizontal, or Mirror Vertical.
- Click Rotate Video (disabled without WebCodecs or while busy).
- Watch Processing… % and the speed log; output saves as MP4.
- Play the result (Converted to MP4 + size badge).
- Download ({basename}.mp4) or Start Over for another angle.
Tips
- Output is always MP4 regardless of input container — WebM/MOV become .mp4.
- 90°/270° swap width/height; mirrors do not — check player dimensions after rotate.
- Audio is preserved through the conversion.
- Pixels are re-encoded (not a metadata tag) so every player shows the new orientation.
Video Rotator FAQ
Is the video uploaded?
No — GPU/WebCodecs rotation runs locally (the alert says so explicitly).
Why is Rotate Video disabled?
Either no file is loaded or the browser lacks VideoEncoder/VideoDecoder.
Can I rotate by arbitrary angles (e.g. 45°)?
No — only 90°, 180°, 270°, or the two mirrors are offered.
What container will I get?
Always MP4 (video/mp4), named {original-basename}.mp4.
Is the audio kept?
Yes — audio tracks are passed through the conversion.
Credits
- mediabunny — WebCodecs decode/encode with per-frame canvas transforms