Go Back   Project64 Forums > Public Version > Project 64 - v2.x - Issues

Reply
 
Thread Tools Display Modes
  #31  
Old 14th May 2017, 01:36 AM
Maniac Maniac is offline
Junior Member
 
Join Date: Mar 2017
Posts: 19
Default

Quote:
Originally Posted by Frank74 View Post
I made the change but cannot test, as I don't have any XInput controllers to test with.

Here's a build with the code from post #22 to test.
https://www.dropbox.com/s/mgbyng51my...NRage.dll?dl=1

I don't notice any difference in time taken to init.
Thanks for the build! This brought the init time down from 23 seconds to 6 seconds (timed them both). Still not perfect, but definitely way better! So it looks like we are only enumerating the HID devices 1/3 or 1/4 the number of times now on my device.

The rest may be a buggy device driver specific to my device. I'll have to play around with my HID devices. I don't think there's much more we can do with the code.
Reply With Quote
  #32  
Old 14th May 2017, 01:42 AM
Maniac Maniac is offline
Junior Member
 
Join Date: Mar 2017
Posts: 19
Default

My post went to moderation again... not really sure why that keeps happening.

Thanks for the build Frank74. I went from 23 seconds to init to 6 seconds on my device. I think it's enumerating 1/3 to 1/4 of the time now.

The rest of the delay is probably a buggy HID driver on my device. I might try playing with that some time, but with only a 6 second wait I probably don't care enough. There's not much else we can do with the code (unless there are multiple controllers hooked up... any device that has a delay will have a linear increase in delay per controller without a more complicated code fix).
Reply With Quote
  #33  
Old 14th May 2017, 05:25 AM
retroben's Avatar
retroben retroben is offline
Alpha Tester
Project Supporter
Senior Member
 
Join Date: Jul 2013
Posts: 651
Default

Quote:
Originally Posted by theboy181 View Post
not sure how to do that tbh..
Open the Task Manager via right clicking for the context menu on the clock in taskbar and then after making all processes visible,click on the top part with the CPU usage text on it so the list updates on every instance of changed CPU usage for any and every given program using your CPU cores.
If the WMI Provider Host or other particular processes flare up during the delayed open moment,then that is likely the problem process causing the issue to still occur.
Reply With Quote
  #34  
Old 15th May 2017, 12:41 PM
Maniac Maniac is offline
Junior Member
 
Join Date: Mar 2017
Posts: 19
Default

OK, I've created a pull request for this:
https://github.com/project64/project64/pull/1312

I made an additional change. I noticed that there was also a few seconds being spent process devices of type DI8DEVTYPE_DEVICE. These aren't keyboards or mice... they are just generic devices. I added an immediate return when we run across one of these devices.

@Squall, when I tried DI8DEVCLASS_GAMECTRL, I never hit the IsXInputDevice call for my XInput device. I only hit it when I had DI8DEVTYPE_GAMEPAD, as that's what my gamepad was returning. Were you hitting the call?
Reply With Quote
  #35  
Old 15th May 2017, 03:32 PM
Maniac Maniac is offline
Junior Member
 
Join Date: Mar 2017
Posts: 19
Default

I submitted a pull request for this:
https://github.com/project64/project64/pull/1312

I also made an additional minor change. Many of the enumerated devices were of the type DI8DEVTYPE_DEVICE. These aren't anything important for gaming, so now the enumerate skips them rather than processing them. This saves a couple more seconds on my device.

@Squall, you'll probably want to move this change to the nrage repo. Also, when I tried putting DI8DEVCLASS_GAMECTRL in the switch statement, I never hit that case, so IsXInputDevice was not called. Did you hit it in yours? My Xbox 360 controller was returning DI8DEVTYPE_GAMEPAD.
Reply With Quote
  #36  
Old 15th May 2017, 03:32 PM
Maniac Maniac is offline
Junior Member
 
Join Date: Mar 2017
Posts: 19
Default

I submitted a pull request for this on the project 64 github:
https://github.com/project64/project64/pull/1312

I also made an additional minor change. Many of the enumerated devices were of the type DI8DEVTYPE_DEVICE. These aren't anything important for gaming, so now the enumerate skips them rather than processing them. This saves a couple more seconds on my device.

@Squall, you'll probably want to move this change to the nrage repo. Also, when I tried putting DI8DEVCLASS_GAMECTRL in the switch statement, I never hit that case, so IsXInputDevice was not called. Did you hit it in yours? My Xbox 360 controller was returning DI8DEVTYPE_GAMEPAD.
Reply With Quote
  #37  
Old 15th May 2017, 03:34 PM
Maniac Maniac is offline
Junior Member
 
Join Date: Mar 2017
Posts: 19
Default

(Weird, whenever I put a link in, my post goes to moderation)

I submitted a pull request for this on the project 64 github.

I also made an additional minor change. Many of the enumerated devices were of the type DI8DEVTYPE_DEVICE. These aren't anything important for gaming, so now the enumerate skips them rather than processing them. This saves a couple more seconds on my device.

@Squall, you'll probably want to move this change to the nrage repo. Also, when I tried putting DI8DEVCLASS_GAMECTRL in the switch statement, I never hit that case, so IsXInputDevice was not called. Did you hit it in yours? My Xbox 360 controller was returning DI8DEVTYPE_GAMEPAD.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT. The time now is 01:43 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.