Open trigun0x2 opened 10 years ago
I'm using windows 8.1 and it works fine for me. Not sure what's up.
I just messaged the guy, hopefully this was a detection of different languages problem that was fix in 697caa6c4d6b69806f7024d9f6cbf409db937ba1
Log from Win8.1 user. Did not seem to be fixed in the latest patch.
Checking for updates ... Latest version available: 0.15.201403141 Waiting for Hearthstone (in windowed mode) ... null window found with process name Hearthstone.exe Warning! null minimized. No detection possible. null window restored
Resolution: 1360 x 768
Seems to be an issue with a 3 monitor setup. Not sure if we're going to support that any time soon. @JeromeDane
Yeah, it doesn't work on certain graphics setups (my work computer has 5 monitors and doesn't work). Could be outdated vid. drivers too. No intention/ability to support such setups.
I am running Windows 8.1 with 3 monitors as standard which does not work, one VGA and the other HDMI and the standard laptop monitor. Detection don't work with 3 monitors, when I unplug one detections works (2 monitor setup).
@JeromeDane Do you know why more than 2 monitors does not work? The native windows api's to get the window position and size / do the copying should work independent of the number of monitors right?
Not sure if it's the same problem or not, but screen capture also doesn't work with my triple monitor setup (Windows 7). I get no error message on the log, but it was visible that it wasn't working (the app didn't recognize any event that wasn't coming purely from the game log).
I did some digging through the code and after some quick hacks to check out the output of the capture, it turns out the problem is related to the Win BitBlt function. At least on my system, this function is "caching" the first capture it does, and always returns the same bitmap afterwards. It works fine if: a) I use a single monitor b) I disable Aero (no idea why, it was just a hunch to try this)
One possible solution for this is to revert back to standard Java capture (using the Robot class). I saw in the code that this code path is only used if the game is in "fullscreen", but otherwise it uses a C/JNA implementation.
My tweak was to change the getHSWindowBounds function to return the window client bounds in screen coordinates, and then always use robot.createScreenCapture(bounds) in getScreenCapture().
public Rectangle getHSWindowBounds() { RECT bounds = new RECT(); POINT topLeft = new POINT();
/*
User32Extra.INSTANCE.GetWindowRect(windowHandle, bounds);
*/
User32Extra.INSTANCE.GetClientRect(windowHandle, bounds); // get client coords
topLeft.x = bounds.left;
topLeft.y = bounds.top;
User32Extra.INSTANCE.ClientToScreen(windowHandle, topLeft); // convert top-left
bounds.left = topLeft.x;
bounds.top = topLeft.y;
bounds.right = bounds.right + bounds.left;
bounds.bottom = bounds.bottom + bounds.top;
return bounds.toRectangle();
}
This had very little testing, but seems to work perfectly fine in my system. Hope this helps.
Not sure what the problem is since I am not running 8.1 but several Win8.1 users have notified me that it does not detect anything except for the game window in 8.1.