|
|
Created:
7 years, 9 months ago by CrazyNorman Modified:
6 years, 4 months ago CC:
chromium-reviews, joi+watch-content_chromium.org, darin-cc_chromium.org, jam Base URL:
http://src.chromium.org/svn/trunk/src/ Visibility:
Public. |
DescriptionAdded a mapping for the Logitech Extreme 3D Pro joystick to the DirectInput whitelist. This way, Windows users with this joystick will be able to access it through the Gamepad APIs
BUGS=217608
Patch Set 1 #Patch Set 2 : #
Total comments: 1
Messages
Total messages: 10 (0 generated)
No LGTM from a valid reviewer yet. Only full committers are accepted. Even if an LGTM may have been provided, it was from a non-committer or a lowly provisional committer, _not_ a full super star committer. See http://www.chromium.org/getting-involved/become-a-committer Note that this has nothing to do with OWNERS files.
Hi Scott, We spoke on IRC, and I've submitted the patch discussed. Bug is logged here: https://code.google.com/p/chromium/issues/detail?id=217608&thanks=217608&ts=1... Thanks, Dan
+teravest It doesn't seem right to me to call this a standard gamepad. ref: http://www.logitech.com/en-us/product/extreme-3d-pro?crid=719 Options that come to mind: 1) We could have mappers that don't add the "STANDARD GAMEPAD" to |id|. I'm not sure how sensible that is if we don't know what we're mapping them to. 2) Work on the spec to define a similar "STANDARD JOYSTICK". 3) Remove the whitelist and allow all DirectInput devices through in raw form. https://codereview.chromium.org/12917009/diff/4001/content/browser/gamepad/ga... File content/browser/gamepad/gamepad_standard_mappings_win.cc (right): https://codereview.chromium.org/12917009/diff/4001/content/browser/gamepad/ga... content/browser/gamepad/gamepad_standard_mappings_win.cc:89: mapped->buttons[kButtonLeftShoulder] = 4; I'm assuming these two lines are incorrect.
On Mon, Mar 18, 2013 at 11:29 AM, <scottmg@chromium.org> wrote: > +teravest > > It doesn't seem right to me to call this a standard gamepad. ref: > http://www.logitech.com/en-us/product/extreme-3d-pro?crid=719 > > Options that come to mind: > 1) We could have mappers that don't add the "STANDARD GAMEPAD" to |id|. I'm > not > sure how sensible that is if we don't know what we're mapping them to. > 2) Work on the spec to define a similar "STANDARD JOYSTICK". > 3) Remove the whitelist and allow all DirectInput devices through in raw > form. Option 3 makes me nervous, only because I've seen such different mappings on gamepads with similar shapes. I'm inclined toward option 1, mostly because it's less work than making a joystick spec (and I don't know how standardized they are). > > > https://codereview.chromium.org/12917009/diff/4001/content/browser/gamepad/ga... > File content/browser/gamepad/gamepad_standard_mappings_win.cc (right): > > https://codereview.chromium.org/12917009/diff/4001/content/browser/gamepad/ga... > content/browser/gamepad/gamepad_standard_mappings_win.cc:89: > mapped->buttons[kButtonLeftShoulder] = 4; > I'm assuming these two lines are incorrect. > > https://codereview.chromium.org/12917009/
Option #1 seems like a good idea to me. By the way, if I were to set things up so that the DirectInput portion of Chromium reads these mappings from configuration files, would that be acceptable? It'd be a lot more flexible than hard-coding. My main issue is whether its appropriate to have configuration files specific to one subsystem, or if it should try to function for XInput and cross platform situations? On 2013/03/21 16:27:09, teravest wrote: > On Mon, Mar 18, 2013 at 11:29 AM, <mailto:scottmg@chromium.org> wrote: > > +teravest > > > > It doesn't seem right to me to call this a standard gamepad. ref: > > http://www.logitech.com/en-us/product/extreme-3d-pro?crid=719 > > > > Options that come to mind: > > 1) We could have mappers that don't add the "STANDARD GAMEPAD" to |id|. I'm > > not > > sure how sensible that is if we don't know what we're mapping them to. > > 2) Work on the spec to define a similar "STANDARD JOYSTICK". > > 3) Remove the whitelist and allow all DirectInput devices through in raw > > form. > > Option 3 makes me nervous, only because I've seen such different > mappings on gamepads with similar shapes. > > I'm inclined toward option 1, mostly because it's less work than > making a joystick spec (and I don't know how standardized they are). > > > > > > > > https://codereview.chromium.org/12917009/diff/4001/content/browser/gamepad/ga... > > File content/browser/gamepad/gamepad_standard_mappings_win.cc (right): > > > > > https://codereview.chromium.org/12917009/diff/4001/content/browser/gamepad/ga... > > content/browser/gamepad/gamepad_standard_mappings_win.cc:89: > > mapped->buttons[kButtonLeftShoulder] = 4; > > I'm assuming these two lines are incorrect. > > > > https://codereview.chromium.org/12917009/
On Fri, Mar 22, 2013 at 12:10 PM, <CrazyNorman@gmail.com> wrote: > Option #1 seems like a good idea to me. By the way, if I were to set things > up > so that the DirectInput portion of Chromium reads these mappings from > configuration files, would that be acceptable? You mean having a configuration file that's parsed at runtime? It's probably worth asking chromium-dev, I personally can't think of many parts of Chromium that behave that way. > It'd be a lot more flexible > than > hard-coding. My main issue is whether its appropriate to have configuration > files specific to one subsystem, or if it should try to function for XInput > and > cross platform situations? XInput should be consistent across devices, so I don't think you'd have to be concerned in that case. It would be nice if the configuration file was the same across windows, OS X, and Linux, though. Thankfully, the mapper interface they all use is the same. > > On 2013/03/21 16:27:09, teravest wrote: > >> On Mon, Mar 18, 2013 at 11:29 AM, <mailto:scottmg@chromium.org> wrote: >> > +teravest >> > >> > It doesn't seem right to me to call this a standard gamepad. ref: >> > http://www.logitech.com/en-us/product/extreme-3d-pro?crid=719 >> > >> > Options that come to mind: >> > 1) We could have mappers that don't add the "STANDARD GAMEPAD" to |id|. >> > I'm >> > not >> > sure how sensible that is if we don't know what we're mapping them to. >> > 2) Work on the spec to define a similar "STANDARD JOYSTICK". >> > 3) Remove the whitelist and allow all DirectInput devices through in raw >> > form. > > >> Option 3 makes me nervous, only because I've seen such different >> mappings on gamepads with similar shapes. > > >> I'm inclined toward option 1, mostly because it's less work than >> making a joystick spec (and I don't know how standardized they are). > > >> > >> > >> > > > > https://codereview.chromium.org/12917009/diff/4001/content/browser/gamepad/ga... >> >> > File content/browser/gamepad/gamepad_standard_mappings_win.cc (right): >> > >> > > > > https://codereview.chromium.org/12917009/diff/4001/content/browser/gamepad/ga... >> >> > content/browser/gamepad/gamepad_standard_mappings_win.cc:89: >> > mapped->buttons[kButtonLeftShoulder] = 4; >> > I'm assuming these two lines are incorrect. >> > >> > https://codereview.chromium.org/12917009/ > > > > > https://codereview.chromium.org/12917009/
The mapping interface is the same, but I'm not sure the raw data for a device will be the same across different operating systems, so I think we'd need per-OS sections. (Hopefully I'm wrong about that?) We would want to bake the remap database at build time not parse config files at runtime, but as the database grows we should refactor the code mappings to be data-driven. I apologize this is taking so long Daniel, we don't really have a great plan for non-gamepad style devices at this point. To get this CL landed, the prerequisite is to refactor the mapping code to support mapping for joysticks and have them put "STANDARD JOYSTICK" into the id string rather than GAMEPAD. On Fri, Mar 29, 2013 at 7:20 AM, Justin TerAvest <teravest@chromium.org> wrote: > On Fri, Mar 22, 2013 at 12:10 PM, <CrazyNorman@gmail.com> wrote: >> Option #1 seems like a good idea to me. By the way, if I were to set things >> up >> so that the DirectInput portion of Chromium reads these mappings from >> configuration files, would that be acceptable? > > You mean having a configuration file that's parsed at runtime? > It's probably worth asking chromium-dev, I personally can't think of > many parts of Chromium that behave that way. > >> It'd be a lot more flexible >> than >> hard-coding. My main issue is whether its appropriate to have configuration >> files specific to one subsystem, or if it should try to function for XInput >> and >> cross platform situations? > > XInput should be consistent across devices, so I don't think you'd > have to be concerned in that case. > It would be nice if the configuration file was the same across > windows, OS X, and Linux, though. Thankfully, the mapper interface > they all use is the same. > >> >> On 2013/03/21 16:27:09, teravest wrote: >> >>> On Mon, Mar 18, 2013 at 11:29 AM, <mailto:scottmg@chromium.org> wrote: >>> > +teravest >>> > >>> > It doesn't seem right to me to call this a standard gamepad. ref: >>> > http://www.logitech.com/en-us/product/extreme-3d-pro?crid=719 >>> > >>> > Options that come to mind: >>> > 1) We could have mappers that don't add the "STANDARD GAMEPAD" to |id|. >>> > I'm >>> > not >>> > sure how sensible that is if we don't know what we're mapping them to. >>> > 2) Work on the spec to define a similar "STANDARD JOYSTICK". >>> > 3) Remove the whitelist and allow all DirectInput devices through in raw >>> > form. >> >> >>> Option 3 makes me nervous, only because I've seen such different >>> mappings on gamepads with similar shapes. >> >> >>> I'm inclined toward option 1, mostly because it's less work than >>> making a joystick spec (and I don't know how standardized they are). >> >> >>> > >>> > >>> > >> >> >> https://codereview.chromium.org/12917009/diff/4001/content/browser/gamepad/ga... >>> >>> > File content/browser/gamepad/gamepad_standard_mappings_win.cc (right): >>> > >>> > >> >> >> https://codereview.chromium.org/12917009/diff/4001/content/browser/gamepad/ga... >>> >>> > content/browser/gamepad/gamepad_standard_mappings_win.cc:89: >>> > mapped->buttons[kButtonLeftShoulder] = 4; >>> > I'm assuming these two lines are incorrect. >>> > >>> > https://codereview.chromium.org/12917009/ >> >> >> >> >> https://codereview.chromium.org/12917009/
On 2013/03/29 17:39:04, scottmg wrote: > I apologize this is taking so long Daniel, we don't really have a > great plan for non-gamepad style devices at this point. To get this CL > landed, the prerequisite is to refactor the mapping code to support > mapping for joysticks and have them put "STANDARD JOYSTICK" into the > id string rather than GAMEPAD. Hey Scott. Has there been an update since this was last discussed? If not, I'd love to work with you or someone else on getting this refactor in. I'm looking for this specific joystick support in one of my node-webkit projects. |