From owner-freebsd-questions@FreeBSD.ORG Wed Jan 9 08:41:57 2008 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2D48916A41A for ; Wed, 9 Jan 2008 08:41:57 +0000 (UTC) (envelope-from boris@brooknet.com.au) Received: from smtp.po.exetel.com.au (pecan.exetel.com.au [220.233.0.17]) by mx1.freebsd.org (Postfix) with ESMTP id AF26113C469 for ; Wed, 9 Jan 2008 08:41:56 +0000 (UTC) (envelope-from boris@brooknet.com.au) Received: from 28.201.233.220.exetel.com.au ([220.233.201.28] helo=[192.168.100.148]) by smtp.po.exetel.com.au with esmtp (Exim 4.68) (envelope-from ) id 1JCWFc-0004d1-92; Wed, 09 Jan 2008 19:25:28 +1100 In-Reply-To: <1199835084.952.18.camel@polaris.admcs.wwu.edu> References: <1199835084.952.18.camel@polaris.admcs.wwu.edu> Mime-Version: 1.0 (Apple Message framework v753) Content-Type: text/plain; charset=WINDOWS-1252; delsp=yes; format=flowed Message-Id: Content-Transfer-Encoding: quoted-printable From: Sam Lawrance Date: Wed, 9 Jan 2008 19:26:06 +1100 To: Bob Finch X-Mailer: Apple Mail (2.753) Cc: freebsd-questions@freebsd.org Subject: Re: Xorg 7.2 and FreeBSD 6.2-p5 VMWARE vmmouse problem X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 09 Jan 2008 08:41:57 -0000 On 09/01/2008, at 10:31 AM, Bob Finch wrote: > On 10/10/2007, at 17:00:22, Sam Lawrance wrote: >> On 10/07/2007, at 11:53 AM, Webster, Andrew wrote: > >>> Howdy, >>> >>> >>> >>> I was successfully able to get Xorg upgraded to 7.2 by just >>> installing them from scratch as opposed to trying to upgrading an >>> existing system, BUT I=92ve run into a problem=85 >>> >>> >>> >>> While running VMWare Server 1.0.3 with FreeBSD 6.2-p5 and Xorg 7.2, >>> the mouse pointer behaves very oddly. >>> >>> The pointer appears in the wrong place on the screen for where the >>> system actually thinks that it is. >>> >>> I=92m using the vmmouse driver part of the Xorg system, as the >>> regular mouse driver doesn=92t appear to work at all, unless some >>> settings are amiss. >>> >>> I really like the vmmouse drive because you can move the pointer in/ >>> out of the window as you do with regular windows guest OSes. >>> >>> >>> >>> Has anyone experienced similar problems and/ or know of a fix for >>> this? >>> >> >> Andrew, >> >> I just set up VMWare Fusion with FreeBSD and have a problem that >> might be related. Ascii art time: >> _____________ >> |_| | >> | | >> | | >> |___________| >> >> The pointer appears normally on the screen. However, clicking around >> the screen does not work except in a small area in the top left >> corner. Moving the mouse within this tiny corner seems to scale up >> and operate on the entire screen. Eg. if I click and drag across the >> tiny corner, I can see the selection appear across the entire =20 >> desktop. >> >> Is this similar to your issue? Did you find a resolution? > > Sam, > > I ran into this problem on FreeBSD 7.0 RC1 with Xorg 7.3 using the > VMWare mouse driver (vmmouse). > > Apparently, X server 1.4.0 in Xorg 7.3 no longer calls the =20 > conversion_proc > function in the mouse driver. The VMWare mouse driver depends on that > call to scale the mouse coordiates to the screen size. > > As a workaround, I fetched the x11-drivers/xf86-input-vmmouse port and > patched src/vmmouse.c by hand before installing it: > > bob polaris[9]: diff -u orig/xf86-input-vmmouse-12.4.3/src/=20 > vmmouse.c xf86-input-vmmouse-12.4.3/src/vmmouse.c > --- orig/xf86-input-vmmouse-12.4.3/src/vmmouse.c 2007-09-25 =20 > 16:11:47.000000000 -0700 > +++ xf86-input-vmmouse-12.4.3/src/vmmouse.c 2008-01-08 =20 > 14:58:59.000000000 -0800 > @@ -964,8 +964,11 @@ > VMMOUSE_INPUT_DATA vmmouseInput; > int ps2Buttons =3D 0; > int numPackets; > + VMMousePrivPtr mPriv; > + double factorX, factorY; > > pMse =3D pInfo->private; > + mPriv =3D pMse->mousePriv; > while((numPackets =3D VMMouseClient_GetInput(&vmmouseInput))){ > if (numPackets =3D=3D VMMOUSE_ERROR) { > VMMouseClient_Disable(); > @@ -990,6 +993,13 @@ > dy =3D vmmouseInput.Y; > dz =3D (char)vmmouseInput.Z; > dw =3D 0; > + > + /* X server 1.4.0 does not call VMMouseConvertProc() so we =20 > scale coordinates here */ > + factorX =3D ((double) screenInfo.screens[mPriv->screenNum]-=20 > >width) / (double) 65535; > + factorY =3D ((double) screenInfo.screens[mPriv->screenNum]-=20 > >height) / (double) 65535; > + dx =3D dx * factorX + 0.5; > + dy =3D dy * factorY + 0.5; > + > /* post an event */ > pMse->PostEvent(pInfo, buttons, dx, dy, dz, dw); > } Oh wow, I owe you a beer! Any idea why this does not affect everyone using vmware?