Enlightenment CVS committal

Author  : ulisses
Project : e17
Module  : proto/python-efl

Dir     : e17/proto/python-efl/python-evas/evas


Modified Files:
        __init__.py evas.c_evas_object_image.pxi 
Added Files:
        evas_object_image_rotate.c 


Log Message:
Add support for rotating images.

Patch by Leonardo Sobral.

===================================================================
RCS file: /cvs/e/e17/proto/python-efl/python-evas/evas/__init__.py,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -3 -r1.16 -r1.17
--- __init__.py 3 Oct 2007 04:44:24 -0000       1.16
+++ __init__.py 15 Nov 2007 22:38:11 -0000      1.17
@@ -77,5 +77,9 @@
 EVAS_OBJECT_POINTER_MODE_AUTOGRAB = 0
 EVAS_OBJECT_POINTER_MODE_NOGRAB = 1
 
+EVAS_IMAGE_ROTATE_NONE = 0
+EVAS_IMAGE_ROTATE_90 = 1
+EVAS_IMAGE_ROTATE_180 = 2
+EVAS_IMAGE_ROTATE_270 = 3
 
 c_evas.init()
===================================================================
RCS file: 
/cvs/e/e17/proto/python-efl/python-evas/evas/evas.c_evas_object_image.pxi,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -3 -r1.13 -r1.14
--- evas.c_evas_object_image.pxi        13 Nov 2007 15:53:45 -0000      1.13
+++ evas.c_evas_object_image.pxi        15 Nov 2007 22:38:11 -0000      1.14
@@ -1,5 +1,16 @@
 # This file is included verbatim by c_evas.pyx
 
+## for rotate support
+cdef extern from "evas_object_image_rotate.h":
+    ctypedef enum Rotation:
+            ROTATE_NONE
+            ROTATE_90
+            ROTATE_180
+            ROTATE_270
+
+    void evas_object_image_rotate(Evas_Object *image, Rotation rotation)
+
+
 cdef int _data_size_get(Evas_Object *obj):
     cdef int stride, h, bpp, cspace, have_alpha
     stride = evas_object_image_stride_get(obj)
@@ -436,6 +447,9 @@
 
         def __set__(self, int value):
             self.colorspace_set(value)
+
+    def rotate(self, int rotation):
+        evas_object_image_rotate(self.obj, <Rotation>rotation)
 
     def reload(self):
         "Force reload of image data."



-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to