Enlightenment CVS committal

Author  : moom16
Project : e17
Module  : libs/emotion

Dir     : e17/libs/emotion/src/modules


Modified Files:
        emotion_xine.c emotion_xine.h 


Log Message:
* Have rewritten the yuy2->rgb converter to avoid license problems.
So now, emotion_xine supports yuy2-encoded movies (such as .wmv).

===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/emotion/src/modules/emotion_xine.c,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -3 -r1.23 -r1.24
--- emotion_xine.c      8 Jul 2005 20:28:50 -0000       1.23
+++ emotion_xine.c      8 Jul 2005 23:08:48 -0000       1.24
@@ -16,8 +16,10 @@
 static double em_ratio_get(void *ef);
 static int em_seekable(void *ef);
 static void em_frame_done(void *ef);
-static void em_yuv_size_get(void *ef, int *w, int *h);
+static Emotion_Format em_format_get(void *ef);
+static void em_video_data_size_get(void *ef, int *w, int *h);
 static int em_yuv_rows_get(void *ef, int w, int h, unsigned char **yrows, 
unsigned char **urows, unsigned char **vrows);
+static int em_bgra_data_get(void *ef, unsigned char **bgra_data);
 static void em_event_feed(void *ef, int event);
 static void em_event_mouse_button_feed(void *ef, int button, int x, int y);
 static void em_event_mouse_move_feed(void *ef, int x, int y);
@@ -544,8 +546,21 @@
      }
 }
 
+static Emotion_Format em_format_get(void *ef)
+{
+   Emotion_Xine_Video *ev;
+   Emotion_Xine_Video_Frame *fr;
+   
+   ev = (Emotion_Xine_Video *)ef;
+   fr = ev->cur_frame;
+
+   if (fr)
+     return fr->format;
+   return EMOTION_YV12;
+}
+
 static void
-em_yuv_size_get(void *ef, int *w, int *h)
+em_video_data_size_get(void *ef, int *w, int *h)
 {
    Emotion_Xine_Video *ev;
    Emotion_Xine_Video_Frame *fr;
@@ -583,6 +598,23 @@
    return 0;
 }
 
+static int
+em_bgra_data_get(void *ef, unsigned char **bgra_data)
+{
+   Emotion_Xine_Video *ev;
+   Emotion_Xine_Video_Frame *fr;
+   
+   ev = (Emotion_Xine_Video *)ef;
+   fr = ev->cur_frame;
+   if (!fr) return 0;
+   if (fr->bgra_data)
+     {
+   *bgra_data = fr->bgra_data;
+       return 1;
+     }
+   return 0;
+}
+
 static void
 em_event_feed(void *ef, int event)
 {
@@ -1337,8 +1369,10 @@
      em_audio_handled, /* audio_handled */
      em_seekable, /* seekable */
      em_frame_done, /* frame_done */
-     em_yuv_size_get, /* yuv_size_get */
+     em_format_get, /* format_get */
+     em_video_data_size_get, /* video_data_size_get */
      em_yuv_rows_get, /* yuv_rows_get */
+     em_bgra_data_get, /* bgra_data_get */
      em_event_feed, /* event_feed */
      em_event_mouse_button_feed, /* event_mouse_button_feed */
      em_event_mouse_move_feed, /* event_mouse_move_feed */
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/emotion/src/modules/emotion_xine.h,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -3 -r1.10 -r1.11
--- emotion_xine.h      8 Jul 2005 20:28:50 -0000       1.10
+++ emotion_xine.h      8 Jul 2005 23:08:48 -0000       1.11
@@ -57,7 +57,9 @@
 {
    int            w, h;
    double         ratio;
+   Emotion_Format format;
    unsigned char *y, *u, *v;
+   unsigned char *bgra_data;
    int            y_stride, u_stride, v_stride;
    Evas_Object   *obj;
    double         timestamp;




-------------------------------------------------------
This SF.Net email is sponsored by the 'Do More With Dual!' webinar happening
July 14 at 8am PDT/11am EDT. We invite you to explore the latest in dual
core and dual graphics technology at this free one hour event hosted by HP,
AMD, and NVIDIA.  To register visit http://www.hp.com/go/dualwebinar
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to