return ret;
}
+
+int player_set_display_roi_area(player_h player, int x, int y, int width, int height)
+{
+ PLAYER_INSTANCE_CHECK(player);
+ int ret = PLAYER_ERROR_NONE;
+ muse_player_api_e api = MUSE_PLAYER_API_SET_DISPLAY_ROI_AREA;
+ player_cli_s *pc = (player_cli_s *) player;
+ char *ret_buf = NULL;
+ wl_win_msg_type wl_win;
+ char *wl_win_msg = (char *)&wl_win;
+
+ LOGD("ENTER");
+#ifdef TIZEN_FEATURE_EVAS_RENDERER
+ if (EVAS_HANDLE(pc)) {
+ ret = mm_evas_renderer_set_roi_area(EVAS_HANDLE(pc), x, y, width, height);
+ return ret;
+ }
+#endif
+ wl_win.wl_window_x = x;
+ wl_win.wl_window_y = y;
+ wl_win.wl_window_width = width;
+ wl_win.wl_window_height = height;
+
+ player_msg_send_array(api, pc, ret_buf, ret, wl_win_msg, sizeof(wl_win_msg_type), sizeof(char));
+ g_free(ret_buf);
+ return ret;
+}
+
int player_set_playback_rate(player_h player, float rate)
{
PLAYER_INSTANCE_CHECK(player);
CURRENT_STATUS_LOOPING,
CURRENT_STATUS_DISPLAY_SURFACE_CHANGE,
CURRENT_STATUS_DISPLAY_MODE,
+ CURRENT_STATUS_DISPLAY_DST_ROI,
CURRENT_STATUS_DISPLAY_ROTATION,
CURRENT_STATUS_DISPLAY_VISIBLE,
CURRENT_STATUS_SUBTITLE_FILENAME,
g_print(" ==> [Player_Test] Display mode: [%d ] \n", mode);
}
+static void set_display_roi_area(int x, int y, int width, int height)
+{
+ //player_set_display_roi_area(g_player[0], x, y, width, height);
+ g_print(" ==> [Player_Test] Display roi area: [x(%d) y(%d) width(%d) height(%d)] \n", x, y, width, height);
+}
+
static void set_display_rotation(int rotation)
{
if (player_set_display_rotation(g_player[0], rotation) != PLAYER_ERROR_NONE)
g_print("memory playback = %d\n", g_memory_playback);
} else if (strncmp(cmd, "ds", 2) == 0) {
g_menu_state = CURRENT_STATUS_DISPLAY_SURFACE_CHANGE;
+ } else if (strncmp(cmd, "dr", 2) == 0) {
+ g_print("now, PLAYER_DISPLAY_MODE_DST_ROI(display mode) is set\n");
+ g_menu_state = CURRENT_STATUS_DISPLAY_DST_ROI;
} else if (strncmp(cmd, "nb", 2) == 0) {
g_menu_state = CURRENT_STATUS_HANDLE_NUM;
} else if (strncmp(cmd, "tr", 2) == 0) {
g_print("[display] v. Set display visible\t");
g_print("w. Get display visible\n");
g_print("[display] ds. Change display surface type\n");
+ g_print("[display] dr. set display roi area\n");
g_print("[overlay display] r. Set display mode\t");
g_print("s. Get display mode\n");
g_print("[overlay display] t. Set display Rotation\n");
g_print("*** input display surface type.(0: X surface, 1: EVAS surface) \n");
} else if (g_menu_state == CURRENT_STATUS_DISPLAY_MODE) {
g_print("*** input display mode value.(0: LETTER BOX, 1: ORIGIN SIZE, 2: FULL_SCREEN, 3: CROPPED_FULL, 4: ORIGIN_OR_LETTER) \n");
+ } else if (g_menu_state == CURRENT_STATUS_DISPLAY_DST_ROI) {
+ g_print("*** input display roi value sequentially.(x, y, w, h)\n");
} else if (g_menu_state == CURRENT_STATUS_DISPLAY_ROTATION) {
g_print("*** input display rotation value.(0: NONE, 1: 90, 2: 180, 3: 270, 4:F LIP_HORZ, 5: FLIP_VERT ) \n");
} else if (g_menu_state == CURRENT_STATUS_DISPLAY_VISIBLE) {
reset_menu_state();
}
break;
+ case CURRENT_STATUS_DISPLAY_DST_ROI:
+ {
+ int value = atoi(cmd);
+ static int x = 0;
+ static int y = 0;
+ static int w = 0;
+ static int h = 0;
+ static int cnt = 0;
+
+ set_display_mode(PLAYER_DISPLAY_MODE_DST_ROI);
+ switch (cnt) {
+ case 0:
+ x = value;
+ cnt++;
+ break;
+ case 1:
+ y = value;
+ cnt++;
+ break;
+ case 2:
+ w = value;
+ cnt++;
+ break;
+ case 3:
+ cnt = 0;
+ h = value;
+ set_display_roi_area(x, y, w, h);
+ x = y = w = h = 0;
+ reset_menu_state();
+ break;
+ default:
+ break;
+ }
+ }
+ break;
case CURRENT_STATUS_DISPLAY_ROTATION:
{
int rotation = atoi(cmd);