From: <eli...@us...> - 2006-07-21 20:36:00
|
Revision: 2532 Author: elias_naur Date: 2006-07-21 13:35:27 -0700 (Fri, 21 Jul 2006) ViewCVS: http://svn.sourceforge.net/java-game-lib/?rev=2532&view=rev Log Message: ----------- Windows: Ingore DI_POLLEDDEVICE when setting buffer size of a directinput device Modified Paths: -------------- trunk/LWJGL/src/java/org/lwjgl/opengl/WindowsDirectInput.java trunk/LWJGL/src/java/org/lwjgl/opengl/WindowsDirectInputDevice.java Modified: trunk/LWJGL/src/java/org/lwjgl/opengl/WindowsDirectInput.java =================================================================== --- trunk/LWJGL/src/java/org/lwjgl/opengl/WindowsDirectInput.java 2006-07-17 23:27:29 UTC (rev 2531) +++ trunk/LWJGL/src/java/org/lwjgl/opengl/WindowsDirectInput.java 2006-07-21 20:35:27 UTC (rev 2532) @@ -46,6 +46,7 @@ public final static int DI_OK = 0x00000000; public final static int DI_NOEFFECT = 0x00000001; public final static int DI_PROPNOEFFECT = 0x00000001; + public final static int DI_POLLEDDEVICE = 0x00000002; public final static int DI_DOWNLOADSKIPPED = 0x00000003; public final static int DI_EFFECTRESTARTED = 0x00000004; Modified: trunk/LWJGL/src/java/org/lwjgl/opengl/WindowsDirectInputDevice.java =================================================================== --- trunk/LWJGL/src/java/org/lwjgl/opengl/WindowsDirectInputDevice.java 2006-07-17 23:27:29 UTC (rev 2531) +++ trunk/LWJGL/src/java/org/lwjgl/opengl/WindowsDirectInputDevice.java 2006-07-21 20:35:27 UTC (rev 2532) @@ -94,7 +94,7 @@ public void setBufferSize(int buffer_size) throws LWJGLException { int ret = setBufferSize(di_device, buffer_size); - if (ret != WindowsDirectInput.DI_OK) + if (ret != WindowsDirectInput.DI_OK && ret != WindowsDirectInput.DI_PROPNOEFFECT && ret != WindowsDirectInput.DI_POLLEDDEVICE) throw new LWJGLException("Failed to set buffer size (" + ret + ")"); int event_buffer_size = getEventSize()*buffer_size; event_buffer = BufferUtils.createByteBuffer(event_buffer_size); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |