[vlc-commits] python bindings: define translation for uintptr_t* and update module
Olivier Aubert
git at videolan.org
Mon Apr 29 12:19:49 CEST 2013
vlc/python | branch: master | Olivier Aubert <contact at olivieraubert.net> | Mon Apr 29 12:17:57 2013 +0200| [d325f0a313af38310d0ba899915a4dfed3f02bbb] | committer: Olivier Aubert
python bindings: define translation for uintptr_t* and update module
This allows to wrap libvlc_log_get_object
> http://git.videolan.org/gitweb.cgi/vlc/python.git/?a=commit;h=d325f0a313af38310d0ba899915a4dfed3f02bbb
---
generate.py | 1 +
generated/vlc.py | 39 +++++++++++++++++++++++++++++++++++++--
2 files changed, 38 insertions(+), 2 deletions(-)
diff --git a/generate.py b/generate.py
index ffbc8be..76548ae 100755
--- a/generate.py
+++ b/generate.py
@@ -761,6 +761,7 @@ class PythonGenerator(_Generator):
'float': 'ctypes.c_float',
'int': 'ctypes.c_int',
'int*': 'ctypes.POINTER(ctypes.c_int)', # _video_get_cursor
+ 'uintptr_t*': 'ctypes.POINTER(ctypes.c_uint)',
'int64_t': 'ctypes.c_int64',
'short': 'ctypes.c_short',
'uint32_t': 'ctypes.c_uint32',
diff --git a/generated/vlc.py b/generated/vlc.py
index 556cce2..765afa7 100644
--- a/generated/vlc.py
+++ b/generated/vlc.py
@@ -48,7 +48,7 @@ import sys
from inspect import getargspec
__version__ = "N/A"
-build_date = "Mon Apr 1 23:47:38 2013"
+build_date = "Mon Apr 29 12:17:29 2013"
if sys.version_info[0] > 2:
str = str
@@ -3351,6 +3351,39 @@ def libvlc_event_type_name(event_type):
ctypes.c_char_p, ctypes.c_uint)
return f(event_type)
+def libvlc_log_get_context(ctx):
+ '''Gets debugging informations about a log message: the name of the VLC module
+ emitting the message and the message location within the source code.
+ The returned module name and file name will be NULL if unknown.
+ The returned line number will similarly be zero if unknown.
+ @param ctx: message context (as passed to the @ref libvlc_log_cb callback).
+ @return: module module name storage (or NULL), file source code file name storage (or NULL), line source code file line number storage (or NULL).
+ @version: LibVLC 2.1.0 or later.
+ '''
+ f = _Cfunctions.get('libvlc_log_get_context', None) or \
+ _Cfunction('libvlc_log_get_context', ((1,), (2,), (2,), (2,),), None,
+ None, Log_ptr, ListPOINTER(ctypes.c_char_p), ListPOINTER(ctypes.c_char_p), ctypes.POINTER(ctypes.c_uint))
+ return f(ctx)
+
+def libvlc_log_get_object(ctx, id):
+ '''Gets VLC object informations about a log message: the type name of the VLC
+ object emitting the message, the object header if any and a temporaly-unique
+ object identifier. These informations are mainly meant for B{manual}
+ troubleshooting.
+ The returned type name may be "generic" if unknown, but it cannot be NULL.
+ The returned header will be NULL if unset; in current versions, the header
+ is used to distinguish for VLM inputs.
+ The returned object ID will be zero if the message is not associated with
+ any VLC object.
+ @param ctx: message context (as passed to the @ref libvlc_log_cb callback).
+ @return: name object name storage (or NULL), header object header (or NULL), line source code file line number storage (or NULL).
+ @version: LibVLC 2.1.0 or later.
+ '''
+ f = _Cfunctions.get('libvlc_log_get_object', None) or \
+ _Cfunction('libvlc_log_get_object', ((1,), (2,), (2,), (1,),), None,
+ None, Log_ptr, ListPOINTER(ctypes.c_char_p), ListPOINTER(ctypes.c_char_p), ctypes.POINTER(ctypes.c_uint))
+ return f(ctx, id)
+
def libvlc_log_unset(p_instance):
'''Unsets the logging callback for a LibVLC instance. This is rarely needed:
the callback is implicitly unset when the instance is destroyed.
@@ -5827,7 +5860,7 @@ def libvlc_vlm_get_event_manager(p_instance):
# libvlc_printerr
# libvlc_set_exit_handler
-# 15 function(s) not wrapped as methods:
+# 17 function(s) not wrapped as methods:
# libvlc_audio_output_device_list_release
# libvlc_audio_output_list_release
# libvlc_clearerr
@@ -5838,6 +5871,8 @@ def libvlc_vlm_get_event_manager(p_instance):
# libvlc_get_changeset
# libvlc_get_compiler
# libvlc_get_version
+# libvlc_log_get_context
+# libvlc_log_get_object
# libvlc_media_tracks_release
# libvlc_module_description_list_release
# libvlc_new
More information about the vlc-commits
mailing list