Java-Gaming.org Java4K winners: [ by our judges | by the community ]         
Featured games (67)
games approved by the League of Dukes
Games in Showcase (∞)
games submitted by our members



News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  Print  
  Graphics Inconsistancy  (Read 976 times)
0 Members and 1 Guest are viewing this topic.
Offline swh

JGO n00b
*

Posts: 3


Modelzilla rocks!  Java's cool too!


« on: 2003-08-25 22:38:05 »

Hi,

Just last week I changed my OpenGL rendering code to use JOGL instead of GL4Java.  I was able to get it working well on both Windows and Linux in less than a day.  Very nice.

But, Solaris wasn't so sucessful.  I am running the very latest Java version (1.4.2) and Im getting very strange lighting behaviour.  I have made a test program that shines a single directional light from the upper right top, onto a grey sphere.  The directional light comes out at maximum brightness at every vertex it strikes, regarless of the angle at which they hit the sphere.

Could I be forgetting to set some OpenGL defaults that are different on Solaris OpenGL and Windows OpenGL? Any luck with Solaris, anyone?

I have included screen shots of my test program:
Windows (good picture) Smiley



Solaris (bad picture) Sad



Oh, but wait!  Lets see what happens with GL_SPECULAR set to zero.... wait.... testing.... it fixes it!  Now the sphere looks evan better on Solaris then on Windows.  In the old version, the version that gives a specular highlight in a few polygons on Windows, the GL_SPECULAR color was set to be the same as GL_DIFFUSE - but this gives crazy shading on Solaris.  So Im not sure how safe this GL_SPECULAR term is to use.  For some reason, GL4Java doesn't have this problem.  Sven Goethel is a genius!        
Pages: [1]
  Print  
 
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.062 seconds with 21 queries.