ATI Matrox - performance question

Hello Everyone
Ive got serious problem with performance under Windows with cards manufactured by ATI or MATROX?
Is there a glitch of some sort or it is just my code? Im using nehe FPSAnimator class as in Nehe example and it works splendid under Nvidia, but under ATI 9200 it stops and makes something about 1-2 fps the same under MATROXG400. It cant be too big to render problem becouse i put it into work on P500+GF2MX and it went well. On my Athlon2.5Ghz 512MB + GF5200 its a pure speed. (also under MATROX AND ATI cards- system usage goes very high - to 90-95% on NVIDIA… not). Ive read about problems with rendering in previous topics but dont get the idea how to repair it.
I used setVisible(true) before adding canvas so this is ok. My app is not fullscreen. Ah, and im using newest JOGL implementation.
Could someone help me becouse its n-th hour of fightning with my indolence of programming OpenGL in JAVA, and im close to shoot my head off… :-/

help:-)

Hello
Ok, maybe this will help - when I deleted all textures it goes well, so maybe there is some sort of proper initialization of textures in JOGL?

Thanks for (if any) help

Matrox cards have never been known for stellar performance - either in DX or GL. You may have hit a software fallback for them. As for the ATI card, sounds like it is also doing a software fallback, so you may want to investigate driver issues first. All ATI cards using the Radeon chipset will have hardware accelarated drivers for GL.

Matrox cards have never been known for stellar performance - either in DX or GL.
Hard to disagree but my app is not so power consuming.
You may have hit a software fallback for them.
this means:
capabilities.setHardwareAccelerated(false);
in that case it does not change anything at all

As for the ATI card, sounds like it is also doing a software fallback, so you may want to investigate driver issues first.
Drivers are newest - guess its not the case
All ATI cards using the Radeon chipset will have hardware accelarated drivers for GL.
But how to use it?:slight_smile:

Thanks very much:)
Hope someone will help:)

P.S.
And when i turn off every textures in the scene it sudenly goes ok…

What sizes are your textures? Have you checked that they are powers of 2? If not, and you’re automatically using the non-power-of-2 texture extensions, it could be forcing your drivers back into software emulation mode. Drivers will use hardware accelaration by default unless forced to otherwise.

What sizes are your textures? Have you checked that they are powers of 2?
i use 14 texture files (jpg - could that be a problem?) where the biggest one is 1024x1024 (there are different sizes of textures) and as far as I now they are a power of 2 If not on my GeForce object simply isnt texturized.
Drivers will use hardware accelaration by default unless forced to otherwise.
How to check while app is runing if hardware mode is enabled? Capabilities have those getters but… this is capabilities object and setting Opengl in hardware acceleration mode doesnt mean it will go - am I right?

Thanks much, hope this will clear up soon:)

You can check for maximum texture size supported by calling


public int getMaxSize()
{
    int maxsize;
    gl.glGetIntegerv(GL.GL_MAX_TEXTURE_SIZE, maxsize);
    return maxSize;
}

IIRC this means the max texture dimension is a square (maxsize, maxsize) rather than a rectangular shape. I’m not sure if JOGL has ported the PROXY_TEXTURE stuff but maybe that would help?

However I would recomend changing to say the PNG format for your textures since JPEG is propriatory(spelling fairy?) and uses a loss-y compression.

HTH, SNR

Hello
Hmm it showed me 4096 but does it mean that max textures are size of squeare of 4096 or4069x4096?
I guess it isnt about oversize of texture but i make mistake in loading it… however i use nehe loader. Then i put everything into lists (texture+ object) in init() and in display i only manipulate on lists… maybe i should initialize textures somewhere else? Could someone provide or point me some place where i can see correctly written code that was actually tested on ati cards and it worked?
BTW:
public int getMaxSize()
{
int maxsize;
gl.glGetIntegerv(GL.GL_MAX_TEXTURE_SIZE, maxsize);
return maxSize;
}

To be honest it goes with int[] not int but dont know why. As for now i think it is non optimized or something (or in some cases there are more max texture sizes however i dont get idea when is that possible).

Thanks for help:)

That code snippet won’t work. No pass-by-ref-primitives in Java.

Cas :slight_smile:

Which one mine?
In my program it does however you have to change int to int[] of length 1. And also i dont make exactly a function. I put it directly into display method and draw it on screen:)
Do you have any advise to me what to do? Im completely stuck and dont know what to do.

Thanks :):slight_smile:

Is this because its an array rather than a primitive like float???

Yeah ut whats the point of using array for that? it should pass only one supported value? … or am I wrong?

Ok I believe that it goes like this, simply speaking of course :slight_smile:

Java has two data types, Primitives and References

Primitives are passed “by value”, i.e methods and assignments make of copy of the variable and manipulate that.

This is not true of reference types (Classes) which is really just a primitive entity, like a C pointer, whose data we can not examine. This means that when passed to a method the method copies the value of the reference not the object. And a reference variable can not be created or changed without being assigned to an object

Java is a proper OOL in that arrays are actually fully fledged classes so that means int[] data produces a reference to an array which can be “repointed” to the ouput of gl.glGetIntegerv(GL.GL_MAX_TEXTURE_SIZE, int[] data);. Otherwise the method would have to return a primitive since we can not reassign passed primitives, like my int maxsize.

SNR

[quote]Yeah ut whats the point of using array for that? it should pass only one supported value? … or am I wrong?
[/quote]
You’re not passing a value, you’re reading it. You need to give it a place to put the value that it’s reading it. Have a look at the C version and it say *int - A pointer to an int. Since Java does not have pointers, you have to do the closest thing, which is pass an array in so that you can copy something into it.

true:) … btw what about problem with ATI?
Ive read about “gotchas” & jogl but i still dont know what are these “gotchas”. Maybe Im blind and there are somewhere documented (please could you tell me where?) “JOGLgotchas”. I think my problem goes becouse of some stupid mistake and GF cards are simply optimizing it where ATI… dont (Im starting to hate this manufacturer).

Pliiiz help help!:slight_smile: