Closed mss555 closed 3 years ago
Thanks, I fixed the missing parameter. get_chapter_count() returns the correct value (17) only after the player is started (even it the media itself is parsed()). This looks like a libvlc shortcoming, you could report it on forum.videolan.org
Hello all,
I'm unable to access the chapter information stored in https://drive.google.com/file/d/1ArYCVA9KNH7kMsBsdMrfSp33SsgkDJL0/view?usp=drive_web using the python3-vlc Debian package included in Ubuntu 21.04.
The first issue is simple to fix:
File "/usr/lib/python3/dist-packages/vlc.py", line 3390, in get_full_chapter_descriptions n = libvlc_media_player_get_full_chapter_descriptions(self, ctypes.byref(chapterDescription_pp)) TypeError: libvlc_media_player_get_full_chapter_descriptions() missing 1 required positional argument: 'pp_chapters'
The get_full_chapter_descriptions() function is simply not passing through the i_chapters_of_title parameter to libvlc_media_player_get_full_chapter_descriptions().
After fixing that, libvlc_media_player_get_full_chapter_descriptions() returns -1 for n, though, which indicates an error.
Calling get_chapter_count() on this video, I get 0. But jumping to chapter 3 with set_chapter(3) works fine and if I read back the current chapter with get_chapter() immediately afterwards, it correctly reports 3.
A return value of 0 for get_chapter_count() might explain why ibvlc_media_player_get_full_chapter_descriptions() returns -1 so this might be the first issue to figure out.
Thanks, Marc