WineHQ
Bug Tracking Database – Bug 20395

 Bugzilla

 

Last modified: 2013-11-15 09:01:11 UTC  

Mouse / keyboard input not handled (RawInput)

Bug 20395 - Mouse / keyboard input not handled (RawInput)
Mouse / keyboard input not handled (RawInput)
Status: CLOSED FIXED
AppDB: Show Apps affected by this bug
Product: Wine
Classification: Unclassified
Component: user32
1.1.31
x86 other
: P2 normal
: ---
Assigned To: Mr. Bugs
: download
: 21330 22123 22655 23624 24403 24681 24712 24883 24955 25326 25632 25654 26557 27080 27224 27421 27551 29370 29564 29917 31267 31337 31607 (view as bug list)
Depends on:
Blocks:
  Show dependency tree
 
Reported: 2009-10-17 07:15 UTC by Warren Dumortier
Modified: 2013-11-15 09:01 UTC (History)
84 users (show)

See Also:
Regression SHA1:
Fixed by SHA1: c6fcc0255c3e7a655b157d1e68e5c80fe328bdf2
Distribution: ---
Staged patchset:


Attachments
Wolfenstein (2009) MP log: user32 channel (1.18 KB, text/plain)
2009-10-17 07:16 UTC, Warren Dumortier
Details
Wolfenstein (2009) MP log: x11drv channel (11.01 KB, application/gzip)
2009-10-17 07:16 UTC, Warren Dumortier
Details
ArmA 2 WINEDEBUG=-d3d_shader,-d3d_draw,-d3d,-d3d_surface,-d3d_texture wine arma2.exe (1.66 KB, text/plain)
2010-07-19 17:06 UTC, Luke Bratch
Details
Raw Input patch (10.95 KB, patch)
2011-03-02 15:32 UTC, Denis Misiurca
Details | Diff
Raw input hack updated for wine 1.3.15 (10.87 KB, patch)
2011-03-08 23:46 UTC, Denis Misiurca
Details | Diff
wine diff for raw input to git 03.08.11 17:37 (81.29 KB, patch)
2011-08-04 12:02 UTC, Manuel Bellersen
Details | Diff
Raw Input patch 8-8-2011 (97.49 KB, patch)
2011-08-07 23:31 UTC, David Parrish
Details | Diff
Log of "cat ../wine_rawinput_8_8_2011.patch | patch -Np1 --no-backup-if-mismatch &> ../wine_rawinput_8_8_2011.patch.log" and rejects. (5.32 KB, application/x-gzip)
2011-10-17 09:40 UTC, hash
Details
Build log of current Wine git and patch from http://dl.dropbox.com/u/6901628/raw3.patch. (86.33 KB, application/x-bzip2)
2011-10-17 10:46 UTC, hash
Details
Diff of manual merge of previous patch into WINE 1.3.32. (97.20 KB, patch)
2011-11-27 08:22 UTC, Richard
Details | Diff
Updated raw input mouse patch (works with Wine Git 1.3.35) (96.56 KB, patch)
2011-12-23 16:52 UTC, Robert Walker
Details | Diff
ARMA 2: output of user32 channel with RawInput grepped during loading screen crash (4.51 KB, text/plain)
2012-05-07 21:20 UTC, Zack Powers
Details
Previous raw input patch for Wine 1.5.9 (97.45 KB, patch)
2012-07-20 16:20 UTC, Martin Madsen
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Warren Dumortier 2009-10-17 07:15:09 UTC
The game runs fine (good framerates), however the game (MP part) is unplayable because the game doesn't react at all to mouse movements. The mouse is however working in the menu.

After debugging the user32 channel, i found this:
fixme:win:RegisterRawInputDevices (pRawInputDevices=0x229eb74, uiNumDevices=1, cbSize=12) stub!

Maybe this stub is the problem, i tried the patch from bug #10318, however it didn't fix the problem.

I'll attach the 2 debug logs, the first one with +user32 and the second with +x11drv.
Comment 1 Warren Dumortier 2009-10-17 07:16:21 UTC
Created attachment 24192 [details]
Wolfenstein (2009) MP log: user32 channel
Comment 2 Warren Dumortier 2009-10-17 07:16:55 UTC
Created attachment 24193 [details]
Wolfenstein (2009) MP log: x11drv channel
Comment 3 Vitaliy Margolen 2009-10-17 11:48:28 UTC
> fixme:win:RegisterRawInputDevices (pRawInputDevices=0x229eb74, uiNumDevices=1, cbSize=12) stub!
This indicates it's trying to use rawinput which is 100% stubbed on Wine. Try setting win version to win2k.
Comment 4 Warren Dumortier 2009-10-17 11:53:25 UTC
(In reply to comment #3)
> > fixme:win:RegisterRawInputDevices (pRawInputDevices=0x229eb74, uiNumDevices=1, cbSize=12) stub!
> This indicates it's trying to use rawinput which is 100% stubbed on Wine. Try
> setting win version to win2k.

Same problem with Windows version set to win2k. So this is the problem if i understand? However the hack from the bug didn't solve it, is it really the problem then?
Comment 5 Pavel 2009-11-27 11:31:42 UTC
Same problem on Debian 5.0.3, Wine 1.1.33.
Single Player's great, but in multiplayer the game doesn't catch mouse movements, although I can shoot and zoom (mouse1 and mouse2 buttons). In menu mouse works ok.
Comment 6 Warren Dumortier 2009-11-27 14:12:01 UTC
I don't have any idea in how mouse input works, but wouldn't it be possible to wrap raw mouse input using the current mouse handling? It wouldn't be really mouse input, does that make any sense? It would be more a hack then :)
Comment 7 Vitaliy Margolen 2009-11-27 17:21:41 UTC
It's not that easy. MS keeps creating API that's newer do what you need, no one can understand, no one knows how to use it right, and there are already several APIs that seems to do exactly the same thing.

RawInput is yet another DInput like interface but without all the device configuration craft, only it can intercept all events before the they hit user layer and generate all associated messages. For Wine that means this will have to be done in wineserver with extensive testing to be sure nothing broke. It will need a separate RawInput queue since events are buffered and then returned one or many at a time.
Comment 8 Vitaliy Margolen 2010-01-12 19:53:15 UTC
*** Bug 21330 has been marked as a duplicate of this bug. ***
Comment 9 Andrew Nguyen 2010-03-22 13:58:30 UTC
*** Bug 22123 has been marked as a duplicate of this bug. ***
Comment 10 Vitaliy Margolen 2010-07-12 20:33:45 UTC
*** Bug 23624 has been marked as a duplicate of this bug. ***
Comment 11 Luke Bratch 2010-07-19 17:06:11 UTC
Created attachment 29714 [details]
ArmA 2 WINEDEBUG=-d3d_shader,-d3d_draw,-d3d,-d3d_surface,-d3d_texture wine arma2.exe

Mouse clicking does not work in ArmA 2 either, does the attached indicate the same problem as this bug?
Comment 12 Denis Misiurca 2011-03-02 15:32:00 UTC
Created attachment 33506 [details]
Raw Input patch

This patch is based on a Hellgate raw input patch from Bug #10318

It was modified to work with Black Prophecy and latest wine (1.3.14 atm).

With original patch the crosschair was jumping to screen corners just after any mouse movement.
Comment 13 Denis Misiurca 2011-03-08 23:46:38 UTC
Created attachment 33578 [details]
Raw input hack updated for wine 1.3.15

This is the previous patch updated to compile with wine 1.3.15.

It applies and compiles successfully, but does not work as well as in 1.3.14:

- Vertical crosschair movement is limited to the half of screen
- Mouse scroll is not working making impossible to change ship speed with mouse.
Comment 14 Austin English 2011-05-12 23:29:15 UTC
Also affects Brink. An updated patch is available at https://gist.github.com/895204#file_raw.patch and fixes the mouse there.
Comment 15 DL 2011-05-13 01:39:18 UTC
Patch doesn't work properly with Brink for me. Can only turn a very limited amount (less than 180 degrees).
Comment 16 Austin English 2011-05-13 16:58:10 UTC
(In reply to comment #15)
> Patch doesn't work properly with Brink for me. Can only turn a very limited
> amount (less than 180 degrees).

Wine version? I only tested in the menu, haven't been able to get in the game yet without hanging. That sounds like bug  6971 though, which is likely fixed in 1.3.20.
Comment 17 DL 2011-05-13 20:32:18 UTC
(In reply to comment #16)
> (In reply to comment #15)
> > Patch doesn't work properly with Brink for me. Can only turn a very limited
> > amount (less than 180 degrees).
> 
> Wine version? I only tested in the menu, haven't been able to get in the game
> yet without hanging. That sounds like bug  6971 though, which is likely fixed
> in 1.3.20.

Wine-1.3.19. I'll try the latest version. BTW, I needed native vcrun2008 to get in game.
Comment 18 DL 2011-05-13 21:26:35 UTC
Tried out wine-1.3.20 with the raw input hack, and mouse now works. Performance is pretty bad, though, especially considering it is an opengl game. Windows users have been complaining of bad performance too, so maybe a future patch will fix this.
Comment 19 DL 2011-05-13 21:40:40 UTC
A simple tweak, and performance is now quite decent:
1. Create autoexec.cfg in brink/base
2. Add r_useThreadedRenderer 2

Now that just leaves the audio problem (and steam DRM for multiplayer)
Comment 20 Austin English 2011-05-16 04:33:35 UTC
*** Bug 25326 has been marked as a duplicate of this bug. ***
Comment 21 Béla Gyebrószki 2011-05-29 13:53:07 UTC
This bug affects Quantz, too (an indie puzzle game): mouse works fine in the menus but in the main game you can't rotate the cube by moving the mouse: only mouse buttons work.

Native dinput8.dll or setting the Windows version to 2k don't help but the rawinput patch (comment #14) resolves the problem in the game.

In the terminal:
fixme:win:RegisterRawInputDevices (pRawInputDevices=0x3c6de00, uiNumDevices=1, cbSize=12) stub!

Quantz has a Windows demo (only 45 MB):
http://www.fileplanet.com/209688/200000/fileinfo/Quantz-Demo

Wine-1.3.21
Comment 22 Vitaliy Margolen 2011-05-30 17:08:24 UTC
*** Bug 22655 has been marked as a duplicate of this bug. ***
Comment 23 Vitaliy Margolen 2011-05-30 17:09:19 UTC
*** Bug 27080 has been marked as a duplicate of this bug. ***
Comment 24 Vitaliy Margolen 2011-05-30 17:10:32 UTC
*** Bug 25632 has been marked as a duplicate of this bug. ***
Comment 25 Vitaliy Margolen 2011-05-30 17:11:12 UTC
*** Bug 24883 has been marked as a duplicate of this bug. ***
Comment 26 Vitaliy Margolen 2011-05-30 17:11:48 UTC
*** Bug 24712 has been marked as a duplicate of this bug. ***
Comment 27 pantano.luigi 2011-06-12 06:39:11 UTC
I have the same problem in Rome Total War (Gold Version)
mouse works fine in the menus but in the main game you can't move the mouse: only mouse buttons work.
Comment 28 Austin English 2011-06-21 10:47:23 UTC
*** Bug 27421 has been marked as a duplicate of this bug. ***
Comment 29 DL 2011-06-22 05:59:41 UTC
I should note that although the raw input patch allows mouse input to work with Deus Ex Human Revolution (beta), keyboard input doesn't seem to work at all.
Is this an additional bug with wine, or an issue with the raw input patch?
Comment 30 Vincas Miliūnas 2011-06-25 12:20:54 UTC
I've developed raw input patch for WINE (still haven't received feedback from AJ how to improve it), it also has support for keyboard. To use it, download and apply http://source.winehq.org/patches/data/75581 http://source.winehq.org/patches/data/75582 patches, then run tools/make_requests script and compile.
Comment 31 DL 2011-06-25 20:41:48 UTC
(In reply to comment #30)
> I've developed raw input patch for WINE (still haven't received feedback from
> AJ how to improve it), it also has support for keyboard. To use it, download
> and apply http://source.winehq.org/patches/data/75581
> http://source.winehq.org/patches/data/75582 patches, then run
> tools/make_requests script and compile.

I tried the patch, but it doesn't compile with several error messages like this:

raw_input.c:119:10: error: dereferencing pointer to incomplete type
raw_input.c:120:15: error: dereferencing pointer to incomplete type
raw_input.c:120:35: error: dereferencing pointer to incomplete type
raw_input.c:123:26: error: dereferencing pointer to incomplete type
raw_input.c:137:26: error: dereferencing pointer to incomplete type
Comment 32 Vincas Miliūnas 2011-06-26 01:31:57 UTC
(In reply to comment #31)
> (In reply to comment #30)
> > I've developed raw input patch for WINE (still haven't received feedback from
> > AJ how to improve it), it also has support for keyboard. To use it, download
> > and apply http://source.winehq.org/patches/data/75581
> > http://source.winehq.org/patches/data/75582 patches, then run
> > tools/make_requests script and compile.
> 
> I tried the patch, but it doesn't compile with several error messages like
> this:

You didn't run the tools/make_requests script. It needs to update wineserver request definitions to compile.
Comment 33 DL 2011-06-26 09:07:03 UTC
(In reply to comment #32)
> 
> You didn't run the tools/make_requests script. It needs to update wineserver
> request definitions to compile.

Yeah, you're right about that. And with the patches, both keyboard and mouse works with Deus Ex : Human Revolution.
Comment 34 Austin English 2011-06-26 15:13:29 UTC
*** Bug 27551 has been marked as a duplicate of this bug. ***
Comment 35 LBM 2011-06-28 13:02:43 UTC
(In reply to comment #30)
> I've developed raw input patch for WINE (still haven't received feedback from
> AJ how to improve it), it also has support for keyboard. To use it, download
> and apply http://source.winehq.org/patches/data/75581
> http://source.winehq.org/patches/data/75582 patches, then run
> tools/make_requests script and compile.

First of all, great work! This seems to fix the input problems in ArmA 2.
Hope it doesn't break anything else and is included in the main dev tree soon.
Comment 36 K1773R 2011-07-02 04:36:08 UTC
(In reply to comment #35)
> (In reply to comment #30)
> > I've developed raw input patch for WINE (still haven't received feedback from
> > AJ how to improve it), it also has support for keyboard. To use it, download
> > and apply http://source.winehq.org/patches/data/75581
> > http://source.winehq.org/patches/data/75582 patches, then run
> > tools/make_requests script and compile.
> 
> First of all, great work! This seems to fix the input problems in ArmA 2.
> Hope it doesn't break anything else and is included in the main dev tree soon.

for wich wine version is this patch? greez
Comment 37 Vincas Miliūnas 2011-07-02 12:46:37 UTC
(In reply to comment #36)
> (In reply to comment #35)
> > (In reply to comment #30)
> > > I've developed raw input patch for WINE (still haven't received feedback from
> > > AJ how to improve it), it also has support for keyboard. To use it, download
> > > and apply http://source.winehq.org/patches/data/75581
> > > http://source.winehq.org/patches/data/75582 patches, then run
> > > tools/make_requests script and compile.
> > 
> > First of all, great work! This seems to fix the input problems in ArmA 2.
> > Hope it doesn't break anything else and is included in the main dev tree soon.
> 
> for wich wine version is this patch? greez

Use the newest version - http://dl.dropbox.com/u/6901628/raw.patch . The previous one failed to compile on 32bit gcc due to a missing include statement. It's rebased to apply on the latest git version but an older one should work as well.
Comment 38 K1773R 2011-07-02 14:02:24 UTC
(In reply to comment #37)
> (In reply to comment #36)
> > (In reply to comment #35)
> > > (In reply to comment #30)
> > > > I've developed raw input patch for WINE (still haven't received feedback from
> > > > AJ how to improve it), it also has support for keyboard. To use it, download
> > > > and apply http://source.winehq.org/patches/data/75581
> > > > http://source.winehq.org/patches/data/75582 patches, then run
> > > > tools/make_requests script and compile.
> > > 
> > > First of all, great work! This seems to fix the input problems in ArmA 2.
> > > Hope it doesn't break anything else and is included in the main dev tree soon.
> > 
> > for wich wine version is this patch? greez
> 
> Use the newest version - http://dl.dropbox.com/u/6901628/raw.patch . The
> previous one failed to compile on 32bit gcc due to a missing include statement.
> It's rebased to apply on the latest git version but an older one should work as
> well.

i tryd it with 1.3.20 and 1.3.23 (newest one), both failed at raw_input, too bad :(
Comment 39 Vincas Miliūnas 2011-07-02 14:14:59 UTC
(In reply to comment #38)
> (In reply to comment #37)
> > (In reply to comment #36)
> > > (In reply to comment #35)
> > > > (In reply to comment #30)
> > > > > I've developed raw input patch for WINE (still haven't received feedback from
> > > > > AJ how to improve it), it also has support for keyboard. To use it, download
> > > > > and apply http://source.winehq.org/patches/data/75581
> > > > > http://source.winehq.org/patches/data/75582 patches, then run
> > > > > tools/make_requests script and compile.
> > > > 
> > > > First of all, great work! This seems to fix the input problems in ArmA 2.
> > > > Hope it doesn't break anything else and is included in the main dev tree soon.
> > > 
> > > for wich wine version is this patch? greez
> > 
> > Use the newest version - http://dl.dropbox.com/u/6901628/raw.patch . The
> > previous one failed to compile on 32bit gcc due to a missing include statement.
> > It's rebased to apply on the latest git version but an older one should work as
> > well.
> 
> i tryd it with 1.3.20 and 1.3.23 (newest one), both failed at raw_input, too
> bad :(

Considering development releases, it will compile only with the 1.3.23, because it's the first release with raw input constants committed.

If you can't compile with 1.3.23 or the latest git, it's most likely that you have forgotten to run the ./tools/make_requests script after applying the patch, otherwise you will see errors like "dereferencing pointer to incomplete type".
Comment 40 K1773R 2011-07-02 15:15:19 UTC
(In reply to comment #39)
> (In reply to comment #38)
> > (In reply to comment #37)
> > > (In reply to comment #36)
> > > > (In reply to comment #35)
> > > > > (In reply to comment #30)
> > > > > > I've developed raw input patch for WINE (still haven't received feedback from
> > > > > > AJ how to improve it), it also has support for keyboard. To use it, download
> > > > > > and apply http://source.winehq.org/patches/data/75581
> > > > > > http://source.winehq.org/patches/data/75582 patches, then run
> > > > > > tools/make_requests script and compile.
> > > > > 
> > > > > First of all, great work! This seems to fix the input problems in ArmA 2.
> > > > > Hope it doesn't break anything else and is included in the main dev tree soon.
> > > > 
> > > > for wich wine version is this patch? greez
> > > 
> > > Use the newest version - http://dl.dropbox.com/u/6901628/raw.patch . The
> > > previous one failed to compile on 32bit gcc due to a missing include statement.
> > > It's rebased to apply on the latest git version but an older one should work as
> > > well.
> > 
> > i tryd it with 1.3.20 and 1.3.23 (newest one), both failed at raw_input, too
> > bad :(
> 
> Considering development releases, it will compile only with the 1.3.23, because
> it's the first release with raw input constants committed.
> 
> If you can't compile with 1.3.23 or the latest git, it's most likely that you
> have forgotten to run the ./tools/make_requests script after applying the
> patch, otherwise you will see errors like "dereferencing pointer to incomplete
> type".

oh well, i did this for the 1.3.20 but forget it to do it on the 1.3.23, my bad :)
great work!
Comment 41 Damian Ivanov 2011-07-03 14:08:17 UTC
If you are using openSUSE You can use my wine RPM, it include's this and some more hackish-style game-fixing patches to it. This patch is also included. If You have suggestions for other patches to be included feel free to contact me :)

http://download.opensuse.org/repositories/home:/damianator/

Cheers,
Damian
Comment 42 Damian Ivanov 2011-07-10 02:13:51 UTC
Bug still exists as of 1.3.24.
This patch no longer compiles with 1.3.24.
Comment 43 Manuel Bellersen 2011-08-04 04:52:09 UTC
I get the singleplayer with patches from http://hellgateaus.net/ and the demo running. No problems so far.

Also I get the new multiplayer http://hellgate.t3fun.com/home/home.aspx
running but when I'm inside the game (inside a station) and try to move or look around I get disconnected.
Anybody got it working and could play?
Comment 44 David Parrish 2011-08-04 10:06:28 UTC
For HellGate London(In reply to comment #43)
> Also I get the new multiplayer http://hellgate.t3fun.com/home/home.aspx
> running but when I'm inside the game (inside a station) and try to move or look
> around I get disconnected.
> Anybody got it working and could play?
I could not play and I didn't get as far as you did.  I am running wine version 1.3.25 on Ubuntu 11.04.  I didn't patch but I did use the Ubuntu PPA.  I get 

Minimum System Requirements Not Met
This application requires a CPU speed of at least 990 MHz (0.9GHz).
Your detected CPU speed is 0 MHz (0.0 GHz). Check that any
power-saving options are set to the maximum performance mode. The
application will proceed, but performance may be adversel

when I start from the HellGate loader.

The game then starts but the video is slow and choppy.  When the menu starts it looks fine but video is still choppy.  I can navigate the menu with the keyboard but the mouse does not work at all.  The cursor is in the middle of the screen and does not move.
Comment 45 Manuel Bellersen 2011-08-04 12:02:06 UTC
Created attachment 35806 [details]
wine diff for raw input to git 03.08.11 17:37

It is patch http://bugs.winehq.org/show_bug.cgi?id=20395#c37 applied to wine git master from 03.08.11 17:37
Comment 46 Manuel Bellersen 2011-08-04 12:17:32 UTC
(In reply to comment #44)
> For HellGate London(In reply to comment #43)
> > Also I get the new multiplayer http://hellgate.t3fun.com/home/home.aspx
> > running but when I'm inside the game (inside a station) and try to move or look
> > around I get disconnected.
> > Anybody got it working and could play?
> I could not play and I didn't get as far as you did.  I am running wine version
> 1.3.25 on Ubuntu 11.04.  I didn't patch but I did use the Ubuntu PPA.  I get 
> 
> Minimum System Requirements Not Met
> This application requires a CPU speed of at least 990 MHz (0.9GHz).
> Your detected CPU speed is 0 MHz (0.0 GHz). Check that any
> power-saving options are set to the maximum performance mode. The
> application will proceed, but performance may be adversel
> 
> when I start from the HellGate loader.
> 
> The game then starts but the video is slow and choppy.  When the menu starts it
> looks fine but video is still choppy.  I can navigate the menu with the
> keyboard but the mouse does not work at all.  The cursor is in the middle of
> the screen and does not move.


You need to build wine from source and apply the patch from
http://bugs.winehq.org/show_bug.cgi?id=20395#c37 to it. I applied it to current
master from 03.08.2011 17:37 and made a diff from it again:
http://bugs2.winehq.org/attachment.cgi?id=35806

The 0MHz is normal and won't disappear with this patch.

With the patch applied the mouse should work and then login and other things
should work without problem.


You can also try the package from
http://bugs.winehq.org/show_bug.cgi?id=20395#c41
It is a rpm, so for Ubuntu you need to use alien to convert it to a deb:
    sudo alien wine-1.3.25-22.6.x86_64.rpm
or
    sudo alien wine-32bit-1.3.25-22.6.i586.rpm 
or whatever you are using or could be using.

It should create some equal file with deb at the and which you could install
normally.
But I don't guaranty on anything ...
Comment 47 David Parrish 2011-08-07 23:31:50 UTC
Created attachment 35873 [details]
Raw Input patch 8-8-2011
Comment 48 David Parrish 2011-08-07 23:36:07 UTC
Comment on attachment 35873 [details]
Raw Input patch 8-8-2011

Manuel, Thanks for the help.  I was able to compile my own version with the
raw_input patch.  My git diff came out a little different than yours though. 
For one thing, I was missing both the raw_input.c and raw_input.h.

Unfortunately, I also get disconnected when I am in the game.  It seems like
whenever I try to shot anything I immediately get disconnected.  I think this
must be a separate issue for HellGate London.
Comment 49 Damian Ivanov 2011-08-08 23:21:42 UTC
(In reply to comment #46)
> (In reply to comment #44)
> > For HellGate London(In reply to comment #43)
> > > Also I get the new multiplayer http://hellgate.t3fun.com/home/home.aspx
> > > running but when I'm inside the game (inside a station) and try to move or look
> > > around I get disconnected.
> > > Anybody got it working and could play?
> > I could not play and I didn't get as far as you did.  I am running wine version
> > 1.3.25 on Ubuntu 11.04.  I didn't patch but I did use the Ubuntu PPA.  I get 
> > 
> > Minimum System Requirements Not Met
> > This application requires a CPU speed of at least 990 MHz (0.9GHz).
> > Your detected CPU speed is 0 MHz (0.0 GHz). Check that any
> > power-saving options are set to the maximum performance mode. The
> > application will proceed, but performance may be adversel
> > 
> > when I start from the HellGate loader.
> > 
> > The game then starts but the video is slow and choppy.  When the menu starts it
> > looks fine but video is still choppy.  I can navigate the menu with the
> > keyboard but the mouse does not work at all.  The cursor is in the middle of
> > the screen and does not move.
> 
> 
> You need to build wine from source and apply the patch from
> http://bugs.winehq.org/show_bug.cgi?id=20395#c37 to it. I applied it to current
> master from 03.08.2011 17:37 and made a diff from it again:
> http://bugs2.winehq.org/attachment.cgi?id=35806
> 
> The 0MHz is normal and won't disappear with this patch.
> 
> With the patch applied the mouse should work and then login and other things
> should work without problem.
> 
> 
> You can also try the package from
> http://bugs.winehq.org/show_bug.cgi?id=20395#c41
> It is a rpm, so for Ubuntu you need to use alien to convert it to a deb:
>     sudo alien wine-1.3.25-22.6.x86_64.rpm
> or
>     sudo alien wine-32bit-1.3.25-22.6.i586.rpm 
> or whatever you are using or could be using.
> 
> It should create some equal file with deb at the and which you could install
> normally.
> But I don't guaranty on anything ...

Yes this here is not the right place for it, sorry no other place where people using wine look that often like in bugzilla :)

If somebody cares my suse package is updated to wine 1.3.26 and also use the patches fixing:
vertblend-bug6955 
rawEvents-bug20395  
popsot_hack-bug17423  
ole-force-inproc-not-local-bug20296	 
dxt-bug15984_14939  
bug201
bug15984
audible_wine-bug16831  
3gbuserspace-bug13335

and integrates ImplementSetThreadPriority and hook-dll-reference patches.

Cheers
Comment 50 Mikko Saarinen 2011-08-13 14:03:10 UTC
World of Tanks also suffers from this.

Otherwise the game plays great but mouse doesn't work (works in the menu list, but not anywhere else). In-game only mouse button (fires cannon) works, but not the mouse movement (which rotates turret).

Please fix this asap, please!!!
Comment 51 Vincas Miliūnas 2011-08-13 14:09:18 UTC
(In reply to comment #50)
> World of Tanks also suffers from this.
> 
> Otherwise the game plays great but mouse doesn't work (works in the menu list,
> but not anywhere else). In-game only mouse button (fires cannon) works, but not
> the mouse movement (which rotates turret).
> 
> Please fix this asap, please!!!

By following the "How to get the latest WINE's git working" instructions on the AppDB page for WoT, you can build a modification of WINE that will make the game playable - http://appdb.winehq.org/objectManager.php?sClass=version&iId=22521
Comment 52 Austin English 2011-08-15 12:31:28 UTC
*** Bug 25654 has been marked as a duplicate of this bug. ***
Comment 53 Daniel 2011-09-03 13:14:51 UTC
attachment 35873 [details] Seem to get the mouse input for Onlive working, but the pointer seems jerky within the menus and occasionally will only move the camera 180°. Any ideas? I'll try and get output the next time it happens.
Comment 54 Austin English 2011-09-05 14:50:10 UTC
(In reply to comment #53)
> attachment 35873 [details] Seem to get the mouse input for Onlive working, but the
> pointer seems jerky within the menus and occasionally will only move the camera
> 180°. Any ideas? I'll try and get output the next time it happens.

Mouse/touchpad? X version? Are you disabling xinput2?
Comment 55 Ezequiel 2011-09-13 15:22:17 UTC
Wolfenstein is affected by this bug in 1.3.28, so is not fixed yet.
Comment 56 Ivan 2011-09-18 07:05:22 UTC
This bug probably affects "Hard reset". You can click with mouse, but you can't navigate with mouse in the game.
Comment 57 zdenek.styblik 2011-09-25 13:11:45 UTC
I would like to confirm patch 2011/Aug/08 works with 1.3.29 and Deus Ex: Human Revolution. At least as far as menu goes as game crashes afterwards.
Comment 58 hash 2011-10-17 09:40:57 UTC
Created attachment 36947 [details]
Log of "cat ../wine_rawinput_8_8_2011.patch | patch -Np1 --no-backup-if-mismatch &> ../wine_rawinput_8_8_2011.patch.log" and rejects.

I've hoped to play Hellgate:London with current Wine git.
After patching got 3 rejects.
Logs of patching process and rejects in attached archive.
If any one interested and/or can do anything about it.
Comment 59 malic 2011-10-17 09:48:31 UTC
Anarchy Online mouse look still ain't working with 1.3.30
Patch from bug 25654 ain't working anymore.
Comment 60 Vincas Miliūnas 2011-10-17 10:06:04 UTC
(In reply to comment #58)
> Created attachment 36947 [details]
> Log of "cat ../wine_rawinput_8_8_2011.patch | patch -Np1
> --no-backup-if-mismatch &> ../wine_rawinput_8_8_2011.patch.log" and rejects.
> 
> I've hoped to play Hellgate:London with current Wine git.
> After patching got 3 rejects.
> Logs of patching process and rejects in attached archive.
> If any one interested and/or can do anything about it.

Please apply the original patch - http://dl.dropbox.com/u/6901628/raw3.patch and afterwards execute ./tools/make_requests script. These instructions are also available at http://appdb.winehq.org/objectManager.php?sClass=version&iId=22521 , in the entry "How to get the latest WINE's git working".

The person who attached the patch decided to combine raw input patch with the results of ./tools/make_requests script and that is not a good practice, thus (as you claimed) the attached patch is currently broken.
Comment 61 hash 2011-10-17 10:46:51 UTC
Created attachment 36952 [details]
Build log of current Wine git and patch from http://dl.dropbox.com/u/6901628/raw3.patch.

Applied raw3.patch and executed ./tools/make_requests script.
Build failed, log attached.
Comment 62 Vincas Miliūnas 2011-10-17 10:54:53 UTC
(In reply to comment #61)
> Created attachment 36952 [details]
> Build log of current Wine git and patch from
> http://dl.dropbox.com/u/6901628/raw3.patch.
> 
> Applied raw3.patch and executed ./tools/make_requests script.
> Build failed, log attached.

You need to apply the patch on a clean WINE git, please follow the instructions in the appdb link.
Comment 63 malic 2011-10-17 11:30:00 UTC
(In reply to comment #62)
> (In reply to comment #61)
> > Created attachment 36952 [details]
> > Build log of current Wine git and patch from
> > http://dl.dropbox.com/u/6901628/raw3.patch.
> > 
> > Applied raw3.patch and executed ./tools/make_requests script.
> > Build failed, log attached.
> 
> You need to apply the patch on a clean WINE git, please follow the instructions
> in the appdb link.

Anarchy Online is partly affected by the patch :
- left button mouse look is working
- right button mousse look is only working on Y-axis
Comment 64 hash 2011-10-18 01:27:46 UTC
Thank you Vincas Miliūnas for persistent and patience with me.
Before, I rebuild Wine with only "git diff | patch -Rp1" and "git checkout -f && git fetch && git rebase origin" and this obviously wasn't enough.
After changing that to:
git clean -fd
git checkout -f && git fetch && git rebase origin
git reset --hard origin/master
git reset --hard HEAD
all compiled well and mouse works right as it should in Hellgate: London.
Only thing left, is I need to do "git reset --hard origin/master" and "git reset --hard HEAD" or are thous somewhat redundant?
Comment 65 Ezequiel 2011-10-18 05:36:28 UTC
(In reply to comment #59)
> Anarchy Online mouse look still ain't working with 1.3.30
> Patch from bug 25654 ain't working anymore.

Wolfenstein is still broken in 1.3.30 too.
Comment 66 Vincas Miliūnas 2011-10-18 05:40:34 UTC
(In reply to comment #64)
>Thank you Vincas Miliūnas for persistent and patience with me.
No need to thank me, just informing people how to get raw input working in WINE.
> Before, I rebuild Wine with only "git diff | patch -Rp1" and "git checkout -f
> && git fetch && git rebase origin" and this obviously wasn't enough.
There are two new files (raw_input.c/.h) being added by the patch, to remove them you also need to add command git clean -f.
> Only thing left, is I need to do "git reset --hard origin/master" and "git
> reset --hard HEAD" or are thous somewhat redundant?
Yes, they to the same thing, just origin/master is explicit, while HEAD assumes the master tree to be the current one.
Comment 67 Laryllan 2011-10-22 04:00:31 UTC
PATCH_33905 doesn't work anymore /w Wine 1.3.31
Comment 68 Mateusz Stachowski 2011-10-30 15:48:41 UTC
Instead of using wine git one can also download it from SourceForge:

http://sourceforge.net/projects/wine/files/Source/

or ibiblio server:

wget http://ibiblio.org/pub/linux/system/emulators/wine/wine-1.3.31.tar.bz2

than unpack, patch, issue ./tools/make_requests command and compile.
Comment 69 Mateusz Stachowski 2011-10-30 15:57:27 UTC
(In reply to comment #68)
> Instead of using wine git one can also download it from SourceForge:
> 
> http://sourceforge.net/projects/wine/files/Source/
> 
> or ibiblio server:
> 
> wget http://ibiblio.org/pub/linux/system/emulators/wine/wine-1.3.31.tar.bz2
> 
> than unpack, patch, issue ./tools/make_requests command and compile.

I've also forgot to add that Trine 2 Beta doesn't work with this patch. I mean that it doesn't help and it doesn't make it worse (than with clean wine-1.3.31). The only thing that is working in that game are keyboard keys, but not all (for example ENTER doesn't work). The mouse cursor sits in the right down corner and it won't move at all, but left and right mouse buttons are working. There is also x cursor in the middle of the screen (game run from Steam).
Comment 70 Josh 2011-11-03 18:19:50 UTC
(In reply to comment #69)
> I've also forgot to add that Trine 2 Beta doesn't work with this patch. I mean
> that it doesn't help and it doesn't make it worse (than with clean
> wine-1.3.31). The only thing that is working in that game are keyboard keys,
> but not all (for example ENTER doesn't work). The mouse cursor sits in the
> right down corner and it won't move at all, but left and right mouse buttons
> are working. There is also x cursor in the middle of the screen (game run from
> Steam).

As someone who has this game working, I should clarify that the enter key doesn't do anything in the game anyway.
Comment 71 Anastasius Focht 2011-11-09 15:01:33 UTC
*** Bug 24403 has been marked as a duplicate of this bug. ***
Comment 72 Richard 2011-11-27 08:22:06 UTC
Created attachment 37665 [details]
Diff of manual merge of previous patch into WINE 1.3.32.

(In reply to comment #67)
> PATCH_33905 doesn't work anymore /w Wine 1.3.31

The issue is that a macro that contained a version number that was changed. The version that this patch used was ahead of both the previous one and the current one. I applied it by hand and it worked, but I am not sure if reusing the old number the right thing to do.

This patch also applies cleanly against WINE 1.3.33, but you need to specify -p2 to patch instead of -p1.
Comment 73 Vitaliy Margolen 2011-12-12 19:24:07 UTC
*** Bug 27224 has been marked as a duplicate of this bug. ***
Comment 74 Robert Walker 2011-12-23 16:47:48 UTC
(In reply to comment #72)
> Created attachment 37665 [details]
> Diff of manual merge of previous patch into WINE 1.3.32.
> 
> (In reply to comment #67)
> > PATCH_33905 doesn't work anymore /w Wine 1.3.31
> 
> The issue is that a macro that contained a version number that was changed. The
> version that this patch used was ahead of both the previous one and the current
> one. I applied it by hand and it worked, but I am not sure if reusing the old
> number the right thing to do.
> 
> This patch also applies cleanly against WINE 1.3.33, but you need to specify
> -p2 to patch instead of -p1.

Hi

I updated this patch to work with Wine release 1.3.35 (from Git tree). This patch completely sorts out the problem with running aliens versus predator classic 2000 steam version (where the mouse movements are not registered at all in game)...
http://bugs.winehq.org/show_bug.cgi?id=26557

I wonder if this patch could go mainstream? Perhaps enabled with a the mouse registry key - to avoid it causing regressions with newer games that don't use raw input??

Thanks
Bob
Comment 75 Robert Walker 2011-12-23 16:52:29 UTC
Created attachment 38090 [details]
Updated raw input mouse patch (works with Wine Git 1.3.35)

Updating the previous patch for Wine 1.3.32. There was only one hunk that wouldn't apply cleanly (due to a version number update) in Wine Git 1.3.35.

Appears to sort out my issues with mouse input to Aliens vs Predator Classic (2000) - Steam version.
Comment 76 Vitaliy Margolen 2011-12-23 18:14:11 UTC
*** Bug 26557 has been marked as a duplicate of this bug. ***
Comment 77 David Rogers 2011-12-24 08:28:05 UTC
This bug also affects Oddworld: Strangers Wrath, the patch above fixed Strangers Wrath and Alien Vs Predator Classic 2000 for me.
Comment 78 Vitaliy Margolen 2012-01-01 10:54:25 UTC
*** Bug 29370 has been marked as a duplicate of this bug. ***
Comment 79 Calum La Croix 2012-01-03 02:41:03 UTC
Robert, your modified patch doesn't seem to work on ARMA II/Operation Arrowhead. Mouse clicks don't work. raw3.patch, however, worked fine (merged without any issues, ./tools/make_requests altered 3 files and compiled and worked fine).

Could you diff your patch with raw3.patch and see if you missed anything?
Comment 80 Robert Walker 2012-01-04 12:19:34 UTC
(In reply to comment #79)
> Robert, your modified patch doesn't seem to work on ARMA II/Operation
> Arrowhead. Mouse clicks don't work. raw3.patch, however, worked fine (merged
> without any issues, ./tools/make_requests altered 3 files and compiled and
> worked fine).
> 
> Could you diff your patch with raw3.patch and see if you missed anything?

@Calum La Croix

Like most people I am not a WINE developer and I just had a game I wanted to test a "raw input" patch with. I simply pulled the most recent patch I could find from this thread and hacked it to work with a newer version of WINE.

Anyway I was intrigued enough by your comment to compare the patch I had pulled (from the link in Richard's posted) to the raw3.patch. I have enough C programming experience to see the raw3.patch appears to be a more refined version of the patch Richard had dug up (from where??) It has a number of significant improvements (error checking, use of heap memory, cleaner integration using 

I would agree that the raw3.patch is superior (which I believe Vincas Miliūnas is developing)... I've no idea what the origin of the other patch is/was (originally) but it appears to be quite dated and not so polished...
Comment 81 Calum La Croix 2012-01-04 21:36:12 UTC
@Robert

I see! Apologies if I came across as rude - I appreciate that the majority of contributions come from volunteered time. :) I simply misinterpreted your patch as a development on raw3. 

That said, isn't it about time that some kind of solution was integrated into mainline? Or is this not feasible without breaking current input support or breaking WINE source conventions?
Comment 82 Vitaliy Margolen 2012-01-08 11:27:12 UTC
*** Bug 29564 has been marked as a duplicate of this bug. ***
Comment 83 Pingubot 2012-01-15 07:22:18 UTC
can't get the last patch working with 1.3.37. A new one wouldreally be appreciated :)
Comment 84 Vincas Miliūnas 2012-01-15 08:37:02 UTC
As I already have suggested in Comment #60, please discontinue the practice of reattaching and using raw3.patch polluted with the products of ./tools/make_requests code-generation script.

If a person can apply a patch, they surely can do that with http://dl.dropbox.com/u/6901628/raw3.patch and type out ./tools/make_requests to run the script. It does not make anything easier, only will brake again and again on WINE server protocol changes, while raw3.patch still applies 1/2 year later.

Looks like this thread has become about "update plz" instead of focusing on implementing raw input :).
Comment 85 Robert Walker 2012-01-15 10:44:07 UTC
Comment on attachment 38090 [details]
Updated raw input mouse patch (works with Wine Git 1.3.35)

Use raw3.patch!! Don't use this version!!
Comment 86 David Rogers 2012-01-15 12:06:44 UTC
raw3 patch (and all other patches above) allows some mouse movement in Alien Vs Predator 2000 but it quite often randomly points straight down.

But it works perfectly with Oddworld: Stranger's Wrath.
Comment 87 llie 2012-02-02 10:06:18 UTC
(In reply to comment #7)
> It's not that easy. MS keeps creating API that's newer do what you need, no one
> can understand, no one knows how to use it right, and there are already several
> APIs that seems to do exactly the same thing.
> 
> RawInput is yet another DInput like interface but without all the device
> configuration craft, only it can intercept all events before the they hit user
> layer and generate all associated messages. For Wine that means this will have
> to be done in wineserver with extensive testing to be sure nothing broke. It
> will need a separate RawInput queue since events are buffered and then returned
> one or many at a time.

In reply to the last comment, I think the above early reply summarizes the situation well. Technically this isn't a "bug" as much as it is a request for a somewhat major enhancement to Wine.

I'm not sure if the raw3.patch is the beginnings to a proper implementation of a solution or not, but it doesn't seem to be a "silver bullet" fix for all games that require RawInput.  From what I've seen the raw3.patch doesn't seem to solve all problems for all games, whereas about half a dozen other patches have been submitted for various games.

If the approach taken in the raw3.patch is deemed by Wine Devs as being an ugly hack (which many of the other RawInput patches appear to be), it would be nice if they commented as such.  I've attempted to read and understand what the patch does, but it's over my head.  Without turning this into an entire sub-project, is there a way to develop and debug a proper solution per Vitaliy Margolen's comments above?

If however, the wine community is close to a solution, it would also be nice if this could be nominated as a candidate for the 1.4 release.
Comment 88 Anastasius Focht 2012-02-02 15:18:40 UTC
*** Bug 24955 has been marked as a duplicate of this bug. ***
Comment 89 cluthz 2012-02-07 20:04:09 UTC
I cannot get the raw.patch to patch.
Seems like the last segment has an error in the second last line and i get a malformed patch error.

Patching file server/raw_input.h using Plan A...
patch unexpectedly ends in middle of line
Comment 90 Vincas Miliūnas 2012-02-08 08:42:55 UTC
(In reply to comment #89)
> I cannot get the raw.patch to patch.
> Seems like the last segment has an error in the second last line and i get a
> malformed patch error.
> 
> Patching file server/raw_input.h using Plan A...
> patch unexpectedly ends in middle of line

SHA1 checksum of raw3.patch is 43901a0ef3ba1115bbaa0f6e2e8971c517a8181f

Be sure you've downloaded the file correctly.
Comment 91 Emmanuel Anne 2012-02-08 16:01:35 UTC
Well I can confirm this raw input patch (wine_rawinput_8_8_2011.patch) does miracles for kingdoms of amalur at least.
I am really curious to know why it wasn't merged in all that time, anyway... thanks for the patch, I'll keep it around ! :)
Comment 92 Emmanuel Anne 2012-02-08 16:03:28 UTC
Sorry I forgot to tell that the patch applies almost correctly on 1.4rc2, just have to edit an include file because of a define, after that it compiles without problem and does miracles, thanks again !
Comment 93 Vincas Miliūnas 2012-02-08 17:09:34 UTC
(In reply to comment #92)
> Sorry I forgot to tell that the patch applies almost correctly on 1.4rc2, just
> have to edit an include file because of a define, after that it compiles
> without problem and does miracles, thanks again !

wine_rawinput_8_8_2011.patch? It's the backwards version polluted with generated code - http://onliveinformer.com/2011/09/04/community-hack-allows-linuxwine-users-to-experience-onlive/ . It's also misattributed for the guy who attached the patch, not who developed it ;)

I've built WINE w/ raw3.patch today and there were no problems. You only need to run ./tools/make_requests script after applying the patch - http://bugs.winehq.org/show_bug.cgi?id=20395#c84
Comment 94 Emmanuel Anne 2012-02-08 18:49:18 UTC
Well I just lost some time trying to compile your raw3.patch with 1.4rc2 and it doesn't work : the patch applies without problem, and then :
a ton of errors on raw_input.c starting with :
raw_input.c:137:47: warning: 'struct raw_input_device_registration' declared inside parameter list
(very bad start !).

Ok, I'll revert to the other patch tomorrow (the one that works !), too late for that today... !
Comment 95 hash 2012-02-08 22:20:40 UTC
(In reply to comment #94)
> Well I just lost some time trying to compile your raw3.patch with 1.4rc2 and it
> doesn't work : the patch applies without problem, and then :
> a ton of errors on raw_input.c starting with :
> raw_input.c:137:47: warning: 'struct raw_input_device_registration' declared
> inside parameter list
> (very bad start !).
> 
> Ok, I'll revert to the other patch tomorrow (the one that works !), too late
> for that today... !

I am compiling wine-git every day with raw3.patch and it work perfectly and with no errors, here is sequence how I compile:
git clean -fd
git checkout -f && git fetch && git rebase origin
git reset --hard origin/master
export CFLAGS="-march=native -O2 -pipe -fomit-frame-pointer"
git apply ../raw3.patch
./tools/make_requests
./configure --prefix=/opt/wine-raw-input --without-openal --with-xinput2 --with-
opengl --with-oss --with-mpg123 && make depend && make && make install

It is by no means the right and/or the only way but simple the way I use and which works for me.
Comment 96 Vincas Miliūnas 2012-02-08 23:46:02 UTC
(In reply to comment #94)
> Well I just lost some time trying to compile your raw3.patch with 1.4rc2 and it
> doesn't work : the patch applies without problem, and then :
> a ton of errors on raw_input.c starting with :
> raw_input.c:137:47: warning: 'struct raw_input_device_registration' declared
> inside parameter list
> (very bad start !).
> 
> Ok, I'll revert to the other patch tomorrow (the one that works !), too late
> for that today... !

I explicitly said and and linked to that you need to run the ./tools/make_requests script after applying the patch ;)
Comment 97 Emmanuel Anne 2012-02-09 03:42:15 UTC
Ok, sorry, my bad, it might have been too late last night, and I missed the part about tools/make_request
So it's working ok now.

As a side note, shift is still ignored in the editable text boxes of kingdoms of amalur, but it's probably not related to this (the problem is here with any of these 2 patches or with no patch at all).
Anyway, thanks again, and I hope it will be merged soon, a very useful patch for sure !
Comment 98 Dedmas 2012-02-11 17:21:28 UTC
guys please explain, how i can patch my crossover games with rawinput 8 8 2 (step by step please)
Comment 99 Dmitry Timoshkov 2012-02-11 21:43:26 UTC
(In reply to comment #98)
> guys please explain, how i can patch my crossover games with rawinput 8 8 2
> (step by step please)

This is bugzilla, not a user support forum.
Comment 100 Vitaliy Margolen 2012-02-18 10:00:28 UTC
*** Bug 29917 has been marked as a duplicate of this bug. ***
Comment 101 Austin English 2012-02-23 15:21:20 UTC
Removing deprecated 'All' OS.
Comment 102 Béla Gyebrószki 2012-02-26 03:37:33 UTC
*** Bug 24681 has been marked as a duplicate of this bug. ***
Comment 103 Mr Nobody 2012-04-05 05:58:47 UTC
.. I've found the raw3.patch works for some good many apps - I was kind of hoping it'd fix xpad input of 'Blur' (Steam) which doesn't see my xpad at all, and it's one of those titles that has premapped configs built into the game options for the xpad HID. I didn't try hard to debug it, but the only obvious line has been and still is ;

fixme:win:RegisterRawInputDevices RIDEV_INPUTSINK support is not implemented

..kbd input works, but that's all. Tbh, I'm not entirely sure rawinput is the (only) culprit, but I'd like to isolate whether it's participle or not -- might someone in the know with this stuff suggest debug channels I should grab from Blur, to determine whether it's bad xpad behavior is part of this bug? Note, I got the above trace wrt wine-1.5.1 *with* the raw3.patch, linux.. I didn't look at what the pristine build is currently doing...

Thanks
Comment 104 Luis Alvarado 2012-04-08 17:10:46 UTC
Confirmed for Deus Ex. The only way to exit was to open a terminal and wineserver -k. Tested with 1.4 Final in Ubuntu 11.10.
Comment 105 Robert Walker 2012-04-09 17:44:34 UTC
(In reply to comment #104)
> Confirmed for Deus Ex. The only way to exit was to open a terminal and
> wineserver -k. Tested with 1.4 Final in Ubuntu 11.10.

Uhhhmmm. Everyone knows you mean Deus Ex: HR... But you still need to mention this (there are 2 previous versions of Deus Ex after all)... I certainly found I needed the raw.input3 patch to get Deus Ex: HR to accept any input. I was really hoping this patch (or similar) might get into 1.4...
Comment 106 sxe 2012-04-17 07:34:20 UTC
Hey guys, 

i don't know if this is of any interest but i tried the raw3.patch today to fix rawinput problems in some games based on the unity3d engine.

Before applying the patch i get some of these messages at start:

fixme:win:GetRawInputDeviceList (pRawInputDeviceList=(nil), puiNumDevices=0x33d700, cbSize=8) stub!
fixme:win:RegisterRawInputDevices (pRawInputDevices=0x33df58, uiNumDevices=1, cbSize=12) stub!

The game works fine beside the mouse input. Quit normal i think.

After applying the patch the messages above disappear but the game is stuck at that point.

So this patch does not fix unity3d games.

I'm on archlinux 64bit btw.
Comment 107 Frozen Fox 2012-04-22 10:54:45 UTC
(In reply to comment #106)
> i don't know if this is of any interest but i tried the raw3.patch today to fix
> rawinput problems in some games based on the unity3d engine.
> (. . .)
> So this patch does not fix unity3d games.

Just ftr (also on Arch64), the patch actually did fix my mouse input issues in Rochard, which I'm reasonably certain was done with unity3d. The game has other issues with textures messing up, but that is unrelated of course. Many thanks to whomever wrote it.
Comment 108 sxe 2012-04-22 12:00:26 UTC
@Brandon Howard
Thats interesting. I tried Rochard (installed with steam) and it does not work on my system. The Rochard.exe will be started but thats all, nothing happens than. I used wine-git with the patch, maybe i did something wrong. Can we meet in IRC to try to fix this? It works with the normal wine version (beside the mouse of course).
Comment 109 Ákos Maróy 2012-04-28 12:37:00 UTC
I'm trying to apply this patch to wine, but to no avail. what wine version do these patches work with? I've tried the latest 1.3 and 1.5 versions (1.3.37 and 1.5.3), but the patches don't work. here is what I get, for example, with 1.3.37:


$ patch -p2 --dry-run < ../wine-raw-input.patch 
patching file dlls/user32/input.c
Hunk #1 succeeded at 474 (offset -2 lines).
Hunk #2 succeeded at 705 (offset -2 lines).
Hunk #3 succeeded at 750 (offset -2 lines).
Hunk #4 succeeded at 771 (offset -2 lines).
Hunk #5 succeeded at 864 (offset -2 lines).
Hunk #6 succeeded at 905 (offset -2 lines).
patching file dlls/user32/tests/input.c
Hunk #3 succeeded at 1623 (offset 5 lines).
Hunk #4 succeeded at 2594 (offset 5 lines).
patching file include/wine/server_protocol.h
Hunk #1 succeeded at 4887 (offset 5 lines).
Hunk #2 succeeded at 5221 (offset 5 lines).
Hunk #3 succeeded at 5480 (offset 5 lines).
Hunk #4 FAILED at 5732.
1 out of 4 hunks FAILED -- saving rejects to file include/wine/server_protocol.h.rej
patching file server/Makefile.in
patching file server/process.c
patching file server/process.h
patching file server/protocol.def
Hunk #1 succeeded at 3374 (offset 5 lines).
patching file server/queue.c
Hunk #4 succeeded at 2220 (offset 10 lines).
patching file server/raw_input.c
patching file server/raw_input.h
patching file server/request.h
Hunk #3 succeeded at 2152 (offset 4 lines).
patching file server/trace.c
Hunk #1 succeeded at 3912 (offset 5 lines).
Hunk #2 succeeded at 4216 (offset 5 lines).
Hunk #3 succeeded at 4471 (offset 5 lines).
Hunk #4 succeeded at 4726 (offset 5 lines).


$ patch -p1 --dry-run < ../wine-raw-input-mouse.patch 
patching file dlls/user32/input.c
Hunk #2 FAILED at 56.
Hunk #3 succeeded at 494 (offset -7 lines).
Hunk #4 succeeded at 571 (offset -7 lines).
Hunk #5 succeeded at 687 (offset -7 lines).
1 out of 5 hunks FAILED -- saving rejects to file dlls/user32/input.c.rej
patching file dlls/user32/Makefile.in
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED -- saving rejects to file dlls/user32/Makefile.in.rej
patching file include/winuser.h
Hunk #1 succeeded at 493 (offset 2 lines).


$ patch -p1 --dry-run < ../wine_rawinput_8_8_2011.patch
patching file dlls/user32/input.c
Hunk #1 succeeded at 474 (offset -2 lines).
Hunk #2 succeeded at 705 (offset -2 lines).
Hunk #3 succeeded at 750 (offset -2 lines).
Hunk #4 succeeded at 771 (offset -2 lines).
Hunk #5 succeeded at 864 (offset -2 lines).
Hunk #6 succeeded at 905 (offset -2 lines).
patching file dlls/user32/tests/input.c
Hunk #3 succeeded at 1623 (offset 5 lines).
Hunk #4 succeeded at 2594 (offset 5 lines).
patching file include/wine/server_protocol.h
Hunk #1 succeeded at 4887 (offset 9 lines).
Hunk #2 succeeded at 5221 (offset 9 lines).
Hunk #3 succeeded at 5480 (offset 9 lines).
Hunk #4 FAILED at 5728.
1 out of 4 hunks FAILED -- saving rejects to file include/wine/server_protocol.h.rej
patching file server/Makefile.in
patching file server/process.c
patching file server/process.h
patching file server/protocol.def
Hunk #1 succeeded at 3374 (offset 9 lines).
patching file server/queue.c
Hunk #3 succeeded at 1459 (offset -3 lines).
Hunk #4 succeeded at 2220 (offset 15 lines).
patching file server/raw_input.c
patching file server/raw_input.h
patching file server/request.h
Hunk #3 succeeded at 2152 (offset 8 lines).
patching file server/trace.c
Hunk #1 succeeded at 3912 (offset 9 lines).
Hunk #2 succeeded at 4216 (offset 9 lines).
Hunk #3 succeeded at 4471 (offset 9 lines).
Hunk #4 succeeded at 4726 (offset 9 lines).
Comment 110 Robert Walker 2012-04-29 03:04:55 UTC
(In reply to comment #109)
> I'm trying to apply this patch to wine, but to no avail. what wine version do
> these patches work with? I've tried the latest 1.3 and 1.5 versions (1.3.37 and
> 1.5.3), but the patches don't work. here is what I get, for example, with
> 1.3.37:
> 
> ....

Are you using the "raw3.patch" (linked to a few times e.g. comment 61)? As stated in comment 62 - apply this to a clean Git tree...

Don't fall into the trap of using one of the many other "patches" floating about - that "saves" you having build the raw input handler (./tools/make_requests) manually after the "raw3.patch" patch is applied. Fell into that trap myself :-) However I had the common sense to delete my link when I realised what I had done...
Comment 111 Ákos Maróy 2012-04-29 05:31:10 UTC
(In reply to comment #110)
> (In reply to comment #109)
> > I'm trying to apply this patch to wine, but to no avail. what wine version do
> > these patches work with? I've tried the latest 1.3 and 1.5 versions (1.3.37 and
> > 1.5.3), but the patches don't work. here is what I get, for example, with
> > 1.3.37:
> > 
> > ....
> 
> Are you using the "raw3.patch" (linked to a few times e.g. comment 61)? As
> stated in comment 62 - apply this to a clean Git tree...
> 
> Don't fall into the trap of using one of the many other "patches" floating
> about - that "saves" you having build the raw input handler
> (./tools/make_requests) manually after the "raw3.patch" patch is applied. Fell
> into that trap myself :-) However I had the common sense to delete my link when
> I realised what I had done...

thanks, indeed it works agains the git tree. also thanks for the specific patch reference...
Comment 112 Zack Powers 2012-05-07 21:20:42 UTC
Created attachment 40087 [details]
ARMA 2: output of user32 channel with RawInput grepped during loading screen crash

The attached log is of a null a pointer exception that occurs whenever there are any mouse events during a loading screen in ArmA 2.

If there aren't any events during the loading screen, the game performs as expected.
Comment 113 ax 34noff 2012-05-11 06:45:52 UTC
* Advice for people who don't want to patch wine manually: use playonlinux or playonmac, they have already raw3-patched wines in their repository
Comment 114 Martin Madsen 2012-07-20 16:20:19 UTC
Created attachment 41081 [details]
Previous raw input patch for Wine 1.5.9

Ignored the VERSION part at the 4th hunk of server_protocol.h, as we would otherwise 'downgrade'.
Comment 115 Inf L00p 2012-07-21 03:20:38 UTC
The game Guild Wars 2 does not expect a UINT -1 returned on the GetRawInputData function, you can change the patch to return size of buffer, single line change on patch.
< return (UINT)-1;
> return result;
Comment 116 Forest 2012-07-22 00:01:43 UTC
(In reply to comment #114)
> Created attachment 41081 [details]
> Previous raw input patch for Wine 1.5.9
> 
> Ignored the VERSION part at the 4th hunk of server_protocol.h, as we would
> otherwise 'downgrade'.

In case anyone is looking for a quick & easy way to take advantage of your patch, I applied it to the current winehq ubuntu packages and published them in my PPA:
https://launchpad.net/~foresto/+archive/winepatched/
Comment 117 rmlipman 2012-07-24 01:31:41 UTC
When using the rawinput3 patch, the game Endless Space never actually shows the game window. It doesn't look like it's crashing either, as the process sticks around in the process list.
Comment 118 Robert Walker 2012-07-25 08:34:34 UTC
(In reply to comment #114)
> Created attachment 41081 [details]
> Previous raw input patch for Wine 1.5.9
> 
> Ignored the VERSION part at the 4th hunk of server_protocol.h, as we would
> otherwise 'downgrade'.

Please refer to comment 61/ 110!! raw3.patch is the way to go...
"Your patch" will break randomly at some future Wine update (and confuse people)...

Bob
Comment 119 Austin English 2012-07-27 12:50:34 UTC
*** Bug 31337 has been marked as a duplicate of this bug. ***
Comment 120 qMax 2012-08-12 08:29:34 UTC
Status: NEW?
for five years!?

What is state of the bug in 1.5.10?
Comment 121 Luis Alvarado 2012-08-14 09:24:07 UTC
Can confirm with Slender 0.9.6. Does not work even with PoL. Using Ubuntu 12.04 with PoL 4.0.16.

I tested with PoL 4.0.16 with the Wine 1.4.x it downloaded for Slender at the mouse did not work.

I then tested with the latest PPA update as of today using the Ubuntu Wine and it was the same problem. The video works perfectly in full graphics, the problem is when I try to move the mouse. It only responds to mouse clicks, but not movements.
Comment 122 rmlipman 2012-08-27 11:47:28 UTC
*** Bug 31267 has been marked as a duplicate of this bug. ***
Comment 123 chemacg 2012-09-02 18:59:54 UTC
No improvement on this?
Comment 124 voidcastr 2012-09-03 02:07:07 UTC
Apparently, either no one knows how to implement this correctly or doing so will potentially break so many things in wine that everybody is afraid of trying.

I've somewhat investigated the "raw3" hack a bit, but despite being a software developer I'm still neither a wine developer nor in to Windows APIs. Thus, it's quite hard to understand what's going on in there...

Anyway, one question arises:
Which aspects of the current "raw3" implementation must be changed so that it could be considered a fully functional patch?
Above, someone already mentioned the necessity of making many changes to the wineserver in order to get a nice and clean implementation...
Comment 125 Béla Gyebrószki 2012-09-03 12:41:46 UTC
*** Bug 31607 has been marked as a duplicate of this bug. ***
Comment 126 Jerome Leclanche 2012-09-06 17:45:00 UTC
Patches submitted.
Comment 127 voidcastr 2012-09-09 13:15:04 UTC
(In reply to comment #126)
> Patches submitted.

Sorry if this is a dumb question, but do you refer to the raw input implementation becoming a part of wine mainline?
Comment 128 Jerome Leclanche 2012-09-09 13:33:49 UTC
(In reply to comment #127)
Yes, Henri submitted some patches. They weren't accepted the first time around, waiting for approval right now.

See: http://source.winehq.org/patches/

Patches 89705, 89706, 89707, 89708
Comment 129 voidcastr 2012-09-10 16:06:23 UTC
The mentioned patches were just merged into the git. Unfortunately, it seems like they do not suffice as a functional raw input implementation -- at least not for the mouse input in Guild Wars 2 (I have no other application to test it).

Even worse, the current "raw3" hack cannot be applied to the current git version anymore.

Thus, we're currently stuck without any chance of raw input unless things get fixed...
Comment 130 Bruno Jesus 2012-09-10 16:16:28 UTC
The mentioned patches were not entirely correct. There are still 2 raw input patches are still in the list: 89656 and 89655.

Most possibly Henri will send then again.
Comment 131 Austin English 2012-09-11 17:21:07 UTC
(In reply to comment #130)
> The mentioned patches were not entirely correct. There are still 2 raw input
> patches are still in the list: 89656 and 89655.
> 
> Most possibly Henri will send then again.

http://source.winehq.org/git/wine.git/commitdiff/faaf3d388eb6db8c2594cb11f76a2b1bce77edf3

rawinput mouse support is now in. keyboard support is still pending.
Comment 132 voidcastr 2012-09-12 04:42:37 UTC
After compiling and testing the latest git version with Guild Wars 2 (in which the camera is rotated around the character by holding down the left or right mouse button and then dragging), I made the observations listed below. Please understand them as a feedback directed to providing viable information for debugging.

- Basically, the camera can now be turned using the mouse.
- Doing so has a major impact on the game's performance. For me, it drops from 40-50 to ~3 FPS.
- Actually, trying to turn the view with the mouse is not even necessary to cause the FPS drop: Simply moving the cursor e.g. in a constant circle, not even pressing a mouse button, leads to the very same result.
- Moving the cursor was already possible before the patch was merged to the git. Thus, it seems to me like the game only uses the raw input path when click-dragging the mouse.
- Before the patch was merged, moving the pointer did not cause a performance drop.
- The previous two points seem to contradict -- I suspect a conflict/bug somewhere in there.
- Turning the view with the keyboard is perfectly smooth, but it cannot be considered an option regarding gameplay.
- All in all, the camera angle kind of performs jumps instead of smooth transitions. This makes the game unplayable.

I'm quite sure to speak for many gamers out there when I say: Thank you for your efforts, Henri - we greatly appreciate your work! Ofc, this also goes to anyone else who was involved.

Anyway, we'd love to see further improvements on this - it looks like raw mouse input is almost done except for performance tweaks.
Comment 133 llie 2012-09-12 12:51:46 UTC
I've tested the new commit using Anarchy Online.  Using windowed mode (not full screen, and no full screen mouse capture).

I'm seeing the same results as Voidcastr.  Mouse control is extremely erratic.  I don't seem to be seeing the mere mouse movements causing a drop in framerate, but it could be that Anarchy Online only uses raw mouse input when there is a button press, as even without the raw3 patch the cursor would move in Anarchy Online, but the character and camera rotation (caused by pressing left or right mouse button) would not work without the raw3 patch.
Comment 134 Austin English 2012-09-12 13:43:52 UTC
http://source.winehq.org/git/wine.git/commitdiff/c6fcc0255c3e7a655b157d1e68e5c80fe328bdf2

keyboard input is now implemented. Other problems (performance, erratic mouse, etc.) should be filed as separate bugs.
Comment 135 voidcastr 2012-09-12 14:40:16 UTC
Created a new bug for the raw mouse input issues, as suggested:

http://bugs.winehq.org/show_bug.cgi?id=31691
Comment 136 Alexandre Julliard 2012-09-14 13:36:04 UTC
Closing bugs fixed in 1.5.13.


Privacy Policy
If you have a privacy inquiry regarding this site, please write to [email protected]

Hosted By CodeWeavers