+* Fri May 24 2013 Shibata Makoto <shibata@mac.tec.toyota.co.jp> accepted/2.0alpha-wayland/20130520.103636@6271b38
+- ico-app-samplenavi
+- Bug fix: 0 display processing correction of the number of the place of 10.
+
+-ico-app-vicsample
+- A display is changed. (The left : the camera shot, the right : map)
+
* Wed May 22 2013 Shibata Makoto <shibata@mac.tec.toyota.co.jp> accepted/2.0alpha-wayland/20130520.103636@a26f959
- ico-app-samplenavi
- Bug fix: The NoDisplay parameter of a desktop file is changed into "false" from "ture".(TIVI-972)
Name: ico-uxf-HomeScreen-sample-app
Summary: HomeScreen sample application
-Version: 0.0.6
+Version: 0.0.9
Release: 1
Group: System/GUI
License: Apache License, Version 2.0
Requires: automotive-message-broker
#Requires: libopencv2_4
+#DemoMeterApp.wgt DemoAudioApp.wgt
+Requires: pkgmgr
+
%description
HomeScreen sample application
%post
# install shell(DemoMeterApp.wgt DemoAudioApp.wgt)
#sh /opt/apps/homescreen-sample-app/wgt/wgt-install.sh
-wrt-installer -i /tmp/DemoMeterApp.wgt
-wrt-installer -i /tmp/DemoAudioApp.wgt
+pkgcmd -i -t wgt -p /tmp/DemoMeterApp.wgt -q
+pkgcmd -i -t wgt -p /tmp/DemoAudioApp.wgt -q
+#wrt-installer -i /tmp/DemoMeterApp.wgt
+#wrt-installer -i /tmp/DemoAudioApp.wgt
+
+rm -rf /opt/dbspace/.app_info*
+/usr/bin/ail_initdb
+
rm -f /tmp/DemoMeterApp.wgt
rm -f /tmp/DemoAudioApp.wgt
#sh /opt/apps/homescreen-sample-app/wgt/wgt-uninstall.sh
%postun
-id=`wrt-launcher -l | grep -e " DemoMeterApp " | sed -e 's/\s\{1,\}/ /g' | cut -d' ' -f3`
-wrt-installer -u $id
-id=`wrt-launcher -l | grep -e " DemoAudioApp " | sed -e 's/\s\{1,\}/ /g' | cut -d' ' -f3`
-wrt-installer -u $id
+#id=`wrt-launcher -l | grep -e " DemoMeterApp " | sed -e 's/\s\{1,\}/ /g' | cut -d' ' -f3`
+#wrt-installer -u $id
+#id=`wrt-launcher -l | grep -e " DemoAudioApp " | sed -e 's/\s\{1,\}/ /g' | cut -d' ' -f3`
+#wrt-installer -u $id
+pkgcmd -u -t wgt -n AKsMREAjt9 -q
+pkgcmd -u -t wgt -n d41dRLC2Qs -q
+
+rm -rf /opt/dbspace/.app_info*
+/usr/bin/ail_initdb
#map_canvas {\r
float: center;\r
width: 100%;\r
- height: 700px;\r
+ height: 1270px;\r
}\r
#define W_WIDTH (1920)
#define W_HEIGHT (1080-64) /* StatusBar window height:64 */
-#define W_NAVI_HEIGHT (480)
-#define W_MAP_HEIGHT (536)
+#define W_NAVI_WIDTH (W_WIDTH / 2)
+#define W_NAVI_HEIGHT (W_HEIGHT - W_TEXTAREA_HEIGHT)
#define W_NAVI_ORIGINE_X (0)
#define W_NAVI_ORIGINE_Y (0)
-#define W_MAP_ORIGINE_X (0)
-#define W_MAP_ORIGINE_Y (480)
+#define W_MAP_WIDTH (W_WIDTH / 2)
+#define W_MAP_HEIGHT (W_HEIGHT - W_TEXTAREA_HEIGHT)
+#define W_MAP_ORIGINE_X (W_WIDTH / 2)
+#define W_MAP_ORIGINE_Y (0)
#define W_TEXTAREA_X (0)
-#define W_TEXTAREA_Y (416)
+#define W_TEXTAREA_Y (W_HEIGHT - W_TEXTAREA_HEIGHT)
#define W_TEXTAREA_HEIGHT (64)
#define W_TEXTAREA_WIDTH (W_WIDTH)
#define W_GOALMESSAGE_HEIGHT (50)
#define W_GOALMESSAGE_WIDTH (478)
-#define W_GOALMESSAGE_X (150)
-#define W_GOALMESSAGE_Y (283)
+#define W_GOALMESSAGE_X (75)
+#define W_GOALMESSAGE_Y (566)
#define W_ADDRESS_HEIGHT (50)
#define W_ADDRESS_WIDTH (570)
#define LON_CONVERT (90550.8)
#define LAT_CONVERT (111240)
+#define W_METER_HEIGHT (300)
+#define W_METER_WIDTH (320)
+#define W_METER_X (0)
+#define W_METER_Y (W_HEIGHT - 180)
+
+#define W_METER_UNIT_HEIGHT (45)
+#define W_METER_UNIT_WIDTH (478)
+#define W_METER_UNIT_X (180)
+#define W_METER_UNIT_Y (W_HEIGHT - W_METER_UNIT_HEIGHT)
+
/* Directory */
#define RESOURCE_DIR "/opt/apps/org.tizen.ico.app-samplenavi/res"
#define IMAGES_DIR "/opt/apps/org.tizen.ico.app-samplenavi/res/images"
/* set points */
evas_map_point_coord_set(m2, 0,
- (Evas_Coord) (plane->pt[0].x + ((W_WIDTH) / 2)),
+ (Evas_Coord) (plane->pt[0].x + ((W_WIDTH) / 4)),
(Evas_Coord) (plane->pt[0].y +
- ((W_NAVI_HEIGHT) / 2)),
+ ((W_NAVI_HEIGHT) / 4)),
(Evas_Coord) (plane->pt[0].z + FRONT_SIDE_Z));
evas_map_point_coord_set(m2, 1,
- (Evas_Coord) (plane->pt[1].x + ((W_WIDTH) / 2)),
+ (Evas_Coord) (plane->pt[1].x + ((W_WIDTH) / 4)),
(Evas_Coord) (plane->pt[1].y +
- ((W_NAVI_HEIGHT) / 2)),
+ ((W_NAVI_HEIGHT) / 4)),
(Evas_Coord) (plane->pt[1].z + FRONT_SIDE_Z));
evas_map_point_coord_set(m2, 2,
- (Evas_Coord) (plane->pt[2].x + ((W_WIDTH) / 2)),
+ (Evas_Coord) (plane->pt[2].x + ((W_WIDTH) / 4)),
(Evas_Coord) (plane->pt[2].y +
- ((W_NAVI_HEIGHT) / 2)),
+ ((W_NAVI_HEIGHT) / 4)),
(Evas_Coord) (plane->pt[2].z + FRONT_SIDE_Z));
evas_map_point_coord_set(m2, 3,
- (Evas_Coord) (plane->pt[3].x + ((W_WIDTH) / 2)),
+ (Evas_Coord) (plane->pt[3].x + ((W_WIDTH) / 4)),
(Evas_Coord) (plane->pt[3].y +
- ((W_NAVI_HEIGHT) / 2)),
+ ((W_NAVI_HEIGHT) / 4)),
(Evas_Coord) (plane->pt[3].z + FRONT_SIDE_Z));
for (i = 0; i < 4; i++) {
evas_map_point_image_uv_set(m2, i, plane->pt[i].u, plane->pt[i].v);
evas_map_point_color_set(m2, i, 255, 255, 255, 255);
}
- evas_map_util_3d_perspective(m2, (W_WIDTH / 2), (W_NAVI_HEIGHT / 2) - 100,
- Z0_POSITION, FOCUS_LENGTH);
-
+ evas_map_util_3d_perspective(m2, (W_WIDTH / 4), (W_NAVI_HEIGHT / 4) - 100,
+ Z0_POSITION, FOCUS_LENGTH / 2);
evas_object_map_enable_set(plane->o, 1);
evas_object_map_set(plane->o, m2);
break;
}
}
+
/* First Plane (Front) */
CUBE_POINT(0, 0, -w, -h, -d, 0, 0);
CUBE_POINT(0, 1, w, -h, -d, 600, 0);
*
* @param[in] c cube address
* @param[in] x x coordinates
- * @param[in] y y coordinates
+ * param[in] y y coordinates
* @param[in] z z coordinates
* @param[in] dx amount of degrees from 0.0 to 360.0 to rotate around X axis.
* @param[in] dy amount of degrees from 0.0 to 360.0 to rotate around Y axis.
for (j = 0; j < 4; j++) {
evas_map_point_coord_set(m, j,
- c->side[i].pt[j].x + ((W_WIDTH) / 2) +
+ c->side[i].pt[j].x + ((W_WIDTH) / 4) +
x - camera.x,
c->side[i].pt[j].y +
- ((W_NAVI_HEIGHT) / 2) + y - camera.y,
+ (W_NAVI_HEIGHT / 2) + y - camera.y,
c->side[i].pt[j].z + z - camera.z +
FRONT_SIDE_Z);
if (!(i == 4 || i == 5)) {
evas_map_point_color_set(m, j, 255, 255, 255, 255);
}
evas_map_util_3d_rotate(m, dx, dy, dz,
- (W_WIDTH / 2) + x - camera.x,
+ ((W_WIDTH) / 4) + x - camera.x,
(W_NAVI_HEIGHT / 2) + y - camera.y,
z - camera.z + FRONT_SIDE_Z);
/* for camera angle */
evas_map_util_3d_rotate(m, 0, -camera.angle, 0,
- (W_WIDTH / 2), (W_NAVI_HEIGHT / 2),
+ ((W_WIDTH) / 4), (W_NAVI_HEIGHT / 2),
FRONT_SIDE_Z);
- evas_map_util_3d_perspective(m, (W_WIDTH / 2), (W_NAVI_HEIGHT / 2),
- Z0_POSITION, FOCUS_LENGTH);
+ evas_map_util_3d_perspective(m, ((W_WIDTH) / 4), (W_NAVI_HEIGHT / 2),
+ Z0_POSITION, FOCUS_LENGTH / 2);
#ifdef _USE_Z_LIMIT_FIX_
for (j = 0; j < 4; j++) {
evas_map_smooth_set(m3, 0);
evas_map_point_coord_set(m3, 0,
- (Evas_Coord) (plane->pt[0].x + ((W_WIDTH) / 2)),
+ (Evas_Coord) (plane->pt[0].x + ((W_WIDTH) / 4)),
(Evas_Coord) (plane->pt[0].y +
((W_NAVI_HEIGHT) / 2)),
(Evas_Coord) (plane->pt[0].z + FRONT_SIDE_Z));
evas_map_point_coord_set(m3, 1,
- (Evas_Coord) (plane->pt[0].x + ((W_WIDTH) / 2)),
+ (Evas_Coord) (plane->pt[0].x + ((W_WIDTH) / 4)),
(Evas_Coord) ((-1) * plane->pt[0].y +
- (W_NAVI_HEIGHT) / 2),
+ ((W_NAVI_HEIGHT) / 2)),
(Evas_Coord) (plane->pt[0].z + FRONT_SIDE_Z));
evas_map_point_coord_set(m3, 2,
- (Evas_Coord) (plane->pt[3].x + ((W_WIDTH) / 2)),
+ (Evas_Coord) (plane->pt[3].x + ((W_WIDTH) / 4)),
(Evas_Coord) ((-1) * plane->pt[3].y +
- (W_NAVI_HEIGHT) / 2),
+ ((W_NAVI_HEIGHT) / 2)),
(Evas_Coord) (plane->pt[3].z + FRONT_SIDE_Z));
evas_map_point_coord_set(m3, 3,
- (Evas_Coord) (plane->pt[3].x + ((W_WIDTH) / 2)),
+ (Evas_Coord) (plane->pt[3].x + ((W_WIDTH) / 4)),
(Evas_Coord) (plane->pt[3].y +
((W_NAVI_HEIGHT) / 2)),
(Evas_Coord) (plane->pt[3].z + FRONT_SIDE_Z));
evas_map_point_image_uv_set(m3, 2, 0, 600);
evas_map_point_image_uv_set(m3, 3, 0, 0);
- evas_map_util_3d_perspective(m3, (W_WIDTH / 2), (W_NAVI_HEIGHT / 2) - 100,
- Z0_POSITION, FOCUS_LENGTH);
+ evas_map_util_3d_perspective(m3, (W_WIDTH / 4), (W_NAVI_HEIGHT / 2) - 100,
+ Z0_POSITION, FOCUS_LENGTH / 2);
evas_object_map_enable_set(goal_object, 1);
evas_object_map_set(goal_object, m3);
//#define DEBUG_VIC_INFO_SET
#ifdef DEBUG_VIC_INFO_SET
+#include <math.h>
extern int route_data_count;
extern CsvRoute csv_route[MAX_ROUTE_POINTS];
static double test_lat = 35.47945;
static double test_lon = 139.40026;
+static int test_dir = 0;
static int test_cnt = 0;
#endif
/* DEBUG.e */
fig_r = w_fig_r;
}
- if (w_fig_c != fig_c) {
+ if (w_fig_c != fig_c || fig_c == 0) {
evas_object_hide(ui_meter_c[fig_c]);
if (w_fig_c != 0 || w_fig_l == 1) {
sprintf(str, "[kph] %d", ui_vicspeed);
evas_object_text_text_set(ui_vicspeed_text, str);
evas_object_move(ui_vicspeed_text, 0, 430);
- evas_object_resize(ui_vicspeed_text, W_GOALMESSAGE_WIDTH,
- W_GOALMESSAGE_HEIGHT);
+ evas_object_resize(ui_vicspeed_text, W_METER_UNIT_WIDTH,
+ W_METER_UNIT_HEIGHT);
evas_object_show(ui_vicspeed_text);
evas_object_layer_set(ui_vicspeed_text, LAYER_UI);
#else
ui_meter_l = evas_object_image_add(e_ui);
evas_object_image_file_set(ui_meter_l, meter_l_path, NULL);
- evas_object_image_fill_set(ui_meter_l, 0, 0, 300, 320);
- evas_object_move(ui_meter_l, 0, 300);
- evas_object_resize(ui_meter_l, 300, 320);
+ evas_object_image_fill_set(ui_meter_l, 0, 0, W_METER_HEIGHT,
+ W_METER_WIDTH);
+ evas_object_move(ui_meter_l, W_METER_X, W_METER_Y);
+ evas_object_resize(ui_meter_l, W_METER_HEIGHT, W_METER_WIDTH);
evas_object_hide(ui_meter_l);
evas_object_layer_set(ui_meter_l, LAYER_UI);
for (i = 0; i < 10; i++) {
ui_meter_c[i] = evas_object_image_add(e_ui);
evas_object_image_file_set(ui_meter_c[i], meter_c_path[i], NULL);
- evas_object_image_fill_set(ui_meter_c[i], 0, 0, 300, 320);
- evas_object_move(ui_meter_c[i], 0, 300);
- evas_object_resize(ui_meter_c[i], 300, 320);
+ evas_object_image_fill_set(ui_meter_c[i], 0, 0, W_METER_HEIGHT,
+ W_METER_WIDTH);
+ evas_object_move(ui_meter_c[i], W_METER_X, W_METER_Y);
+ evas_object_resize(ui_meter_c[i], W_METER_HEIGHT, W_METER_WIDTH);
evas_object_hide(ui_meter_c[i]);
evas_object_layer_set(ui_meter_c[i], LAYER_UI);
ui_meter_r[i] = evas_object_image_add(e_ui);
evas_object_image_file_set(ui_meter_r[i], meter_r_path[i], NULL);
- evas_object_image_fill_set(ui_meter_r[i], 0, 0, 300, 320);
- evas_object_move(ui_meter_r[i], 0, 300);
- evas_object_resize(ui_meter_r[i], 300, 320);
+ evas_object_image_fill_set(ui_meter_r[i], 0, 0, W_METER_HEIGHT,
+ W_METER_WIDTH);
+ evas_object_move(ui_meter_r[i], W_METER_X, W_METER_Y);
+ evas_object_resize(ui_meter_r[i], W_METER_HEIGHT, W_METER_WIDTH);
evas_object_hide(ui_meter_r[i]);
evas_object_layer_set(ui_meter_r[i], LAYER_UI);
}
evas_object_color_set(ui_vicspeed_text, 255, 255, 255, 255);
evas_object_text_font_set(ui_vicspeed_text, "Utopia", 24);
evas_object_text_text_set(ui_vicspeed_text, "kph");
- evas_object_move(ui_vicspeed_text, 180, 440);
- evas_object_resize(ui_vicspeed_text, W_GOALMESSAGE_WIDTH,
- W_GOALMESSAGE_HEIGHT);
+ evas_object_move(ui_vicspeed_text, W_METER_UNIT_X, W_METER_UNIT_Y);
+ evas_object_resize(ui_vicspeed_text, W_METER_UNIT_WIDTH,
+ W_METER_UNIT_HEIGHT);
evas_object_show(ui_vicspeed_text);
+
evas_object_layer_set(ui_vicspeed_text, LAYER_UI);
#endif
browser = ewk_view_add(e_map);
ewk_context_proxy_uri_set(ewk_view_context_get(browser), proxy_uri);
evas_object_move(browser, W_MAP_ORIGINE_X, W_MAP_ORIGINE_Y);
- evas_object_resize(browser, W_WIDTH, W_MAP_HEIGHT);
+ evas_object_resize(browser, W_MAP_WIDTH, W_MAP_HEIGHT);
evas_object_show(browser);
ewk_view_uri_set(browser, default_url);
evas_object_layer_set(browser, LAYER_MAP);
evas_object_show(cam);
}
#else
- evas_object_image_fill_set(cam, 0, 0, W_WIDTH, W_NAVI_HEIGHT);
+ evas_object_image_fill_set(cam, 0, 0, W_NAVI_WIDTH, W_NAVI_HEIGHT);
evas_object_move(cam, W_NAVI_ORIGINE_X, W_NAVI_ORIGINE_Y);
- evas_object_resize(cam, W_WIDTH, W_NAVI_HEIGHT);
+ evas_object_resize(cam, W_NAVI_WIDTH, W_NAVI_HEIGHT);
evas_object_show(cam);
#endif
{
/* DEBUG.s */
#ifdef DEBUG_VIC_INFO_SET
- if (test_cnt < route_data_count) {
- test_lat = csv_route[test_cnt].lat;
- test_lon = csv_route[test_cnt].lon;
- camera_geocode.lat = test_lat;
- camera_geocode.lon = test_lon;
- test_cnt++;
+double lat_tmp = 0;
+double lon_tmp = 0;
+int add_angle = 0;
+
+if (test_cnt < route_data_count) {
+ test_lat = csv_route[test_cnt].lat;
+ test_lon = csv_route[test_cnt].lon;
+
+ if ((test_cnt + 1) != route_data_count) {
+ lat_tmp = csv_route[test_cnt + 1].lat - test_lat;
+ lon_tmp = csv_route[test_cnt + 1].lon - test_lon;
+
+ if (lat_tmp >= 0 && lon_tmp >= 0) {
+ add_angle = 0;
+ test_dir =
+ atan((fabs(lon_tmp) / fabs(lat_tmp))) * 180.0 / (atan(1.0) *
+ 4.0);
+ }
+ else if (lat_tmp < 0 && lon_tmp >= 0) {
+ add_angle = 90;
+ test_dir =
+ atan((fabs(lat_tmp) / fabs(lon_tmp))) * 180.0 / (atan(1.0) *
+ 4.0);
+ }
+ else if (lat_tmp < 0 && lon_tmp < 0) {
+ add_angle = 180;
+ test_dir =
+ atan((fabs(lon_tmp) / fabs(lat_tmp))) * 180.0 / (atan(1.0) *
+ 4.0);
+ }
+ else if (lat_tmp >= 0 && lon_tmp < 0) {
+ add_angle = 270;
+ test_dir =
+ atan((fabs(lat_tmp) / fabs(lon_tmp))) * 180.0 / (atan(1.0) *
+ 4.0);
+ }
+ test_dir = test_dir + add_angle;
}
+ camera_geocode.lat = test_lat;
+ camera_geocode.lon = test_lon;
+ camera_geocode.dir = test_dir;
+ test_cnt++;
+
+ uim_debug("test_lat = [%f]", test_lat);
+ uim_debug("test_lon = [%f]", test_lon);
+ uim_debug("test_dir = [%d]", test_dir);
+}
#endif
/* DEBUG.e */
}
}
else if ((in != NULL) && (strncmp("CLOSE", in, strlen("CLOSE")) == 0)) {
+ evas_object_hide(g_edje);
evas_object_del(g_edje);
uim_debug("ONSCREEN CLOSE");
}
message,
reply_timeout, &error);
if (reply == NULL) {
-//DEBUG uim_debug( "Err dbus_connection_send_with_reply_and_block" );
+ uim_debug( "Err dbus_connection_send_with_reply_and_block" );
/* Release the connection */
dbus_connection_unref(g_connection);
result = getAmbDbus(i, vic_val);
if (result != 0) {
-//DEBUG uim_debug("Err getAmbDbus : Unacquired [%s]",vic_data[i].name);
+ uim_debug("Err getAmbDbus : Unacquired [%s]",vic_data[i].name);
continue;
}
}
break;
case VEHICLESPEED:
-//DEBUG uim_debug ("%s(%d)",vic_data[i].name, vic_val[0].i32_val);
if (ui_vicspeed != vic_val[0].i32_val) {
uim_debug("%s(%d)", vic_data[i].name, vic_val[0].i32_val);
ui_vicspeed = vic_val[0].i32_val;
(g_edje, edje_file, (const char *) group->data)) {
int err = edje_object_load_error_get(g_edje);
const char *errmsg = edje_load_error_str(err);
- uim_debug("Setting screen: could not load %s: %s", edje_file, errmsg);
+ uim_debug("Setting screen: could not load %s: %s", edje_file,
+ errmsg);
edje_file_collection_list_free(group);
evas_object_del(g_edje);
#endif /* _USE_OPENCV_ */
#endif
- evas_object_image_fill_set(cam, 0, 0, W_WIDTH, W_NAVI_HEIGHT);
- evas_object_move(cam, W_NAVI_ORIGINE_X, W_NAVI_ORIGINE_Y);
- evas_object_resize(cam, W_WIDTH, W_NAVI_HEIGHT);
+ evas_object_image_fill_set(cam, 0, 0, W_NAVI_WIDTH, W_NAVI_HEIGHT);
+ evas_object_move(cam, W_NAVI_ORIGINE_X, W_NAVI_ORIGINE_Y);
+ evas_object_resize(cam, W_NAVI_WIDTH, W_NAVI_HEIGHT);
evas_object_show(cam);
/* 3D Layer */