Show Posts
|
|
Pages: [1] 2 3 ... 6
|
|
1
|
Java Game APIs & Engines / JOGL Development / Re: Grid - Triangle Strip/Vertex Normals algorithm
|
on: 2009-02-03 17:17:07
|
@princec Is this true? I always thought that at least the space saving gives some benefits, so I am using triangle strips in my terrain implementation...
With DrawElements you still only have to store the unique vertices, and the index array will reference the shared vertices how ever many times necessary. To keep performance similar to triangle strips you will want to make sure you draw all triangles with shared vertices close enough together that the shared vertices will still be in the cache.
|
|
|
|
|
3
|
Java Game APIs & Engines / JOGL Development / Re: glDrawElements weirdness
|
on: 2009-01-01 02:26:29
|
|
The type argument is used just to indicate the size of the data to expect, so signed or unsigned should be the same size but the GL spec says unsigned only otherwise it'll throw an error and ignore the command.
And while Java only supports signed values the underlying GL implementation will still treat the values as unsigned so if you have your bit patterns all figured out correctly you can still supply it with the upper half of the 2^n index values :-).
|
|
|
|
|
4
|
Java Game APIs & Engines / JOGL Development / Re: RLE compression for textures
|
on: 2008-12-27 07:11:07
|
|
I guess it all comes down to how you are accessing the data. If you expect any sort of random access just say no to RLE. You say S3TC won't cut it, but spend a little more time looking at the algorithm, you'll see that there's nothing requiring it be applied to 4x4 blocks, you can actually choose any block size you want. Same thing goes for the reconstruction equations. All of which should be easily doable in a shader.
|
|
|
|
|
5
|
Java Game APIs & Engines / JOGL Development / Re: [BUG] Loading custom mipmaps fails
|
on: 2008-11-23 18:07:10
|
|
I think I see what you mean, there's no level argument to Texture.updateImage(), sorry about that. I've not looked at that code but I would imaging that call in particular is probably a fairly simple wrapper around glTexImage. The fastest way to get the changes into the project would be to make them yourself and submit them. Hopefully Ken Russell can chime in a bit here on how to do that.
|
|
|
|
|
12
|
Java Game APIs & Engines / JOGL Development / Re: Initializing uniforms in glsl
|
on: 2008-09-11 09:33:44
|
|
You are correct there are nearly identical initializations shown in the spec.
Nvidia uses their Cg (Nvidia's shader language) compiler for GLSL as well, so something that might be worth looking at is whether or not Cg allows uniforms to be initialized like that. That will at least help narrow it down if it is a driver issue.
|
|
|
|
|
18
|
Java Game APIs & Engines / JOGL Development / Re: OpenGL 3.0
|
on: 2008-08-12 08:08:10
|
|
All in all, not as ground breaking as they had lead us to believe but a worthwhile and necessary update.
The biggest problem I can see is that they didn't immediately deprecate the features they decided upon. Instead by extending their life it'll only make the process of finally removing them that much more painful.
|
|
|
|
|
20
|
Java Game APIs & Engines / JOGL Development / Re: frame rate issue
|
on: 2008-08-04 16:57:15
|
Triple buffering only helps in a few borderline cases mind you, and comes at the cost of a fair chunk of VRAM, the use of which might actually slow down your application further if it's texture upload bound. Cas  I'd hardly say that it uses a fair chunk of memory, it's only a single extra back buffer, width x height x bit-depth, which would be roughly comparable to a single additional texture without mipmaps.
|
|
|
|
|
21
|
Java Game APIs & Engines / JOGL Development / Re: frame rate issue
|
on: 2008-08-04 09:02:34
|
|
You usually see this when you've enabled v-sync (vertical sync) for your video card and then the timing is off slightly for when a frame is ready versus when the display is ready to display it. When this occurs the frame is delayed a refresh before it is displayed (which explains the exact multiples of the refresh rate), and in double buffered rendering the front and back buffers can't be swapped while waiting for the display.
The solution is called triple buffering, and unfortunately there aren't many (any?) tutorials on how to implement it with OpenGL nor do I have that knowledge.
|
|
|
|
|
22
|
Java Game APIs & Engines / JOGL Development / Re: Double Buffering in JOGL
|
on: 2008-07-24 06:29:34
|
|
Setting double buffered in the capabilities object is the only thing that needs to be done.
And unfortunately I think you misunderstand what double buffering does. It doesn't really make animation smoother, rather it avoids tearing, and at that you need to have vertical sync (v-sync) on to completely avoid tearing.
Now what is tearing you might ask? It's an artifact that shows up in double buffering with v-sync off and when the monitor is part of the way through the verticle refresh the video card then directs it to use the other buffer, causing the image on the screen to tear because the first portion was drawn from one rendered image and the rest from a second image. In a single buffered display, tearing will be seen as an unfinished image in the process of being draw and then when finished probably abruptly cleared and the process starts over again.
I know that wasn't the clearest description but I hope it helps.
|
|
|
|
|
25
|
Java Game APIs & Engines / JOGL Development / Re: Problem in GLSL
|
on: 2008-06-18 17:19:42
|
The HP laptop has a ATI Mobility Radeon 7500 4x AGP, which should be OK. But you need a driver update (which might be difficult without using hacked drivers), so search the HP support site. If it's actually a Radeon 7500 then no driver up date will get GLSL working, Radeon's first got GLSL support with the 9500-9800 series. Of course they've wrapped their number scheme around and it's soon going to be hard to tell what's what if you're try to support legacy parts. The other three afaik have Intel integrated graphics (GMA 950), which are considered to have bad drivers. Anybody out there used GLSL on one?
As of this moment, no Intel part supports GLSL on Windows, while some do on Mac.
|
|
|
|
|
26
|
Java Game APIs & Engines / JOGL Development / Re: Error swapping buffers and glTexParameteri
|
on: 2008-06-17 03:27:40
|
BUT now: When I activate a DebugGL, I can find an exception in Exception in thread "AWT-EventQueue-2" javax.media.opengl.GLException: glGetError() returned the following error codes after a call to glTexParameteri(): GL_INVALID_ENUM at javax.media.opengl.DebugGL.checkGLGetError(DebugGL.java:12715) at javax.media.opengl.DebugGL.glTexParameteri(DebugGL.java:9106) at com.sun.opengl.util.texture.Texture.updateImage(Texture.java:596) at com.sun.opengl.util.texture.Texture.updateImage(Texture.java:381) at com.sun.opengl.util.texture.Texture.<init>(Texture.java:182) at com.sun.opengl.util.texture.TextureIO.newTexture(TextureIO.java:445)
What actually happens there is that glTexParameteri is called with argument CLAMP_TO_EDGE. According to the OpenGL spec, this feature was introduced with version 1.2, which is supported by the installed graphics card, see some lines above. We might be able to help more if you shared some of the pertinent code. The thing is, that I want to deploy a stable application, not a program that work on some pcs. So I would be interested in finding out why this error occurs. Unfortunately Unichrome and stable don't exactly go together, thankfully they are fairly rare. In comparison the much complained about Intel IGPs are stunningly compatible and feature rich(and VERY common). Vendor: S3 Graphics Renderer: VIA/S3G UniChrome IGP/MMX/SSE Version: 1.2
|
|
|
|
|
27
|
Java Game APIs & Engines / JOGL Development / Re: JOGL and software pixel shader?
|
on: 2008-06-11 18:50:25
|
I really shouldn't be posting while at work, but I'm stalled waiting for someone else at the moment so here we go!  But hey, since you seem to know a bit about this, maybe you can tell me if I can achieve this full-screen effect with the arb_fragment_program? And if yes, please can you point me to a demo? I searched google thin trying to find fullscreen effect demos using the arb_frag... but I couldnt really land anything. The basic algorithm for doing it is... 1.) draw your scene 2.) get your scene into a texture some how (FBOs, pbuffer + Render_texture, glCopyPixels) 3.) bind your scene texture 3.) draw a fullscreen quad with a fragment program that looks up the scene texture and performs your effect. But hey, horraaaayh for having anything remotely useful on my card hehe. I guess the arb_frag program is quite common! If most people have this, i will consider adding it to my game. Well the 945 is about as low end as it gets and is frighteningly common. Basically anything from ATI or Nvidia should be well beyond a 945 in features, the Geforce 3 and Radeon 8500 supported these features I believe, which should give you a feel for the era the 945 was designed for.
|
|
|
|
|
28
|
Java Game APIs & Engines / JOGL Development / Re: JOGL and software pixel shader?
|
on: 2008-06-11 16:22:37
|
|
You've got it, that second one on the list, GL_ARB_fragment_program, and I assume the vertex version is somewhere in there too.
As for the lack of multisample extension I'm vaguely remembering there is no support for that, though strangely enough isn't there an option for it in their control panel? Or is that anisotropic filtering that they have, but is limited to a really low sample count?
|
|
|
|
|
29
|
Java Game APIs & Engines / JOGL Development / Re: JOGL and software pixel shader?
|
on: 2008-06-11 07:17:51
|
How do you sleep at night? Linking me to a dot.net program from a java forum heehehhe.. Believe it or not I don't program Java for a living. Unfortunately I get paid to write C and every day I'm reminded how much I love Java. no seriously thanks alot, im gonna see what I can do with this information. This laptop shipped with *cough*vista*cough*, and since I'm using ubuntu 8.04 and windows XP now, maybe the drivers wont support it? I guess they should, but I don't know much about drivers. Anyhow thanks, its lovely to get all this help  The 945 does support the ARB programs, at least under XP and Vista, it's just a matter of making certain you have the appropriate drivers installed. Check the vendor string, if it says anything about GDI, Microsoft, or Mesa under Linux then you need to update your drivers, and even if it doesn't I'd look into getting the latest drivers.
|
|
|
|
|
30
|
Java Game APIs & Engines / JOGL Development / Re: JOGL and software pixel shader?
|
on: 2008-06-10 16:27:55
|
The 945 does support the ARB programs, it's possible you need to update/install drivers for your card though. Here's a handy little program that will show you all the interesting details of your cards OpenGL implementation... http://www.realtech-vr.com/glview/And as for the multi-sampling, if my memory serves me correctly the Intel part does support it but with only 2 samples, so the 4 sample examples probably won't work (change the 4 to a 2).
|
|
|
|
|
|
Add your game by posting it in the WIP section,
or publish it in Showcase.
The first screenshot will be displayed as a thumbnail.
|
|