[vlc-devel] [RFC] JS and libvlc mouse events

Jean-Paul Saman jpsaman at gmail.com
Mon Jan 25 15:25:44 CET 2010

2010/1/25 Rémi Denis-Courmont <remi at remlab.net>:
> On Mon, 25 Jan 2010 14:43:11 +0100, Jean-Paul Saman <jpsaman at videolan.org>
> wrote:
>> The first attached patches export mouse events from video output upto
>> the libvlc API level.
> The mouse coordinates are tied to the video track. It makes absolutely no
> sense to replicate them into libvlc.
> Also, the events are a bit silly. Double-clicks don't exist as such and
> shouldn't be exposed. There should be a event carrying the status of all
> buttons instead of click events. Mouse movement should be a single event
> with two coordinates, not two events.
> That said, I find the whole concept to be questionable. If you want to
> handle mouse events, set --no-mouse-events and let the windowing system
> send them to your parent window. As such, I fail to see why LibVLC would
> need to reinvent the wheel.

The caller needs to know where exactly a logo picture is located
inside VLC video output window. Therefor the mouse coordinates in VLC
video output should be obtained and returned to the event listener
which happen to be a JS callback function. The position of the mouse
against the desktop or browser window is irrelevant for this usage.

Instead of providing this generic mouse event solution it is possible
to export a 'logo-object-moved' event (and possible do that for all
video filters that support moving their object in the video output

Jean-Paul Saman

More information about the vlc-devel mailing list