[vlc-commits] commit: python-vlc: fix video_get_size /	video_get_cursor overrides ( Olivier Aubert )
    git at videolan.org 
    git at videolan.org
       
    Tue Nov 16 14:29:34 CET 2010
    
    
  
vlc/python | branch: master | Olivier Aubert <olivier.aubert at liris.cnrs.fr> | Tue Nov 16 12:05:39 2010 +0100| [3ac0e1e0f5175a96bdc646addc1432e74eb43712] | committer: Olivier Aubert 
python-vlc: fix video_get_size / video_get_cursor overrides
> http://git.videolan.org/gitweb.cgi/vlc/python.git/?a=commit;h=3ac0e1e0f5175a96bdc646addc1432e74eb43712
---
 override.py |   10 ++--------
 1 files changed, 2 insertions(+), 8 deletions(-)
diff --git a/override.py b/override.py
index 4689888..9ab66e4 100644
--- a/override.py
+++ b/override.py
@@ -160,10 +160,7 @@ class MediaPlayer:
 
         @param num: video number (default 0)
         """
-        x, y = ctypes.c_ulong(), ctypes.c_ulong()  # or c_uint?
-        if libvlc_video_get_size(self, num, ctypes.byref(x), ctypes.byref(y)):
-            raise LibVLCException('invalid video number (%s)' % (num,))
-        return int(x.value), int(y.value)
+        return libvlc_video_get_size(self, num)
 
     def video_get_width(self, num=0):
         """Get the width of a video in pixels.
@@ -198,10 +195,7 @@ class MediaPlayer:
 
         @param num: video number (default 0)
         """
-        x, y = ctypes.c_long(), ctypes.c_long()  # or c_int?
-        if libvlc_video_get_cursor(self, num, ctypes.byref(x), ctypes.byref(y)):
-            raise LibVLCException('invalid video number (%s)' % (num,))
-        return int(x.value), int(y.value)
+        return libvlc_video_get_cursor(self, num)
 
 class MediaListPlayer:
     """Create a new MediaListPlayer instance.
    
    
More information about the vlc-commits
mailing list