Java-Gaming.org    
Featured games (91)
games approved by the League of Dukes
Games in Showcase (581)
games submitted by our members
Games in WIP (500)
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] 2 3 ... 11
1  Game Development / Shared Code / Kinect: Java/JNI wrapper for libfreenect on: 2010-11-29 15:06:18
Hi everyone,

I have written a Java/JNI wrapper for 'libfreenect' recently which might be interesting for Java Games.

I only tested it on Ubuntu 64bit but in principle it should compile on
others platforms. However, the minimal build script has some
hard-coded paths for now.

Anyway, please give it a try and let me know if it works for you:
https://github.com/michael-nischt/libfreenect

Usage:
1. cmake .
2. make
3. cd wrappers/java
    ./build.sh


Best,
 Micha
2  Java Game APIs & Engines / OpenGL Development / Re: lwjgl.org down on: 2010-09-13 14:34:05
thanks, it worked magically.
3  Java Game APIs & Engines / OpenGL Development / Re: lwjgl.org down on: 2010-09-13 13:48:55
Is the Forum (http://lwjgl.org/forum/) registration broken as part of this?

I tried to create an account (michael.nischt) during the weekend but never received the validation mail, even not after requesting a re-send. I checked my spam folder and nothing there either.
4  Java Game APIs & Engines / JOGL Development / Re: How to enable quad-buffered stereo rendering? on: 2010-07-06 08:23:34
Just to confirm: quad-buffered rendering for stereoscopic 3D works well with the OpenGL Bindings of the LWJGL - even embedded inside awt using the AWTGLCanvas. So it has to be a Jogl/Jogamp specific bug.

A fix would be very much appreciated, but I'm glad that I can continue to use Java with the LWJGL in the meantime (and possible in the future as I like LWJGL's simplistic approach).

Best,
 Michael
5  Java Game APIs & Engines / JOGL Development / Re: How to enable quad-buffered stereo rendering? on: 2010-07-04 21:27:08
thanks for answering.

Unfortunately the solution is not that simple.

I tried in fullscreen mode and it didnt work. Also the python works in window mode and AFAIK the technique is supposed to work in window mode (as opposed the nvidia Direct3D "automatic stereo).

Anyhow, I wil try with the LWJGL tomorrow or on Tuesday and let you guys know if it works there..
6  Java Game APIs & Engines / JOGL Development / How to enable quad-buffered stereo rendering? on: 2010-07-02 16:54:18
Hi there,

I have an 120Hz screen and the nvidia 3D vision kit plugged into my computer running Ubuntu (Linux-amd64) with a GeForce Quadro FX 4800 and want to use quad-buffered stereo rendering in jogl2. Unfortunately, I don't see how to enable it.

I set GLCapabilties.setStereo(true), but the flag is false in the chosen caps of the GLDrawable - a GLCanvas in my case. Actually, using a GLCapabiltiyChooser, none of the available modes has the stereo flag set to true. Accordringly a later query to glGetBooleanv(GL_STEREO, ..) returns GL_FALSE.

However, my system configuration is perfectly capable of it. For example these programs written in PyOpenGL work perfectly fine:
http://www.geeks3d.com/20090814/stereoscopic-camera-in-opengl-using-pyopengl/
I added the glGetBooleanv(GL_STEREO, ..) to these scripts and the returned value is GL_TRUE.

Can anyone help my enable stereo with JOGL2?

Thanks and Best,
 Michael

7  Java Game APIs & Engines / Android / VBOs broken in GLES2 on: 2010-06-12 01:32:37
VBOs are broken in OpenGL ES 2 (Android 2.2), please vote for an accelerated fix: http://code.google.com/p/android/issues/detail?id=8931
8  Java Game APIs & Engines / JOGL Development / Re: Opengl 3.2 SimpleJOGL on: 2010-05-06 17:41:21
IMHO there is a bug in the code.

The red book says that glBindAttribLocation can only be called before linking the program. If you don't, then you have to use glGetAttribLocation to query for the location of the attrib instead of setting it.

I suppose it doesn't matter here because you only use one attrib, but it should be corrected, again IMHO.

Yes it will be problematic when more attributes are used. However, there is a simple fix: re-linking the program

1  
2  
3  
4  
gl.glLinkProgram(iProgram); 
...
gl.glBindAttribLocation(iProgram, 0, "position");
gl.glLinkProgram(iProgram); //re-link

9  Java Game APIs & Engines / JOGL Development / Re: Pure Offscreen Rendering on: 2010-05-06 17:20:29
thanks for answering!

I hoped pure FBO rendering would be possible (like on the iPhone/Pod/Pad). Guess I stick stick to my 1x1 pbuffer, because I don't like passing the PBuffer class into the 'real' code Smiley
10  Java Game APIs & Engines / JOGL Development / Pure Offscreen Rendering on: 2010-05-06 16:34:18
I want to use JOGL 2.x for a console/terminal based image manipulation program without any GUI/window. Unfortunately, I don't find a way to create and opengl context easily.

I know there are pbuffers, but AFAIK these are platform dependent and not very flexible in the format (floating point formats only?). That is why I use a framebuffer object with a texture2D as color component. That works fine, but it seems I still need a window or pbuffer to create the GLContext. Currently, I use a 1x1 sized pbuffer to get an 'offscreen' opeengl context like this:

1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
GLCapabilities caps = new GLCapabilities(GLProfile.getDefault());
caps.setDoubleBuffered(false);

GLCapabilitiesChooser capsChooser = new DefaultGLCapabilitiesChooser();
GLPbuffer pBuffer = GLDrawableFactory.getFactory(GLProfile.getDefault()).createGLPbuffer(caps, capsChooser, 1, 1, null);

GLContext context = pBuffer.getContext();
context.makeCurrent();

GL gl = context.getGL();

// my offscreen rendering code goes here

context.destroy();


Is this necessary or can I create an opengl context without a pbuffer (and window)?
11  Discussions / General Discussions / Re: Why Sun should make a PS3 JVM on: 2008-09-04 14:21:50
I agree there is no real reason for Sun to make a PS3 JVM atm and in the current situation. 

Actually, I think Sony should create a VM, preferreable the JVM of course  Smiley

Sony will need to put s.th up against X-BOX360 C# development/XNA eventually. Nice Java based PSN titles would be a great start.
12  Discussions / Miscellaneous Topics / Re: New look projectdarkstar.com on: 2008-08-06 14:13:33
looks pretty nice!  Smiley


small error I found on this page:
http://www.projectdarkstar.com/external/projects.html

The SGS C-client links to the AS3-client page...
13  Discussions / General Discussions / Re: Sun to pursue Java-less Java? on: 2008-03-08 08:13:52
I hope Sun will push Scala, too. It's a great language.

+1
14  Java Game APIs & Engines / JOGL Development / Re: glTexSubImage2D - performace issue on: 2007-11-28 10:41:04
I'm experiencing serious performance problems when calling
glTexSubImage2D() with width or height = 1 to copy a thin rectangular
region on a texture (just a vertical or horizontal line)  (running under windows xp)

The hardware usually does a single block lookup (e.g. 16x16 ) although your pixel shader only contains a single textureXXX call. The block is then used for a fragment (some pixel in a small region). Therefore you have to expect slow downs, if your projected vertices are not next to each other or you access the texels sequentially (=linear as you did) or 'randomly' (that's even worse)..

15  Games Center / Archived Projects / Re: Basketball Demo, based on Multibody System with Cloth Simulations on: 2007-11-22 12:57:09
really cool.. I love the style.. reminds me of another world :-)
16  Discussions / General Discussions / Re: Alternative Java-based languages on: 2007-11-06 11:34:47
Personally, I do more and more programming in Scala. It has lots of features mentioned here and its performance profile is equal to Java (or even better like in this particular raytracing benchmark)
17  Discussions / General Discussions / Re: XNA ? on: 2007-08-21 10:50:56
Doesn't LWJGL work for you?

you got me wrong, jogl has them too. But Managaed DX is 2 years behind and doesn't offer them..
18  Discussions / General Discussions / Re: XNA ? on: 2007-08-21 01:21:42
Does Microsoft really support C# devs that well:
DirectX SDK (August 2005) Managed
DirectX SDK (August 2007) C++

Imagine the complains here at JGO if jogl wouldn't have been updated that long.. no access to dx10 features, ..  - terrible! (ok, even carmack doesn't care  Wink)

However, XNA and Video Tutorials are nice..

Regarding "Tao": Last time I tested it it was still really buggy and it took me really long time to install  Sad but, maybe ths has changed already, I don't know..
IMHO the non microsoft way of C# (==mono, toa,..) suffers from exactly the problems Java does: easy deployment and a tool stack. But at least I see more efforts going on here.. (consumer jre, ...)
19  Discussions / Miscellaneous Topics / OpenGL 3.0 is (Nearly) Here; Why Use DirectX? on: 2007-08-21 00:19:23
Actually, a really nice post promoting Java for (3D) Graphics..

OpenGL 3.0 is (Nearly) Here; Why Use DirectX?
20  Java Game APIs & Engines / Tools Discussion / Re: NetBeans OpenGL Pack preview release is out on: 2007-08-16 18:51:55
GREAT!
Especially the GLSL editor and compiler support! (personally I don't care much about the rest..  Smiley)

however: it does not work with nb6 M10, does it?
the screenshots look like nb6, but I got the following error adding the nbm:

Quote
Plugin NetBeans OpenGL Pack Update Center cannot match its dependencies:
module org.netbeans.modules.autoupdate.services > 1.3

I could add it manually with the following url:
https://netbeans-opengl-pack.dev.java.net/updatecenter/updates.xml
but I got an UnsatisfiedLinkError when starting nb..
21  Discussions / Miscellaneous Topics / Re: Carmack did it again on: 2007-08-12 23:24:12
I'm not thinking at the micro-level.

sorry for confusion, that post I answered to 'bitshit'..
22  Discussions / Miscellaneous Topics / Re: Carmack did it again on: 2007-08-12 23:22:57
All the above is still next to impossible. Everything should be put into arrays or buffers (no objects anywhere) before this would have a chance. If one is making such an effort, he can as well port it himself. bytecode analysis and transformation won't get you anywhere, because traversing all those (dynamic) object-references with random pointers, is a horrendous datastructure for SIMD related code.

I think the usage of classes of type T as well as Arrays of them T[] should be fine, if:
 - the are declared final
 - contain only primitives and primitve arrays fields

checking the referred class attributes and method paramters should not be difficult.
23  Discussions / Miscellaneous Topics / Re: Carmack did it again on: 2007-08-12 23:17:16
I think this is an unrealistic expectation.

The moment there is 1 method-call or object-field reference within the bytecode, which (return)value can change any time, it's basicly impossible to port it to GLSL and extremely hard to port to native code.

You'd really need a Domain Specific Language to truely transform to vector-math. Doing it on the GPU adds a significant overhead of copying the data back and forth all the time, so even when the transformer is there, you'd have to specificly design your code around it, instead of trying to find patterns in existing bytecode.

Actually, I'd prefer a DSL for vecmath. In principle that's also what it is, but embedded in Java. This has the advantage that the programmer doesn't need to call things like 'execute(VecMathProg). On the other hand Java doesn't allow to embed it nicely: no operator overloading, implicit casts).

However, it would be easier to translate a DSL created upon Groovy (or Scala) to a native function, than a working at the bytecode level.
24  Discussions / Miscellaneous Topics / Re: Carmack did it again on: 2007-08-12 23:04:16
don't think at the micro level.

I'm NOT talking about translating a single math API call to JNI, like vector4.add(vecto4 right), but about a methods using such an API to be compiled to a single native method using SIMD.
For example a method performing vertex blending: it's likely to iterate over say 2k-50k vectors each transformed by 1-4matrices for a single virtual character - that's when its worth to use SIMD.

Now we agreed that translating custom byte code to a native function using SIMD is very difficult (even for SUN people :-)),. However, things become much easier if the method only contains operations on primitive types, no method calls except to a special math-lib and no or only selected control flow constructs,.. (the more restrictions, the easier it is ;-))
25  Discussions / Miscellaneous Topics / Re: Carmack did it again on: 2007-08-12 01:33:39
I never talked about many JNI calls

the idea is if the method uses only certain instructions and apis (with vectors4 and matrix4x4), it can an intermediate, pre-compiled language like GLSL, a JNI lib (e.g. jogl) can execute the code instead of the java one. Of course you can build your own simple vector language and with compiler using SIMD and a JN-lib to compile and call the script.

=> Fully cross platform, scales with time.

using instrumentation (and asm) you can easily extract the method's code, transform and replace it ..

instrumentation can be used each time a vm starts or as a compile step.

in the first case, a c++/glsl/.. compiler is needed on the users pc, but one can do additional optimizatiosn as one knows the exact cpu (#cores, instructions set,..)
in the latter one, you simply put multiple versions up: e.g. standard, intel-performance-pack, opengl-pack, ..



26  Discussions / Miscellaneous Topics / Re: Carmack did it again - SMID & Java on: 2007-08-11 02:34:33
Hmmm how could that library help? From what I understand it compiles javasource to bytecode? For SIMD or other lowlevel stuff the JVM would need to support it, or you mean by redirecting specific calls to a JNI library?

yes redirecting can be done, if could one usees certain instructions/library calls.
27  Discussions / Miscellaneous Topics / Re: Carmack did it again - SMID & Java on: 2007-08-07 21:15:41
Getting off the high horse, we could go the "Mono way": SIMD support in Mono

I like their way of bytecode - to - GL(SL) conversion with attributes (annotations).

[edit] asm looks like cool library doing this in java [/edit]
28  Discussions / Miscellaneous Topics / Re: Carmack did it again on: 2007-08-04 17:22:26
good point Riven,

but do you think more than 50% of CPU consuming code in a game uses SMID? Otherwise the factor should shrink..



Anyway, I also would prefer hotspot using SMID instructions wherever possible/useful instead of having an API. There reason are:

  • I'm lazy: even there is only a speed up of 2x for a dedicated method and I could have achieved 4x with the API, it is likely that I also get an improvement in others places, I would not have used SMID calls explicitly..
  • Such an API probably changes frequently, which is why it is not a good idea to put it in the core library.*

*game developers usually don't care, because most changes after one is done are bug-fixes, so one can stick to the old one (like DirectX) - that's why IMHO a temporary API com.sun.xxx would be great.

Regarding the "other RFE":


I remember asking about the details on a java.net hosted blog (sorry don't rember which one):

IIRC it was a documentation bug, more precise: one of the jvm developers identified a single/few circumstances where SMID can be used and did an implementation. Afterwards, he/she filled the rfe, to document his/her work. This is a step in the right direction, but yet far away from trying to use SMIDs instruction wherever possible - which is what the title may suggest.
29  Discussions / Miscellaneous Topics / Carmack did it again on: 2007-08-04 11:04:58
And as far as Java is concerned, he called it a "good attempt at making something run at a tenth of the speed it should."

Of course he was taking about Java on mobile phones on the QuakeCon 2007..
30  Discussions / General Discussions / Re: Anticipated games from E3 ( NiGHTS! ) on: 2007-07-15 12:07:12
still waiting for Heavy Rain - the demo at E3 2006 was that awesome. Everyone who has not seen The Casting should check out the hires video.
Pages: [1] 2 3 ... 11
 

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

The first screenshot will be displayed as a thumbnail.

xsi3rr4x (57 views)
2014-04-15 18:08:23

BurntPizza (55 views)
2014-04-15 03:46:01

UprightPath (68 views)
2014-04-14 17:39:50

UprightPath (51 views)
2014-04-14 17:35:47

Porlus (68 views)
2014-04-14 15:48:38

tom_mai78101 (92 views)
2014-04-10 04:04:31

BurntPizza (153 views)
2014-04-08 23:06:04

tom_mai78101 (249 views)
2014-04-05 13:34:39

trollwarrior1 (205 views)
2014-04-04 12:06:45

CJLetsGame (212 views)
2014-04-01 02:16:10
List of Learning Resources
by SHC
2014-04-18 03:17:39

List of Learning Resources
by Longarmx
2014-04-08 03:14:44

Good Examples
by matheus23
2014-04-05 13:51:37

Good Examples
by Grunnt
2014-04-03 15:48:46

Good Examples
by Grunnt
2014-04-03 15:48:37

Good Examples
by matheus23
2014-04-01 18:40:51

Good Examples
by matheus23
2014-04-01 18:40:34

Anonymous/Local/Inner class gotchas
by Roquen
2014-03-11 15:22:30
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!