Java-Gaming.org Hi !
Featured games (83)
games approved by the League of Dukes
Games in Showcase (542)
Games in Android Showcase (133)
games submitted by our members
Games in WIP (604)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
   Home   Help   Search   Login   Register   
  Show Posts
Pages: [1]
1  Game Development / Game Mechanics / Re: [odejava] Weird GeomTriMesh problems on: 2005-04-06 21:31:14
Quote
I would like a few more people to confirm that things are better with this change


Where can this version be downloaded from?
2  Game Development / Game Mechanics / [Odejava] Double precision odejava on: 2004-12-20 19:33:16
Are there plans on making a version of odejava using doubles, like there are two flavors of ODE?
3  Java Game APIs & Engines / JInput / Re: Problems when compiling Linux plugin on: 2004-08-26 21:44:17
Quote
Some time ago I have written two variants of the Linux based plugin. One of them is actually SDL based and may be usable with other OSes to.

Thanks for the links!

Quote
You mentioned that awkward installation mechanism. Have a look at the thread by me which was made sticky. It explains other variants.

Errr.. right. Must've overlooked it Roll Eyes
4  Java Game APIs & Engines / JInput / Re: State of Linux plugin on: 2004-08-26 20:08:13
Ahhh, mentioning the /dev/input/event* devices was key to success Smiley Changing their permissions fixed the problem.

I posted small patch which fixes Linux 2.4 problems, please see https://jinput.dev.java.net/issues/show_bug.cgi?id=31
5  Java Game APIs & Engines / JInput / Re: Problems when compiling Linux plugin on: 2004-08-26 20:08:03
Thanks for help, I posted small patch which seems to fix 2.4-related problems at https://jinput.dev.java.net/issues/show_bug.cgi?id=31 but it'll need to be improved so please take a look at it.
6  Java Game APIs & Engines / JInput / Re: State of Linux plugin on: 2004-08-24 21:35:47
Well, I think I'm stuck here. With 0 event devices the joystick device isn't going to be processed by loop at line 84 in file jinput.cpp -- at least I think that's where the problem is.

Any help will be very appreciated.
7  Java Game APIs & Engines / JInput / Problems when compiling Linux plugin on: 2004-08-24 21:24:01
I'm not sure if I should file a bug about it because I suspect I might be doing something wrong. Here is what I was getting when trying to build JInput from CVS on GNU/Linux 2.4.26 by issuing 'ant' command in source root:

Quote

Buildfile: build.xml

init:

core:

init:

compile:
   [javac] Compiling 17 source files to /home/max/projects/jinput_2004-08-25/coreAPI/classes

jar:
     [jar] Building jar: /home/max/projects/jinput_2004-08-25/coreAPI/bin/jinput.jar
    [copy] Copying 1 file to /home/max/projects/jinput_2004-08-25/plugins/DX8/lib

all:
    [echo] JInput has been built and jinput.jar is located in the bin directory.

windows_plugin:

linux_plugin:

init:
   [mkdir] Created dir: /home/max/projects/jinput_2004-08-25/plugins/linux/classes
   [mkdir] Created dir: /home/max/projects/jinput_2004-08-25/plugins/linux/bin

compileNativeJinputLib:

init:
   [mkdir] Created dir: /home/max/projects/jinput_2004-08-25/plugins/linux/src/native/build
   [mkdir] Created dir: /home/max/projects/jinput_2004-08-25/plugins/linux/src/native/apidoc

compileNativeJinputLib:
    [exec] In file included from EventDevice.h:32,
    [exec]                  from jinput.cpp:37:
    [exec] eventInterfaceTypes.h:16: error: redefinition of `struct input_absinfo'
    [exec] /usr/include/linux/input.h:49: error: previous definition of `struct
    [exec]    input_absinfo'
    [exec] In file included from EventDevice.h:32,
    [exec]                  from eventInterface.cpp:37:
    [exec] eventInterfaceTypes.h:16: error: redefinition of `struct input_absinfo'
    [exec] /usr/include/linux/input.h:49: error: previous definition of `struct
    [exec]    input_absinfo'
    [exec] In file included from EventDevice.cpp:27:
    [exec] eventInterfaceTypes.h:16: error: redefinition of `struct input_absinfo'
    [exec] /usr/include/linux/input.h:49: error: previous definition of `struct
    [exec]    input_absinfo'
    [exec] EventDevice.cpp: In member function `virtual int EventDevice::poll()':
    [exec] EventDevice.cpp:337: error: `EV_RST' undeclared (first use this function)
    [exec] EventDevice.cpp:337: error: (Each undeclared identifier is reported only once
    [exec]    for each function it appears in.)
    [exec] In file included from JoystickDevice.h:32,
    [exec]                  from joystickInterface.cpp:37:
    [exec] eventInterfaceTypes.h:16: error: redefinition of `struct input_absinfo'
    [exec] /usr/include/linux/input.h:49: error: previous definition of `struct
    [exec]    input_absinfo'
    [exec] In file included from JoystickDevice.cpp:27:
    [exec] eventInterfaceTypes.h:16: error: redefinition of `struct input_absinfo'
    [exec] /usr/include/linux/input.h:49: error: previous definition of `struct
    [exec]    input_absinfo'
    [exec] In file included from MixedDevice.cpp:27:
    [exec] eventInterfaceTypes.h:16: error: redefinition of `struct input_absinfo'
    [exec] /usr/include/linux/input.h:49: error: previous definition of `struct
    [exec]    input_absinfo'


    [exec] Result: 1

BUILD FAILED


I needed to apply these changes to make it compile:

Quote

Index: plugins/linux/src/native/EventDevice.cpp
===================================================================
RCS file: /cvs/jinput/plugins/linux/src/native/EventDevice.cpp,v
retrieving revision 1.3
diff -u -r1.3 EventDevice.cpp
--- plugins/linux/src/native/EventDevice.cpp    21 Apr 2004 09:48:54 -0000      1.3
+++ plugins/linux/src/native/EventDevice.cpp    24 Aug 2004 23:15:27 -0000
@@ -190,7 +190,7 @@
        sprintf(errorMessage, "Error reading device %s\n", deviceFileName);
        perror(errorMessage);
      }
-      absAxesData = abs_features.curr_value;
+      absAxesData = abs_features.value;
    }
  }

@@ -334,9 +334,11 @@
        //printf("abs axis %d translates to abs axis %d on this device\n", events.code, axisIndex);
        break;
      }
+/*
      case EV_RST:
        // not sure what to do here, doing nothing seems to work Smiley
        break;
+*/
      case EV_LED:
        // reveiced for things like numlock led change
        break;
@@ -363,11 +365,11 @@
}

int EventDevice::getAbsAxisMinimum(int axisNumber) {
-  return abs_features[axisNumber].min_value;
+  return abs_features[axisNumber].minimum;
}

int EventDevice::getAbsAxisMaximum(int axisNumber) {
-  return abs_features[axisNumber].max_value;
+  return abs_features[axisNumber].maximum;
}

int EventDevice::getAbsAxisFuzz(int axisNumber) {
Index: plugins/linux/src/native/eventInterfaceTypes.h
===================================================================
RCS file: /cvs/jinput/plugins/linux/src/native/eventInterfaceTypes.h,v
retrieving revision 1.1
diff -u -r1.1 eventInterfaceTypes.h
--- plugins/linux/src/native/eventInterfaceTypes.h      31 Jul 2003 19:34:46 -0000      1.1
+++ plugins/linux/src/native/eventInterfaceTypes.h      24 Aug 2004 23:15:27 -0000
@@ -13,6 +13,7 @@
        uint16_t version;
};

+/*
struct input_absinfo {
  int curr_value;
  int min_value;
@@ -20,5 +21,6 @@
  int fuzz;
  int flat;
};
+*/

#endif //eventInterfaceTypes_h


Am I doing something wrong?
8  Java Game APIs & Engines / JInput / Re: State of Linux plugin on: 2004-08-24 20:49:24
Great, answering myself  Wink

I made some progress, now when I run ControllerReadTest I get:

Scanning jar: linux.jar
Examining file : META-INF/
Examining file : META-INF/MANIFEST.MF
Examining file : net/
Examining file : net/java/
Examining file : net/java/games/
Examining file : net/java/games/input/
Examining file : net/java/games/input/LinuxDevice$LinuxHat.class
Examining file : net/java/games/input/LinuxDevice$ButtonID.class
Examining file : net/java/games/input/LinuxDevice$1.class
Examining file : net/java/games/input/LinuxDevice.class
Examining file : net/java/games/input/LinuxAxis.class
Examining file : net/java/games/input/LinuxEnvironmentPlugin.class
Found candidate class: net/java/games/input/LinuxEnvironmentPlugin.class
Adding class to plugins:net.java.games.input.LinuxEnvironmentPlugin
Examining file : net/java/games/input/LinuxKeyboard$KeyID.class
Examining file : net/java/games/input/LinuxKeyboard.class
Examining file : net/java/games/input/LinuxMouse$LinuxMouseBall.class
Examining file : net/java/games/input/LinuxMouse$LinuxMouseButtons.class
Examining file : net/java/games/input/LinuxMouse$LinuxMouseButton.class
Examining file : net/java/games/input/LinuxMouse.class
Examining file : net/java/games/input/LinuxNativeTypesMap.class
Examining file : net/java/games/input/NativeDefinitions.class
Initing event interface
Initing joystick interface
Trying to open /dev/input/js0
Opened /dev/input/js0, trying to get device name
Getting button and axes information for /dev/input/js0
Initialisation of /dev/input/js0 completed
Trying to open /dev/input/js1
Failed to open device /dev/input/js1
Trying to open /dev/input/js2
Failed to open device /dev/input/js2
Trying to open /dev/input/js3
Failed to open device /dev/input/js3
Getting the number of event devices
Getting 0 event devices
Getting the number of joystick devices
Getting 1 joystick devices

So the pad seems to be detected, yet it's not showing itself on the getControllers() list... hm... Huh

BTW, I don't want to whine but having to put plugin exactly in controller/ directory Shocked is about to be the perfect unintuitive way of doing it. I managed to find its rationale which sounds good but then I think it has two serious problems as it is now:
* it should be clearly described in the bold big red flashing letters in the README
* JInput should issue an error, or *at least* a clear warning if it doesn't find any plugins -- error message should also contain information about controller/ directory

I think I'll write a short beginner's guide for linux users when/if I manage to do make JInput work  Cheesy
9  Java Game APIs & Engines / JInput / Re: State of Linux plugin on: 2004-08-24 20:06:26
OK, now I'm not sure if Linux plugin is really unfinished as I saw two gamepad entries on the HCL for Linux marked as OK. So I add one more question: how to debug the pad (USB MediaTech MT160 Dual Shock) which doesn't work with JInput? I know it's working fine in all testing apps, cat /dev/input/js0 shows expected garbage and http://sourceforge.net/projects/javajoystick/ works fine so I think it's JInput's problem.
10  Java Game APIs & Engines / JInput / State of Linux plugin on: 2004-08-24 19:33:29
I tried to use JInput with gamepad on Linux (kernel 2.4) with no success (and as I read it's not yet really done, correct?). Everything here is set up properly and I can use the pad with Joystick Driver for Java (http://sourceforge.net/projects/javajoystick/). How are things? Is there any progress in this area (there are no changes in CVS for a few months)? Any expectations about where Linux plugin will work? Can someone with very limited C knowledge be of any help?
Pages: [1]
 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

Elsealabs (15 views)
2014-12-28 10:39:27

CopyableCougar4 (19 views)
2014-12-28 02:10:29

BurntPizza (24 views)
2014-12-27 22:38:51

Mr.CodeIt (14 views)
2014-12-27 04:03:04

TheDudeFromCI (19 views)
2014-12-27 02:14:49

Mr.CodeIt (26 views)
2014-12-23 03:34:11

rwatson462 (58 views)
2014-12-15 09:26:44

Mr.CodeIt (47 views)
2014-12-14 19:50:38

BurntPizza (96 views)
2014-12-09 22:41:13

BurntPizza (115 views)
2014-12-08 04:46:31
How do I start Java Game Development?
by gouessej
2014-12-27 19:41:21

Resources for WIP games
by kpars
2014-12-18 10:26:14

Understanding relations between setOrigin, setScale and setPosition in libGdx
by mbabuskov
2014-10-09 22:35:00

Definite guide to supporting multiple device resolutions on Android (2014)
by mbabuskov
2014-10-02 22:36:02

List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!