[vlc-devel] [V2 PATCH 1/2] es_out: add ES_OUT_SET_VOUT_MOUSE_CALLBACKS
thomas at gllm.fr
Tue Jul 17 09:54:25 CEST 2018
On Mon, Jul 16, 2018, at 19:09, Rémi Denis-Courmont wrote:
> Le maanantaina 16. heinäkuuta 2018, 16.52.45 EEST Thomas Guillem a écrit :
> > > I reckon that conventionally, the VLC mouse event receiver saves the state
> > > (if it needs too), not the sender.
> > Demuxers won't be able to know when a new vout is restarted or created. So
> > the old mouse state that demuxers save can be invalid. That's why I prefer
> > to save the mouse state from the vout.
> If I have to designate an invalid state between the last event received by the
> demuxer, and the previous state of the video output, it would be the latter.
> In this specific corner case, it actually makes more sense to have the demuxer
> save the old state than the provide it. Otherwise, the demuxer will receive
> impossible events such as:
> - mouse button released that was not "never" pressed,
> - mouse button pressed that was already pressed,
> - mouse cursor moving from a position that it did not have.
> In other words, the demuxer does not care about the would-be state that it did
> not receive. It either cares about the difference between the previous and
> current, or only about the current state. I believe that Laurent's approach of
> saving the state where it's actually needed makes far more sense from
> reliability point of view.
OK, will do that.
And the vout will sent a NULL mouse when it is stopped to let demuxers handle this invalid state.
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
More information about the vlc-devel