Java-Gaming.org    
Featured games (79)
games approved by the League of Dukes
Games in Showcase (477)
Games in Android Showcase (107)
games submitted by our members
Games in WIP (535)
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
1  Java Game APIs & Engines / JOGL Development / Re: *lightWeight" problem on Leopard on: 2008-01-14 14:23:59
ok, i found the problem
i have a call to
UIManager.setLookAndFeel("javax.swing.plaf.metal.MetalLookAndFeel");
and i guess this call must be messing around with the LightWeightPopup (but somehow only on Leopard)
2  Java Game APIs & Engines / JOGL Development / *lightWeight" problem on Leopard on: 2008-01-10 16:25:59
Hi

I'm developing a project in JOGL. Everything worked well so far, but since I upgraded my macbook to Leopard, the JMenuItem pop under the JOGL canvas. I do have the following line preventing that behaviour to happen on linux and windows (and osx 10.4 if i remember well)
JPopupMenu.setDefaultLightWeightPopupEnabled(false);

is this a known bug ?
3  Java Game APIs & Engines / JOGL Development / Re: Loading the libraries dynamically on: 2007-07-09 16:05:06
thanks, works great
4  Java Game APIs & Engines / JOGL Development / Loading the libraries dynamically on: 2007-07-06 15:42:49
Hi all

I developped an application using jogl and everything works fine when I launch it as a standalone version with java -Djava.library.path=....

but now my application is to be used (as a pluggin) from another application and i cannot copy the libs to the client jre, and i have no control over the way the application is launched (i cannot enforce the use of -Djava.library.path=...)

i tried to happend my library path to the current one using System.setProperty("java.library.path", ...); despite the fact that the path is correctly set, it won't find the libraries (I have read that using setProperty() with java.library.path is useless since the path is only scanned once,  at startup ...)

Does anyone have an idea, on how to load the jogl library dynamically ?

Thanks in advance
5  Java Game APIs & Engines / JOGL Development / Re: freezing when poping a JOptionPane in a picking method on: 2007-05-04 16:44:22
that was so obvious that i didn't though of it !  Grin

Thanks a lot bleg  Cheesy
6  Java Game APIs & Engines / JOGL Development / freezing when poping a JOptionPane in a picking method on: 2007-05-04 15:17:41
Hi there,

I have a picking method in my application (called by the display method of the GLEventListener)
This methods is supposed to do some operations, or display a WarningMessage in a JOptionPane if the operation in invalid.

but the JOptionPane.showMessage() freeze the application when called from the same thread that display

do you have a solution ? (using SwingWorker or something else)

Thanks
7  Java Game APIs & Engines / JOGL Development / Re: Problem with multiple jogl GLCanvas on: 2006-05-29 13:12:46
i had this problem too, it seems there are too much jogl thread time compared to AWT thread time

if only one of your canvas is "moving"  at the time and this others display a still picture as long as noonne touch them (this was my case) you should stop all "inactive canvas"'s animators and only start the animator of the one  canvas that is moving

but if you have, lets say, two simultaneous display of a moving scene from different point of view, i don't know what to do
8  Java Game APIs & Engines / JOGL Development / Re: jogl application crashing X, how to debug ? on: 2006-05-29 11:19:21
since i tried to debug it (with tracegl) i was unable to crash my soft Grin
9  Java Game APIs & Engines / JOGL Development / Re: jogl application crashing X, how to debug ? on: 2006-05-22 10:10:56
with the other jre (gcj), the this.getContentPane.add(canvas); crashed the application

now with j2sk1.4.2 the application works, but still does this xlib problem at a random point.
sometimes it crashes almost immediatly, sometimes i can use it for ten minutes

I'll try to log exactly every opengl commands and see if there is a correlation at crashing point
also, a friend of mine suspect it comes from the fact that i'm running sid/testing version of debian


but what is weird is that a add absolutly no problem before april 18th, so either I changed something import in my code at that point (i'll check in the  CVS) or I had a mother board failure (the RAM is ok)
10  Java Game APIs & Engines / JOGL Development / Re: jogl application crashing X, how to debug ? on: 2006-05-19 14:09:58
Ok, problem solved

I narrowed down the code to the minimum crashing code. The problem is in the GLCanvas, i don't even need a GLEventListener
the crashing code is when i add the GLcanvas to the JFrame :

1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
22  
23  
package fr.ustrasbg.ibmc.assemble;
import javax.swing.*;
import javax.media.opengl.GLCanvas;
import java.awt.*;

public final class Main extends JFrame
{
    static Main window;
    public static void main(String[] args)
    {
        window = new Main();
    }

    public Main()
    {
        JPopupMenu.setDefaultLightWeightPopupEnabled(false);
        GLCanvas canvas = new GLCanvas();
        canvas.setSize(800, 800);
        this.getContentPane().add(canvas, BorderLayout.CENTER);// this line crashes
       this.pack();
        this.setVisible(true);
    }
}


in fact, when upgrading ma system, my version of java was replaced by /usr/lib/jvm/java-gcj/jre/bin/java
which have problems with AWT
11  Java Game APIs & Engines / JOGL Development / Re: jogl application crashing X, how to debug ? on: 2006-05-19 10:40:23
i checked, every demo works Cry
i will check tracegl
12  Java Game APIs & Engines / JOGL Development / Re: jogl application crashing X, how to debug ? on: 2006-05-18 18:38:52
ARGLLL
I moved to 2.6.16-1-686, with a NVIDIA card and last nvidia drivers on Xorg 7.0.0
i launch my application and i get
Xlib: unexpected async reply (sequence 0x12e)!

I thought this was an ATI bug, is there some way that my jogl code is doing that ?
13  Java Game APIs & Engines / JOGL Development / thread question : how to impose the Main-*** queue instead of the awt-eventqueue on: 2006-05-15 15:02:42
Hi all

I want some actions to take place in a Main-***** thread and not in a AWT-EventQueue-*** thread

but those actions are targetted by a JMenuItem, and thus follow the AWT event pathway

What I do know is launch a Thread from the main() with a
run()
{
   while(true)
   {
      if(flag)
      {
          //do  the actions
         flag = false;
      }
      yield();
   }
}

and the JMenuItem sets the flag to true, when i need the code to be executed

the problem is that the while(true) yield(); take 100% of the CPU (though it is not realy slowing the computer)

but if a start/stop the thread just when i need instead of starting it withing the main(), it ends up in the AWT-EventQueue, and that is bugging the display() thread of my renderer


thx for any clue
14  Java Game APIs & Engines / JOGL Development / Re: Nurbs (Don't worry, i'm not asking why its not in JOGL) on: 2006-05-14 22:14:28
yes, i managed to make JGeom work
15  Java Game APIs & Engines / JOGL Development / Re: jogl application crashing X, how to debug ? on: 2006-05-09 14:43:30
it also crashed with -Djogl.GLContext.noopt

my drivers are fglrx-driver_8.14.13-1_i386 for the the ATI Radeon 9600

16  Java Game APIs & Engines / JOGL Development / Re: jogl application crashing X, how to debug ? on: 2006-05-05 11:49:03
Hummm

it seems that the crash occurs where later versions of jogl would do the "xlib unexcpeted async sequence" stuff ....
17  Java Game APIs & Engines / JOGL Development / jogl application crashing X, how to debug ? on: 2006-05-05 11:18:47
Hello everybody

my application is, after a random amount of time, crashing X :
i can move the mouse, but clicking has no effect, keyboard is not responding (CTRL-ALT-DEL, CTRL-ALT-F123456...)
but i can still access the computer via ssh (killing java has no effect)

at this moment i was unable to reproduce this on another computer (with another ATI card, not the same model however)

I guess that a certain sequence of opengl command are bowsering X ...
how can i determine the last 10-20 opengl commands before the crash ? is there a log somewhere ? can i create one with DebugGL ?


thx

(i'm under Debian 2.6.11-1-686, x.org)
18  Java Game APIs & Engines / JOGL Development / Re: Xlib: unexpected async reply on: 2006-03-31 10:32:24
ok it seems to be working with beta3 (feb 17 20006)
i can't see any efficiency lack between this release and previous ones
19  Java Game APIs & Engines / JOGL Development / Re: Xlib: unexpected async reply on: 2006-03-30 19:59:13
its the same asnyc error yes
20  Java Game APIs & Engines / JOGL Development / Re: Xlib: unexpected async reply on: 2006-03-30 19:42:53
non, i have the same problem with a desktop
21  Java Game APIs & Engines / JOGL Development / Re: Xlib: unexpected async reply on: 2006-03-30 18:34:02
my application is crashing with the latest nightly builds too

it is the first upgrade of jogl i did for two month or so
and during 3-4month i haven't upgraded my system (you may be aware of a certain drivers problem with the latest versions of xorg)

i can't figure out how to check my version of xlibs

my system is a debian, with an ati ( Cry ) 9600

please, tell my all the informations you need to know

also do you know the last 'stable' version regarding this issue ?
22  Java Game APIs & Engines / JOGL Development / Re: Webstart vs. jre/lib/ext on: 2006-03-02 14:41:06
i like deploying my apps in a .zip or .tgz file

the user extract it where he wants and click on the icon under windows or runs the shell script under linux

i think javaws is good, but as an nd user it doesn't allow much control over the application
23  Java Game APIs & Engines / JOGL Development / Re: Webstart vs. jre/lib/ext on: 2006-03-02 10:44:18
yes i also use the  -Djava.library.path method, and i think it's "easier"  than webstart
24  Java Game APIs & Engines / JOGL Development / Use of progress bar, splash screen and other threaded stuff on: 2006-02-24 14:16:38
Hi,

In my main window i have a menu bar, the canvas for jogl, and a progress bar
when a compute something big i want my progress bar to move

but the bar only starts moving when the computation is over and stops directly

i also tried to use a splash screen instead, and it the same, the splash screen appears at the beginning of the computation, but its containt is only drawn once the compuation is over

I know this must be a threading problem, but i don't see how to work around. Is it related to the light/heavy weight "problem" ?

does anyone have a example of code ?
25  Java Game APIs & Engines / JOGL Development / Re: setting position on: 2006-02-24 10:26:27
the camera doesn't move

if you want to point the camera somewhere you can use glu.gluLookAt();
26  Java Game APIs & Engines / JOGL Development / Re: quadric crashing, when fog enabled on: 2006-02-24 10:24:17
i just wonderer if "incompatible" opengl commands existed Smiley
i used my own implementation of sphere instead of glu's and it works fine

but it is not only sphere, cylinder or glutCube too, so maybe it is the GLU.SMOOTH or GLU.OUTSIDE that is incompatible ?
27  Java Game APIs & Engines / JOGL Development / Re: setting position on: 2006-02-23 15:51:12
if i'm not mistaken the translation is the right column of the transformation matrix
28  Java Game APIs & Engines / JOGL Development / quadric crashing, when fog enabled on: 2006-02-23 15:17:40
Hi


When i try to draw a sphere trough GLU everything works fine, but when fog is enabled it crashes with :
Quote
Caused by: javax.media.opengl.GLException: glGetError() returned the following error codes after a call to glEnd(): GL_INVALID_ENUM
   at javax.media.opengl.DebugGL.checkGLGetError(DebugGL.java:9787)
   at javax.media.opengl.DebugGL.glEnd(DebugGL.java:1510)
   at com.sun.opengl.impl.GLUquadricImpl.drawSphere(GLUquadricImpl.java:888)
   at javax.media.opengl.glu.GLU.gluSphere(GLU.java:1172)

my fog code :
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
22  
23  
24  
    public void applyFog()
    {
       if(fog)
        {
            gl.glDepthFunc(GL.GL_LESS);
            gl.glDepthRange(-1,1);
            if(!gl.glIsEnabled(GL.GL_DEPTH_TEST))
                gl.glEnable(GL.GL_DEPTH_TEST);
            gl.glFogi(GL.GL_FOG_MODE, GL.GL_LINEAR);
            gl.glFogf(GL.GL_FOG_DENSITY, fogDensity);
            gl.glFogf(GL.GL_FOG_START, depth/2);
            gl.glFogf(GL.GL_FOG_END  ,  depth);
            gl.glFogfv(GL.GL_FOG_COLOR, background.getRGBOpenGl(), 0);
            if(!gl.glIsEnabled(GL.GL_FOG))
                gl.glEnable(GL.GL_FOG);
            if(gl.glIsEnabled(GL.GL_SMOOTH))
                gl.glDisable(GL.GL_SMOOTH);
        }
        else
        {
            if(gl.glIsEnabled(GL.GL_FOG))
                gl.glDisable(GL.GL_FOG);
        }
    }

I add added test, not to enable.disable something twice, but it still crashes

GLU's  crashing code
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
22  
23  
24  
25  
26  
27  
28  
29  
30  
31  
32  
33  
      if (!textureFlag) {

        // draw +Z end as a triangle fan

        gl.glBegin(GL.GL_TRIANGLE_FAN);

        gl.glNormal3f(0.0f, 0.0f, 1.0f);

        gl.glVertex3f(0.0f, 0.0f, nsign * radius);

        for (j = 0; j <= slices; j++) {

          theta = (j == slices) ? 0.0f : j * dtheta;

          x = -sin(theta) * sin(drho);

          y = cos(theta) * sin(drho);

          z = nsign * cos(drho);

          if (normals) {

            gl.glNormal3f(x * nsign, y * nsign, z * nsign);

          }

          gl.glVertex3f(x * radius, y * radius, z * radius);

        }

        gl.glEnd();

      }


is there an incompatibility between my fog code et glu's code ?
29  Java Game APIs & Engines / JOGL Development / Re: differences between linux & windows on: 2006-02-12 13:49:19
yes, that's true, and i though about that afterwards, but shouldn't i get an "GLContext not current" exception ?

anyway I think if I delay the call to that function, so that it happens while the context is current it will work
30  Java Game APIs & Engines / JOGL Development / Re: differences between linux & windows on: 2006-02-10 18:05:21
ok, i have the same under linux & windows now

but a wierd thing is, once the lights are set, i can't change them :

i tried  modifiying the lights parameters from a widget, the next method is called, but i see no effect on the scene
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
    public void setLight(GL gl)
    {
        System.out.println("Ambient "+lightAmbient+ " specular "+lightSpecular+" diffuse "+lightDiffuse+" materialShininess "+materialShininess);
        gl.glDisable(GL.GL_LIGHTING);
        gl.glDisable(GL.GL_LIGHT0);
        gl.glDisable(GL.GL_COLOR_MATERIAL);

        gl.glLightfv(GL.GL_LIGHT0, GL.GL_AMBIENT, new float[]{lightAmbient,lightAmbient,lightAmbient}, 0); // Setup The Ambient Light
       gl.glLightfv(GL.GL_LIGHT0, GL.GL_SPECULAR, new float[]{lightSpecular,lightSpecular,lightSpecular}, 0); // Setup The Specular Light
       gl.glLightfv(GL.GL_LIGHT0, GL.GL_DIFFUSE, new float[]{lightDiffuse,lightDiffuse,lightDiffuse}, 0); // Setup The Diffuse Light
       gl.glLightfv(GL.GL_LIGHT0, GL.GL_POSITION, lightPosition, 0);            // Position The Light
       float specularReflection[] = {1, 1, 1, 1};
        gl.glMaterialfv(GL.GL_FRONT, GL.GL_SPECULAR, specularReflection, 0);
        gl.glMateriali(GL.GL_FRONT, GL.GL_SHININESS, materialShininess);

        gl.glEnable(GL.GL_COLOR_MATERIAL);
        gl.glEnable(GL.GL_LIGHTING);
        gl.glEnable(GL.GL_LIGHT0);
        gl.glEnable(GL.GL_NORMALIZE);

    }


is it only possible the set the light parameters once ? or within a given block ?
Pages: [1] 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.

E.R. Fleming (12 views)
2014-07-29 03:07:13

E.R. Fleming (4 views)
2014-07-29 03:06:25

pw (39 views)
2014-07-24 01:59:36

Riven (39 views)
2014-07-23 21:16:32

Riven (26 views)
2014-07-23 21:07:15

Riven (28 views)
2014-07-23 20:56:16

ctomni231 (59 views)
2014-07-18 06:55:21

Zero Volt (50 views)
2014-07-17 23:47:54

danieldean (42 views)
2014-07-17 23:41:23

MustardPeter (44 views)
2014-07-16 23:30:00
HotSpot Options
by dleskov
2014-07-08 03:59:08

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:58:24

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:47:22

How do I start Java Game Development?
by ra4king
2014-05-17 11:13:37

HotSpot Options
by Roquen
2014-05-15 09:59:54

HotSpot Options
by Roquen
2014-05-06 15:03:10

Escape Analysis
by Roquen
2014-04-29 22:16:43

Experimental Toys
by Roquen
2014-04-28 13:24:22
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!