Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDave Badia <dbadia@gmail.com>2011-06-10 23:18:26 +0400
committerMichael Niedermayer <michaelni@gmx.at>2011-06-11 00:13:26 +0400
commitd3cef0a85b7d3fd133a3349341646fe15aeb0030 (patch)
tree3cec7c8107bf10feed3dd9cf4535ef762ddc17c4 /libavformat/mov.c
parent0fd82fedc9b279cd12f71dd7de954cfb60fa9dea (diff)
Extract rotation in MOV metadata
Diffstat (limited to 'libavformat/mov.c')
-rw-r--r--libavformat/mov.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libavformat/mov.c b/libavformat/mov.c
index 00330a6f27..4eb8c74a34 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -1926,6 +1926,10 @@ static int mov_read_tkhd(MOVContext *c, AVIOContext *pb, MOVAtom atom)
sc->width = width >> 16;
sc->height = height >> 16;
+ if (display_matrix[0][0] == -65536 && display_matrix[1][1] == -65536) {
+ av_metadata_set2(&st->metadata, "rotate", "180", 0);
+ }
+
// transform the display width/height according to the matrix
// skip this if the display matrix is the default identity matrix
// or if it is rotating the picture, ex iPhone 3GS