make clang happy
authorenglebass <englebass@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Fri, 15 Jan 2010 20:50:48 +0000 (20:50 +0000)
committerenglebass <englebass@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Fri, 15 Jan 2010 20:50:48 +0000 (20:50 +0000)
git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/emotion@45196 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33

src/bin/emotion_test_main.c
src/modules/gstreamer/emotion_gstreamer.c
src/modules/xine/emotion_xine.c
src/modules/xine/emotion_xine_vo_out.c

index e8b4c00..7977945 100644 (file)
@@ -394,9 +394,6 @@ video_obj_down_cb(void *data, Evas *ev, Evas_Object *obj, void *event_info)
 static void
 video_obj_up_cb(void *data, Evas *ev, Evas_Object *obj, void *event_info)
 {
-   Evas_Event_Mouse_Up *e;
-
-   e = event_info;
    evas_object_color_set(obj, 100, 100, 100, 100);
 }
 
@@ -501,9 +498,6 @@ video_obj_position_update_cb(void *data, Evas_Object *obj, void *event_info)
 static void
 video_obj_stopped_cb(void *data, Evas_Object *obj, void *event_info)
 {
-   Evas_Object *oe;
-
-   oe = data;
    printf("video stopped!\n");
    emotion_object_position_set(obj, 0.0);
    emotion_object_play_set(obj, 1);
@@ -512,9 +506,6 @@ video_obj_stopped_cb(void *data, Evas_Object *obj, void *event_info)
 static void
 video_obj_channels_cb(void *data, Evas_Object *obj, void *event_info)
 {
-   Evas_Object *oe;
-
-   oe = data;
    printf("channels changed: [AUD %i][VID %i][SPU %i]\n",
          emotion_object_audio_channel_count(obj),
          emotion_object_video_channel_count(obj),
@@ -524,18 +515,12 @@ video_obj_channels_cb(void *data, Evas_Object *obj, void *event_info)
 static void
 video_obj_title_cb(void *data, Evas_Object *obj, void *event_info)
 {
-   Evas_Object *oe;
-
-   oe = data;
    printf("video title to: \"%s\"\n", emotion_object_title_get(obj));
 }
 
 static void
 video_obj_progress_cb(void *data, Evas_Object *obj, void *event_info)
 {
-   Evas_Object *oe;
-
-   oe = data;
    printf("progress: \"%s\" %3.3f\n",
          emotion_object_progress_info_get(obj),
          emotion_object_progress_status_get(obj));
@@ -544,9 +529,6 @@ video_obj_progress_cb(void *data, Evas_Object *obj, void *event_info)
 static void
 video_obj_ref_cb(void *data, Evas_Object *obj, void *event_info)
 {
-   Evas_Object *oe;
-
-   oe = data;
    printf("video ref to: \"%s\" %i\n",
          emotion_object_ref_file_get(obj),
          emotion_object_ref_num_get(obj));
@@ -555,9 +537,6 @@ video_obj_ref_cb(void *data, Evas_Object *obj, void *event_info)
 static void
 video_obj_button_num_cb(void *data, Evas_Object *obj, void *event_info)
 {
-   Evas_Object *oe;
-
-   oe = data;
    printf("video spu buttons to: %i\n",
          emotion_object_spu_button_count_get(obj));
 }
@@ -565,9 +544,6 @@ video_obj_button_num_cb(void *data, Evas_Object *obj, void *event_info)
 static void
 video_obj_button_cb(void *data, Evas_Object *obj, void *event_info)
 {
-   Evas_Object *oe;
-
-   oe = data;
    printf("video selected spu button: %i\n",
          emotion_object_spu_button_get(obj));
 }
index e894e3e..6500847 100644 (file)
@@ -771,21 +771,14 @@ em_audio_handled(void *video)
 }
 
 static int
-em_seekable(void *video)
+em_seekable(void *video __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
-
    return 1;
 }
 
 static void
-em_frame_done(void *video)
+em_frame_done(void *video __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
 }
 
 static Emotion_Format
@@ -899,27 +892,18 @@ em_bgra_data_get(void *video, unsigned char **bgra_data)
 }
 
 static void
-em_event_feed(void *video, int event __UNUSED__)
+em_event_feed(void *video __UNUSED__, int event __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
 }
 
 static void
-em_event_mouse_button_feed(void *video, int button __UNUSED__, int x __UNUSED__, int y __UNUSED__)
+em_event_mouse_button_feed(void *video __UNUSED__, int button __UNUSED__, int x __UNUSED__, int y __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
 }
 
 static void
-em_event_mouse_move_feed(void *video, int x __UNUSED__, int y __UNUSED__)
+em_event_mouse_move_feed(void *video __UNUSED__, int x __UNUSED__, int y __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
 }
 
 /* Video channels */
@@ -956,13 +940,9 @@ em_video_channel_get(void *video)
 }
 
 static const char *
-em_video_channel_name_get(void *video,
+em_video_channel_name_get(void *video __UNUSED__,
                          int   channel __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
-
    return NULL;
 }
 
@@ -1022,13 +1002,9 @@ em_audio_channel_get(void *video)
 }
 
 static const char *
-em_audio_channel_name_get(void *video,
+em_audio_channel_name_get(void *video __UNUSED__,
                          int   channel __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
-
    return NULL;
 }
 
@@ -1099,122 +1075,76 @@ em_audio_channel_volume_get(void *video)
 /* spu stuff */
 
 static int
-em_spu_channel_count(void *video)
+em_spu_channel_count(void *video __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
-
    return 0;
 }
 
 static void
-em_spu_channel_set(void *video, int channel __UNUSED__)
+em_spu_channel_set(void *video __UNUSED__, int channel __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
 }
 
 static int
-em_spu_channel_get(void *video)
+em_spu_channel_get(void *video __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
-
    return 1;
 }
 
 static const char *
-em_spu_channel_name_get(void *video, int channel __UNUSED__)
+em_spu_channel_name_get(void *video __UNUSED__, int channel __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
    return NULL;
 }
 
 static void
-em_spu_channel_mute_set(void *video, int mute __UNUSED__)
+em_spu_channel_mute_set(void *video __UNUSED__, int mute __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
 }
 
 static int
-em_spu_channel_mute_get(void *video)
+em_spu_channel_mute_get(void *video __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
-
    return 0;
 }
 
 static int
-em_chapter_count(void *video)
+em_chapter_count(void *video __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
    return 0;
 }
 
 static void
-em_chapter_set(void *video, int chapter __UNUSED__)
+em_chapter_set(void *video __UNUSED__, int chapter __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
 }
 
 static int
-em_chapter_get(void *video)
+em_chapter_get(void *video __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
-
    return 0;
 }
 
 static const char *
-em_chapter_name_get(void *video, int chapter __UNUSED__)
+em_chapter_name_get(void *video __UNUSED__, int chapter __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
-
    return NULL;
 }
 
 static void
-em_speed_set(void *video, double speed __UNUSED__)
+em_speed_set(void *video __UNUSED__, double speed __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
 }
 
 static double
-em_speed_get(void *video)
+em_speed_get(void *video __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
-
    return 1.0;
 }
 
 static int
-em_eject(void *video)
+em_eject(void *video __UNUSED__)
 {
-   Emotion_Gstreamer_Video *ev;
-
-   ev = (Emotion_Gstreamer_Video *)video;
-
    return 1;
 }
 
@@ -1305,7 +1235,6 @@ _for_each_tag(GstTagList const* list,
                    void *data)
 {
    Emotion_Gstreamer_Video *ev;
-   const GValue *val;
    int i;
    int count;
 
@@ -1315,7 +1244,6 @@ _for_each_tag(GstTagList const* list,
    if (!ev || !ev->metadata) return;
 
    count = gst_tag_list_get_tag_size(list, tag);
-   val = gst_tag_list_get_value_index(list, tag, 0);
 
    for (i = 0; i < count; i++)
      {
@@ -1438,10 +1366,8 @@ _em_buffer_read(void *data, void *buf, unsigned int nbyte __UNUSED__)
 {
    Emotion_Gstreamer_Video *ev;
    Emotion_Video_Sink      *vsink;
-   GstBuffer               *buffer;
 
    ev = (Emotion_Gstreamer_Video *)data;
-   buffer = *((GstBuffer **)buf);
    _emotion_frame_new(ev->obj);
    vsink = (Emotion_Video_Sink *)eina_list_nth(ev->video_sinks, ev->video_sink_nbr);
    if (vsink)
index d457abd..f489f85 100644 (file)
@@ -525,11 +525,8 @@ em_fps_num_get(void *ef)
 }
 
 static int
-em_fps_den_get(void *ef)
+em_fps_den_get(void *ef __UNUSED__)
 {
-   Emotion_Xine_Video *ev;
-   
-   ev = (Emotion_Xine_Video *)ef;
    return 10000;
 }
 
@@ -883,11 +880,8 @@ em_video_channel_get(void *ef)
 }
 
 static const char *
-em_video_channel_name_get(void *ef, int channel __UNUSED__)
+em_video_channel_name_get(void *ef __UNUSED__, int channel __UNUSED__)
 {
-   Emotion_Xine_Video *ev;
-   
-   ev = (Emotion_Xine_Video *)ef;
    return NULL;
 }
 
@@ -1072,45 +1066,30 @@ em_chapter_count(void *ef)
 }
 
 static void
-em_chapter_set(void *ef, int chapter __UNUSED__)
+em_chapter_set(void *ef __UNUSED__, int chapter __UNUSED__)
 {
-   Emotion_Xine_Video *ev;
-   
-   ev = (Emotion_Xine_Video *)ef;
 }
 
 static int
-em_chapter_get(void *ef)
+em_chapter_get(void *ef __UNUSED__)
 {
-   Emotion_Xine_Video *ev;
-   
-   ev = (Emotion_Xine_Video *)ef;
    return 0;
 }
 
 static const char *
-em_chapter_name_get(void *ef, int chapter __UNUSED__)
+em_chapter_name_get(void *ef __UNUSED__, int chapter __UNUSED__)
 {
-   Emotion_Xine_Video *ev;
-   
-   ev = (Emotion_Xine_Video *)ef;
    return NULL;
 }
 
 static void
-em_speed_set(void *ef, double speed __UNUSED__)
+em_speed_set(void *ef __UNUSED__, double speed __UNUSED__)
 {
-   Emotion_Xine_Video *ev;
-   
-   ev = (Emotion_Xine_Video *)ef;
 }
 
 static double
-em_speed_get(void *ef)
+em_speed_get(void *ef __UNUSED__)
 {
-   Emotion_Xine_Video *ev;
-   
-   ev = (Emotion_Xine_Video *)ef;
    return 1.0;
 }
 
@@ -1166,14 +1145,14 @@ _em_fd_active(void *data, Ecore_Fd_Handler *fdh)
    void *buf;
    int fd, len;
    Emotion_Xine_Video_Frame *fr;
-   Emotion_Xine_Video *ev;
    
-   ev = data;
    fd = ecore_main_fd_handler_fd_get(fdh);
    while ((len = read(fd, &buf, sizeof(buf))) > 0)
      {
        if (len == sizeof(buf))
          {
+            Emotion_Xine_Video *ev;
+
             fr = buf;
             ev = _emotion_video_get(fr->obj);
             if (ev)
@@ -1242,16 +1221,15 @@ _em_module_event(void *data, int type)
 static int
 _em_fd_ev_active(void *data, Ecore_Fd_Handler *fdh)
 {
-   Emotion_Xine_Video *ev;
    int fd, len;
    void *buf[2];
    
-   ev = data;
    fd = ecore_main_fd_handler_fd_get(fdh);
    while ((len = read(fd, buf, sizeof(buf))) > 0)
      {
        if (len == sizeof(buf))
          {
+            Emotion_Xine_Video *ev;
             Emotion_Xine_Event *eev;
             
             ev = buf[0];
@@ -1322,17 +1300,9 @@ _em_fd_ev_active(void *data, Ecore_Fd_Handler *fdh)
                         }
                       break;
                     case XINE_EVENT_FRAME_FORMAT_CHANGE:
-                        {
-                           xine_format_change_data_t *e;
-                           
-                           e = (xine_format_change_data_t *)eev->xine_event;
-                        }
                       break;
                     case XINE_EVENT_UI_MESSAGE:
                         {
-                           xine_ui_message_data_t *e;
-                           
-                           e = (xine_ui_message_data_t *)eev->xine_event;
                            printf("EV: UI Message [FIXME: break this out to emotion api]\n");
                            // e->type = error type(XINE_MSG_NO_ERROR, XINE_MSG_GENERAL_WARNING, XINE_MSG_UNKNOWN_HOST etc.)
                            // e->messages is a list of messages DOUBLE null terminated
@@ -1340,9 +1310,6 @@ _em_fd_ev_active(void *data, Ecore_Fd_Handler *fdh)
                       break;
                     case XINE_EVENT_AUDIO_LEVEL:
                         {
-                           xine_audio_level_data_t *e;
-                           
-                           e = (xine_audio_level_data_t *)eev->xine_event;
                            _emotion_audio_level_change(ev->obj);
                            printf("EV: Audio Level [FIXME: break this out to emotion api]\n");
                            // e->left (0->100) 
index 92f66eb..1053d18 100644 (file)
@@ -138,20 +138,14 @@ _emotion_class_dispose(video_driver_class_t *driver_class)
 }
 
 static char *
-_emotion_class_identifier_get(video_driver_class_t *driver_class)
+_emotion_class_identifier_get(video_driver_class_t *driver_class __UNUSED__)
 {
-   Emotion_Class *cl;
-   
-   cl = (Emotion_Class *)driver_class;
    return "emotion";
 }
 
 static char *
-_emotion_class_description_get(video_driver_class_t *driver_class)
+_emotion_class_description_get(video_driver_class_t *driver_class __UNUSED__)
 {
-   Emotion_Class *cl;
-   
-   cl = (Emotion_Class *)driver_class;
    return "Emotion xine video output plugin";
 }
 
@@ -203,33 +197,24 @@ _emotion_dispose(vo_driver_t *vo_driver)
 
 /***************************************************************************/
 static int
-_emotion_redraw(vo_driver_t *vo_driver)
+_emotion_redraw(vo_driver_t *vo_driver __UNUSED__)
 {
-   Emotion_Driver *dv;
-   
-   dv = (Emotion_Driver *)vo_driver;
 //   printf("emotion: _emotion_redraw()\n");
    return 0;
 }
 
 /***************************************************************************/
 static uint32_t
-_emotion_capabilities_get(vo_driver_t *vo_driver)
+_emotion_capabilities_get(vo_driver_t *vo_driver __UNUSED__)
 {
-   Emotion_Driver *dv;
-   
-   dv = (Emotion_Driver *)vo_driver;
 //   printf("emotion: _emotion_capabilities_get()\n");
    return VO_CAP_YV12 | VO_CAP_YUY2;
 }
 
 /***************************************************************************/
 static int
-_emotion_gui_data_exchange(vo_driver_t *vo_driver, int data_type, void *data __UNUSED__)
+_emotion_gui_data_exchange(vo_driver_t *vo_driver __UNUSED__, int data_type, void *data __UNUSED__)
 {
-   Emotion_Driver *dv;
-   
-   dv = (Emotion_Driver *)vo_driver;
 //   printf("emotion: _emotion_gui_data_exchange()\n");
    switch (data_type)
      {
@@ -292,11 +277,8 @@ _emotion_property_get(vo_driver_t *vo_driver, int property)
 }
 
 static void
-_emotion_property_min_max_get(vo_driver_t *vo_driver, int property __UNUSED__, int *min, int *max)
+_emotion_property_min_max_get(vo_driver_t *vo_driver __UNUSED__, int property __UNUSED__, int *min, int *max)
 {
-   Emotion_Driver *dv;
-   
-   dv = (Emotion_Driver *)vo_driver;
 //   printf("emotion: _emotion_property_min_max_get()\n");
    *min = 0;
    *max = 0;
@@ -304,12 +286,10 @@ _emotion_property_min_max_get(vo_driver_t *vo_driver, int property __UNUSED__, i
 
 /***************************************************************************/
 static vo_frame_t *
-_emotion_frame_alloc(vo_driver_t *vo_driver)
+_emotion_frame_alloc(vo_driver_t *vo_driver __UNUSED__)
 {
-   Emotion_Driver *dv;
    Emotion_Frame *fr;
    
-   dv = (Emotion_Driver *)vo_driver;
 //   printf("emotion: _emotion_frame_alloc()\n");
    fr = (Emotion_Frame *)calloc(1, sizeof(Emotion_Frame));
    if (!fr) return NULL;
@@ -445,7 +425,6 @@ _emotion_frame_display(vo_driver_t *vo_driver, vo_frame_t *vo_frame)
    if (dv->ev)
      {
        void *buf;
-       int ret;
 
        if (dv->ev->closing) return;
        if (fr->format == XINE_IMGFMT_YUY2)
@@ -458,7 +437,7 @@ _emotion_frame_display(vo_driver_t *vo_driver, vo_frame_t *vo_frame)
        fr->frame.done_func = _emotion_frame_data_unlock;
        fr->frame.done_data = fr;
 //     printf("FRAME FOR %p\n", dv->ev);
-       ret = write(dv->ev->fd_write, &buf, sizeof(void *));
+       write(dv->ev->fd_write, &buf, sizeof(void *));
 //     printf("-- FRAME DEC %p == %i\n", fr->frame.obj, ret);
        fr->in_use = 1;
        dv->ev->fq++;
@@ -468,11 +447,8 @@ _emotion_frame_display(vo_driver_t *vo_driver, vo_frame_t *vo_frame)
 }
 
 static void
-_emotion_frame_field(vo_frame_t *vo_frame, int which_field __UNUSED__)
+_emotion_frame_field(vo_frame_t *vo_frame __UNUSED__, int which_field __UNUSED__)
 {
-   Emotion_Frame *fr;
-   
-   fr = (Emotion_Frame *)vo_frame;
 //   printf("emotion: _emotion_frame_field()\n");
 }
 
@@ -510,34 +486,22 @@ _emotion_frame_data_unlock(Emotion_Frame *fr)
 
 /***************************************************************************/
 static void
-_emotion_overlay_begin(vo_driver_t *vo_driver, vo_frame_t *vo_frame, int changed __UNUSED__)
+_emotion_overlay_begin(vo_driver_t *vo_driver __UNUSED__, vo_frame_t *vo_frame __UNUSED__, int changed __UNUSED__)
 {
-   Emotion_Driver *dv;
-   Emotion_Frame *fr;
-   
-   dv = (Emotion_Driver *)vo_driver;
-   fr = (Emotion_Frame *)vo_frame;
 //   printf("emotion: _emotion_overlay_begin()\n");
 }
 
 static void
-_emotion_overlay_end(vo_driver_t *vo_driver, vo_frame_t *vo_frame)
+_emotion_overlay_end(vo_driver_t *vo_driver __UNUSED__, vo_frame_t *vo_frame __UNUSED__)
 {
-   Emotion_Driver *dv;
-   Emotion_Frame *fr;
-   
-   dv = (Emotion_Driver *)vo_driver;
-   fr = (Emotion_Frame *)vo_frame;
 //   printf("emotion: _emotion_overlay_end()\n");
 }
 
 static void
-_emotion_overlay_blend(vo_driver_t *vo_driver, vo_frame_t *vo_frame, vo_overlay_t *vo_overlay)
+_emotion_overlay_blend(vo_driver_t *vo_driver __UNUSED__, vo_frame_t *vo_frame, vo_overlay_t *vo_overlay __UNUSED__)
 {
-   Emotion_Driver *dv;
    Emotion_Frame *fr;
    
-   dv = (Emotion_Driver *)vo_driver;
    fr = (Emotion_Frame *)vo_frame;
 //   printf("emotion: _emotion_overlay_blend()\n");
    _emotion_overlay_blend_yuv(fr->vo_frame.base, vo_overlay,