python-vlc
python-vlc copied to clipboard
Properly convert union declaration into python/ctypes
unions are not really handled for the moment:
https://github.com/oaubert/python-vlc/blob/master/generator/generate.py#L1045
It concerns for the moment 4 structures: libvlc_event_t, libvlc_video_setup_device_info_t, libvlc_video_output_cfg_t and libvlc_media_track_t (referenced in #222)
The first case (libvlc_event_t) has been addressed by defining explicit python code conversion into the generator/templates/override.py (EventUnion class). But this is fragile and dependent on original code updates. A better approach would be to properly handle unions in the generator code.