summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYounghwan Ahn <younghwan_.an@samsung.com>2013-01-15 17:37:09 +0900
committerYounghwan Ahn <younghwan_.an@samsung.com>2013-01-15 17:37:09 +0900
commitcd3ba65b8fe9198de13c300f49bb21f2a8fa1815 (patch)
treeddd6bb311350c6c62849d415d065b9f698d0584b
parent1bf58f0f2024024f398d47c6d27848935d73b46f (diff)
downloadlibmm-player-cd3ba65b8fe9198de13c300f49bb21f2a8fa1815.tar.gz
libmm-player-cd3ba65b8fe9198de13c300f49bb21f2a8fa1815.tar.bz2
libmm-player-cd3ba65b8fe9198de13c300f49bb21f2a8fa1815.zip
fix bug for setting rotation
Change-Id: Iac0803e9bc4fa7b1dc0ff11b79c3265967362969
-rwxr-xr-xsrc/mm_player_priv.c25
1 files changed, 23 insertions, 2 deletions
diff --git a/src/mm_player_priv.c b/src/mm_player_priv.c
index c583c8d..1a1091c 100755
--- a/src/mm_player_priv.c
+++ b/src/mm_player_priv.c
@@ -2417,7 +2417,7 @@ __mmplayer_get_property_value_for_rotation(mm_player_t* player, int rotation_ang
int dest_angle = rotation_angle;
char *element_name = NULL;
int rotation_using_type = -1;
- #define ROTATION_USING_X 0
+ #define ROTATION_USING_X 0
#define ROTATION_USING_FLIP 1
return_val_if_fail(player, FALSE);
@@ -2436,7 +2436,28 @@ __mmplayer_get_property_value_for_rotation(mm_player_t* player, int rotation_ang
return FALSE;
}
- rotation_using_type = ROTATION_USING_FLIP;
+ if (player->use_video_stream)
+ {
+ rotation_using_type = ROTATION_USING_FLIP;
+ }
+ else
+ {
+ int surface_type = 0;
+ mm_attrs_get_int_by_name(player->attrs, "display_surface_type", &surface_type);
+ debug_log("check display surface type for rotation: %d", surface_type);
+
+ switch (surface_type)
+ {
+ case MM_DISPLAY_SURFACE_X:
+ rotation_using_type = ROTATION_USING_X;
+ break;
+ case MM_DISPLAY_SURFACE_EVAS:
+ default:
+ rotation_using_type = ROTATION_USING_FLIP;
+ break;
+ }
+ }
+
debug_log("using %d type for rotation", rotation_using_type);
/* get property value for setting */