- Open Avidemux (free video editing software)
- Open your mp4 file.
- Choose Video > Filters (or in Windows, press Ctrl+Alt+F)
- Double-click “Rotate” to add that filter
- Choose 90 degrees
- Press “Close” to exit “Video Filter Manager”
- Choose File -> Information to see the attributes of your original video
- Choose a “Video Output” other than “Copy” [for LG G2 video choose “Mpeg4 AVC (x264)”]
- Select configure -> General
- Encoding Mode -> Constant Bitrate (Single Pass)
- Target Bitrate -> 16000 kbit/s and click OK to exit.
- Keep audio output on “Copy”.
- Select Output Format -> “MP4 Muxer”
- Save
source: http://superuser.com/questions/82117/rotate-a-mp4-file-while-preserving-codec-and-quality-attributes