[MPlayer-dev-eng] [PATCH] support -mouse-movements on OS/2
Reimar Döffinger
Reimar.Doeffinger at gmx.de
Thu Feb 27 09:06:18 CET 2014
On 27.02.2014, at 08:23, KO Myung-Hun <komh78 at gmail.com> wrote:
> Hi/2.
>
> Reimar Döffinger wrote:
>> On Sun, Feb 23, 2014 at 11:12:05PM +0900, KO Myung-Hun wrote:
>>> Hi/2.
>>>
>>> This patch add -mouse-movements support to OS/2.
>>>
>>> --
>>> KO Myung-Hun
>>>
>>> Using Mozilla SeaMonkey 2.7.2
>>> Under OS/2 Warp 4 for Korean with FixPak #15
>>> In VirtualBox v4.1.28 on Intel Core i7-3615QM 2.30GHz with 8GB RAM
>>>
>>> Korean OS/2 User Community : http://www.ecomstation.co.kr
>>>
>>
>>> Index: libvo/vo_kva.c
>>> ===================================================================
>>> --- libvo/vo_kva.c (revision 36900)
>>> +++ libvo/vo_kva.c (working copy)
>>> @@ -479,6 +573,32 @@
>>>
>>> return (MRESULT)TRUE;
>>>
>>> + case WM_MOUSEMOVE:
>>> + {
>>> + int x = SHORT1FROMMP(mp1);
>>> + int y = SHORT2FROMMP(mp1);
>>> +
>>> + RECTL rclDst;
>>> +
>>> + // get a current movie area
>>> + kvaAdjustDstRect(&m_int.kvas.rclSrcRect, &rclDst);
>>> +
>>> + // offset to movie area
>>> + x -= rclDst.xLeft;
>>> + y -= rclDst.yBottom;
>>> +
>>> + // rescale to image coordinate
>>> + x = x * vo_dwidth / (rclDst.xRight - rclDst.xLeft);
>>> + y = y * vo_dheight / (rclDst.yTop - rclDst.yBottom);
>>> +
>>
>> This looks wrong, all of this should be handled by
>> rescale_input_coordinates in command.c
>
> Ok.
>
>> I suspect this might be related to the missing panscan
>> support and aspect handling that differs from normal
>> MPlayer.
>
> I have a question. Is there a way to set a movie position relative a
> window ? What are vo_dx and vo_dy ?
Hm, the problem is I usually use none of these directly, but through the various helper functions.
I think vo_dx/vo_dy specify where the window should be on screen (compare -geometry).
I think vo_panscan_x/y should be specifying an additional offset inside the window. Note: _additional_, i.e. over what you get from centering according to aspect() scaling.
> And not related this thread, currently dvdnav:// shows a white
> rectangular cursor on OS/2. But on Windows, it shows a selected item
> with some marks. Where should I look into ?
This tends to happen when the proper subtitle stream does not get selected (the marks come from a vobsub stream). Sometimes read errors or seeking can cause this effect, I wouldn't know how this could happen as an OS-specific thing though...
More information about the MPlayer-dev-eng
mailing list