Enlightenment CVS committal

Author  : moom16
Project : e17
Module  : libs/emotion

Dir     : e17/libs/emotion/src/lib


Modified Files:
        emotion_private.h emotion_smart.c 


Log Message:
* Cancel last changes since it seems there are some license problems.
Sorry guys, I didn't think GPLv2 was so "contaminating"


===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/emotion/src/lib/emotion_private.h,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -3 -r1.6 -r1.7
--- emotion_private.h   8 Jul 2005 19:56:46 -0000       1.6
+++ emotion_private.h   8 Jul 2005 20:28:50 -0000       1.7
@@ -15,16 +15,8 @@
 #define META_TRACK_YEAR 6
 #define META_TRACK_DISCID 7
 
-typedef enum _Emotion_Format Emotion_Format;
 typedef struct _Emotion_Video_Module Emotion_Video_Module;
 
-enum _Emotion_Format
-{
-   EMOTION_YV12,
-   EMOTION_YUY2,     /* unused for now since evas does not support yuy2 format 
*/
-   EMOTION_BGRA
-};
-
 struct _Emotion_Video_Module
 {
    unsigned char (*init) (Evas_Object *obj, void **video);
@@ -43,10 +35,8 @@
    int          (*audio_handled) (void *ef);
    int          (*seekable) (void *ef);
    void         (*frame_done) (void *ef);
-   Emotion_Format (*format_get) (void *ef);
-   void         (*video_data_size_get) (void *ef, int *w, int *h);
+   void         (*yuv_size_get) (void *ef, int *w, int *h);
    int          (*yuv_rows_get) (void *ef, int w, int h, unsigned char 
**yrows, unsigned char **urows, unsigned char **vrows);
-   int          (*bgra_data_get) (void *ef, unsigned char **bgra_data);
    void         (*event_feed) (void *ef, int event);
    void         (*event_mouse_button_feed) (void *ef, int button, int x, int 
y);
    void         (*event_mouse_move_feed) (void *ef, int x, int y);
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/emotion/src/lib/emotion_smart.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -3 -r1.13 -r1.14
--- emotion_smart.c     8 Jul 2005 19:56:47 -0000       1.13
+++ emotion_smart.c     8 Jul 2005 20:28:50 -0000       1.14
@@ -982,55 +982,42 @@
 static void
 _pixels_get(void *data, Evas_Object *obj)
 {
+   Evas_Pixel_Import_Source ps;
    int iw, ih, w, h;
+   int i;
+   unsigned char **rows;
    Smart_Data *sd;
-   Emotion_Format format;
 
    sd = data;
    evas_object_image_size_get(obj, &iw, &ih);
-   sd->module->video_data_size_get(sd->video, &w, &h);
+   sd->module->yuv_size_get(sd->video, &w, &h);
    if ((w != iw) || (h != ih))
      {
-       evas_object_image_size_set(obj, w, h);
-       iw = w;
-       ih = h;
+       evas_object_image_size_set(obj, w, h);
+       iw = w;
+       ih = h;
      }
-   format = sd->module->format_get(sd->video);
-   if (format == EMOTION_YV12)
-     {
-       unsigned char **rows;
-       Evas_Pixel_Import_Source ps;
-   
-       ps.format = EVAS_PIXEL_FORMAT_YUV420P_601;
-       ps.w = iw;
-       ps.h = ih;
-      
-       ps.rows = malloc(ps.h * 2 * sizeof(void *));
-       if (!ps.rows)
-         {
-           sd->module->frame_done(sd->video);
-           return;
-         }
+   ps.format = EVAS_PIXEL_FORMAT_YUV420P_601;
+   ps.w = iw;
+   ps.h = ih;
    
-       rows = (unsigned char **)ps.rows;
-      
-       if (sd->module->yuv_rows_get(sd->video, iw, ih,
-             rows, 
-            &rows[ps.h], 
-            &rows[ps.h + (ps.h / 2)]))
-         evas_object_image_pixels_import(obj, &ps);
-       evas_object_image_pixels_dirty_set(obj, 0);
-       free(ps.rows);
-   }
-   else if (format == EMOTION_BGRA)
+   ps.rows = malloc(ps.h * 2 * sizeof(void *));
+   if (!ps.rows)
      {
-       unsigned char *bgra_data;
-       if (sd->module->bgra_data_get(sd->video, &bgra_data));
-         {
-           evas_object_image_data_set(obj, bgra_data);
-         }
+       sd->module->frame_done(sd->video);
+       return;
      }
-
+   
+   
+   rows = (unsigned char **)ps.rows;
+   
+   if (sd->module->yuv_rows_get(sd->video, iw, ih,
+                               rows, 
+                               &rows[ps.h], 
+                               &rows[ps.h + (ps.h / 2)]))
+     evas_object_image_pixels_import(obj, &ps);
+   evas_object_image_pixels_dirty_set(obj, 0);
+   free(ps.rows);
    sd->module->frame_done(sd->video);
 }
 




-------------------------------------------------------
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