I have a cross platform application built with libgdx. The software is often used in conjunction with large touchscreens (like the microsoft coffee table thingy) with Windows (7 & 8) and MacOS. These screens are multitouch capable but I've only implemented single-touch, and would like to take the leap to multi.
I'm asking a few questions here in case someone knowledgeable could spare me a bunch of hours testing hypothesis that are undocumented and un-googleable AFAIK:
-does libgdx support the win7 multitouch interface? win8?
-if I must resort to mt4j, can it be used WITHOUT the 3d engine layer? Heck I don't even need gesture recognition, just the low level state of the fingers. There is no way I'm replacing 10000+ lines of libgdx with mt4j!
-has anyone tried sparsh-ui as an alternative to mt4j? Does it support win7 multitouch?
Thanks for any bit of information that can be provided on these matters!
Cheers!
As far as i know there shouldn't be a problem with multitouch. For libgdx mouse presses and touches are the same thing, so there shouldn't be a problem for win7 and win8.
The touchDown, touchUp and touchDragged methods give you an int pointer, which describes the number of the touch. So if you touch with 4 fingers, the touchDown with pointer = 4 describes the touch of the 4th finger.
You can read something about that here.
Note that i did not test this, as i don't have a win7/8 touch device. So you have to test it yourself, but as i said it should work. Let me know if it worked. Thanks
I`m developing a new robot for a Rescue Competition, and we want to use SLAM to do the mapping and Localization.
One of the main problems is to match a list of dots with another list of dots.
We are running the robot on an Android 2.4Ghz, with a self made app.
Does anyone know about any Java Library for ICP (Iterative Closest Point) or PSM (Polar Scan Matching) algorithm?
If not, do you know how to implement it in Java?
Thanks
This is a pretty vague answer, but you could try your luck with the MITK (Medical Imaging Toolkit) Framework. Some filters there employ the ICP Algorithm. Since the whole thing is open source you should be able to find what you need there. It's all written in C++ though. Plus Side: They are working on an improved version, the Anisotropic ICP. Also check the point based registration module from the 3m3 branch of MITK: The Point Based Registration Module
In school, one of my professors had created a 3D game (not just an engine), where all the players were entirely AI-controlled, and it was our assignment to program the AI of a single player. We were basically provided an API to interact with the game world.
Our AI implementations were then dropped into the game together, and we watched as our programs went to battle against each other.
It was like robot soccer, but virtual, with lots of big guns, and no soccer ball.
I'm now looking for anything similar (and open source) to play with. (Preferably in Java, but I'm open to any language.) I'm not looking for a game engine, or a framework... I'm looking for a complete game that simply lacks AI code... preferably set up for this kind of exercise. Suggestions?
This sounds very similar to Robocode.
Robocode is a programming game, where the goal is to develop a robot battle tank to battle against other tanks in Java or .NET. The robot battles are running in real-time and on-screen.
You may want to check out AIIDE in 2010, where they will be hosting a Starcraft Broodwar AI competition. You can download the software, API, and proxies to allow you to connect your homegrown AI into the Broodwar simulation.
Unlike other platforms such as 3D Robocup, the Broodwar engine will handle the physics, and will probably allow you to focus most of your time on higher level aspects such as path planning, strategy, resource allocation, etc. There are also basic forms of AI that you can plop in as placeholders while you work on your specific improvement, say a melee AI for example.
Check out Mario AI. You get to program an AI to control mario. There's a competition and some papers associated with it. Very easy to setup and get running with Java or any JVM language.
My AI class used the open-source BZFlag, which turned out to be quite entertaining and informative.
You might consider Open NERO (" (Preferably in Java, but I'm open to any language.)") but it's written in Python. If none of the Java suggestions appeal to you, take a look here:
http://code.google.com/p/opennero/
It doesn't "lack" AI code, it contains it. Perhaps looking at an AI implmentation in Python would give you some inspiration for your Java efforts.
Edit: To address vidstige's comment - you could try this : http://aichallenge.org/ - Programming ants to gather food and fight enemy. There seems to be a Java implementation there.
You may start with
this game
Some AI is already implemented so that you can take example
I know you indirectly referenced RoboCup in your question, but I think it's worth a mention here given the heading. There are both 2D and 3D versions:
2D League
3D League
The 2D league is more abstract with commands like move, catch, kick.
The 3D league is more complex as you have to control the angles of each hinge in a 3D robot's body (22 of them with the Nao model).
Both are equally valid exercises for AI. It probably depends what area of AI you want to play with.
Both can be programmed from any language/platform that supports TCP sockets. You'll find sample code in Java online to get you started. I've been maintaining a list of existing libraries for 3D RoboCup on the SimSpark Wiki here.
If you want to use .NET for the 3D league, you can use the TinMan library I created.
Check out ORTS.
Torcs is a racing game engine that lets you build your own drivers in C++.
Your prof's game reminds me a lot of the old macintosh game Assassin, which wasted many of my after-school hours back in the day. It was an interesting turn-based game where players input their moves at the start of each turn, and then their moves are executed simultaneously. The game's AI's were kind of dumb, and I always wished I could muck around and improve them, but I never found an open source version of the game.
My current problem is not so much a blackberry issue as it is a java
package issue.
In the application I have a rectangular region. This region is rotated by
about 30%.
I need to accomplish two things:
when a user clicks, is he inside the region?
when a user draws a straight line on the screen,
does any part of that line intersect the region? if so, what is the
length of the line inside the region?
I know that I can write my own functions to accomplish this (after dusting
off some algebra and geometry skills that aren't needed for web forms) but
I was thinking that this is a common issue in game programming. I found
some libraries for c++ and some for c# but nothing for java.
Does anyone have suggestions for good java packages? The packages don't need to have graphical components. In fact it would be best if they just handled the geometry and calculations based on x,y co-ordinates alone.
The usefulness of this answer will depend on exactly what type (SE or ME) and what version (and, for ME, what config and profile) of JVM you are targeting. Since it's a blackberry, you are likely J2ME of some flavor - YMMV.
That said, the functions you want appear to be present in java.awt.Rectangle, java.awt.geom.Rectangle2D and java.awt.geom.Line2D.
I want to begin developing 2D Java games for phones (on J2ME) therefore I'd like to know if any libraries or "engines" exist to help out in the various graphical tasks:
Drawing text with pixel fonts?
Drawing bitmaps for sprites with multiple frames like animated GIFs?
Drawing graphics with code, lines, beziers, flood-filling and gradient fills?
Ordering / layering of sprites?
Or maybe a great book exists, that gives you enough code samples to get off the ground quickly?
MIDP (JSR-118) includes the basics (most of the things you listed above) mainly in the javax.microedition.lcdui and javax.microedition.lcdui.game namespaces.
I didn't use it myself, but heard some good reference on here.
And here is even a list of libraries, you might need.
There was a book released quite a few years ago called Developing Games in Java by David Brackeen.
That covers the basics of 2d and 3d development in pure Java as well as how to handle time jumps and update the physical properties of your game characters. It is a good introduction to the topic.