From 72093df9fdf281ccd581baf5993bdc2ec6957342 Mon Sep 17 00:00:00 2001 From: David Walter Seikel Date: Sun, 3 Jan 2016 20:35:53 +1000 Subject: Clean up logging, removing most of the printf's. --- src/extantz/camera.c | 10 +++++----- src/extantz/extantz.c | 6 ++---- src/extantz/gears.c | 5 ++--- 3 files changed, 9 insertions(+), 12 deletions(-) (limited to 'src/extantz') diff --git a/src/extantz/camera.c b/src/extantz/camera.c index 4bcf64c..123285c 100644 --- a/src/extantz/camera.c +++ b/src/extantz/camera.c @@ -92,9 +92,9 @@ static void _on_camera_input_down(void *data, Evas *evas, Evas_Object *obj, void else if (0 == strcmp(ev->key, "Home")) move->x = -2.0; else if (0 == strcmp(ev->key, "End")) move->x = 2.0; else if (0 == strcmp(ev->key, "space")) move->jump = 1.0; - else printf("Unexpected down keystroke - %s\n", ev->key); + else PW("Unexpected down keystroke - %s", ev->key); } - else printf("Camera input not ready\n"); + else PE("Camera input not ready"); } /* SL / OS camera controls @@ -184,9 +184,9 @@ static void _on_camera_input_up(void *data, Evas *evas, Evas_Object *obj, void * else if (0 == strcmp(ev->key, "Home")) move->x = 0.0; else if (0 == strcmp(ev->key, "End")) move->x = 0.0; else if (0 == strcmp(ev->key, "space")) move->jump = 0.0; - else printf("Unexpected up keystroke - %s\n", ev->key); + else PW("Unexpected up keystroke - %s", ev->key); } - else printf("Camera input not ready\n"); + else PE("Camera input not ready"); } /* While it's true that image is an Elm image, seems this Elm input event callback doesn't work. @@ -212,7 +212,7 @@ static Eina_Bool _cb_event_GL(void *data, Evas_Object *obj, Evas_Object *src, Ev } default : - printf("Unknown GL input event.\n"); + PE("Unknown GL input event."); } return processed; diff --git a/src/extantz/extantz.c b/src/extantz/extantz.c index c2dadba..840dfec 100644 --- a/src/extantz/extantz.c +++ b/src/extantz/extantz.c @@ -42,7 +42,6 @@ static Eina_Bool clientParser(void *data, Connection *connection, char *SID, cha || (0 == strncmp(command, "llSay(", 6)) || (0 == strncmp(command, "llShout(", 8))) { - sprintf(buf, "%s: %s", SID, command); if (ourGlobals->purkle) { @@ -53,7 +52,7 @@ static Eina_Bool clientParser(void *data, Connection *connection, char *SID, cha push_lua(ourGlobals->purkle->L, "@ ( $ )", _P, "append", buf, 0); } else - PW("No purkle to put - %s", buf); + PE("No purkle to put - %s", buf); } else if (0 == strncmp(command, "llDialog(", 9)) { @@ -69,7 +68,6 @@ static Eina_Bool clientParser(void *data, Connection *connection, char *SID, cha } else PE("No LSLGuiMess to send - %s", command); - } else if (0 == strncmp(command, "loadSim(", 8)) { @@ -556,7 +554,7 @@ static Eina_Bool _makeLove(void *data) ecore_job_add((Ecore_Cb) _makeFiles, ourGlobals); // ecore_timer_add(0.1, _makeFiles, ourGlobals); - PD("About to try connecting to a love server."); +// PD("About to try connecting to a love server."); reachOut("love", "./love", "127.0.0.1", 8211 + 1, ourGlobals, (Ecore_Event_Handler_Cb) _add, /*(Ecore_Event_Handler_Cb) _data*/ NULL, (Ecore_Event_Handler_Cb) _del, clientParser); return ECORE_CALLBACK_CANCEL; diff --git a/src/extantz/gears.c b/src/extantz/gears.c index 68f817e..9998357 100644 --- a/src/extantz/gears.c +++ b/src/extantz/gears.c @@ -279,8 +279,7 @@ static GLuint load_shader(GLData *gld, GLenum type, const char *shader_src) if (info) { gl->glGetShaderInfoLog(shader, len, NULL, info); - printf("Error compiling shader:\n" - "%s\n", info); + PE("Error compiling shader: %s", info); free(info); } } @@ -332,7 +331,7 @@ void gears_init(GLData *gld) if (info) { gld->glApi->glGetProgramInfoLog(gld->program, len, NULL, info); - printf("Error linking program:\n%s\n", info); + PE("Error linking program: %s", info); free(info); } } -- cgit v1.1