Advertisement

interesting rendering problem...

Started by July 19, 2002 09:25 AM
47 comments, last by cpu 22 years, 6 months ago
quote:
Original post by munkie
You know, this may or may not be helpful to you as you seem to be a bit of a perfectionist, but these 'color anomalies' you speak of are not a big deal.. I didn't even know what you were talking about in the original pictures.

So one small surface is a bit brighter at a certain angle and zoom. It's no big deal! And for anyone playing the game, they won't know that it wasn't supposed to be there.

Put it this way: It sure as hell doesn't look bad. Those screenshots are pretty nice, and I wouldn't give a second thought about something so minor as what you're complaining about.


I appreciate your positive way of thinking, but it doesn't look as pretty as you imagine when the whole thing starts to _move_!
Since I made the asteroids bigger, my friend delivered me a better idea of what's happening there: polygons at certain distances from the "camera" simply disappear. The ship moves, rotates (as do the asteroids) and this whole effect is really weird. Would like to get rid of it asap.
[It could easily be an episode of X-files by now... ]

I'd like to test this program on more different video cards/configs, and see if this shit happens there. However, I don't have more good testers than this friend of mine.
Would anyone help me with this? I could compile a working version, zip/rar it with the textures and resources, then post an URL for you to download it.
BTW, this is my first OpenGL program/game ever.

Goodnight everyone (at least anyone who's in Eur),
cpu


[edited by - cpu on July 28, 2002 6:36:38 PM]
it has to do with the point light you are using. when using point lights anomlies can occer when the light is close to the object (or far) depending on how much attenuation and range you give the light. also the 0.5 ambient sorta washes away some shadows and may cause weirdness as well. try using directional lights instead, i bet things will work correctly. the reason the geforce1 may handle it differently is due to how light is caluclated differently in the drivers as well as in each image you show the ship is oriented differently compared to the point light so its not comparable between the two cards at all.
aslo make sure specular lighting is off (ignore what the default may be and turn it off, possible this cause the enhanced brightend areas.
Advertisement
Jo ejszakat! (Don''t answer in Hungarian. I know very, very little.)

I would be glad to test it for you on my computer. Just post it. I have one machine with Win 2000 and a GeForce 3 Ti 200, and another with Win 98 and and some old ATI card that I can''t remember right off the top of my head.
-------------------------------------------------------BZZZZTT - CRASH - BANG"What was that?!""Captain, it appears that we have encountered a strange sub-space anomaly. I'm getting a high reading of tracheons beams. The anomaly seems to be some kind of rift in the space-time continuum. -- Never mind, Bones was just using the microwave again."
quote:
Original post by a person
it has to do with the point light you are using. when using point lights anomlies can occer when the light is close to the object (or far) depending on how much attenuation and range you give the light. also the 0.5 ambient sorta washes away some shadows and may cause weirdness as well. try using directional lights instead, i bet things will work correctly. the reason the geforce1 may handle it differently is due to how light is caluclated differently in the drivers as well as in each image you show the ship is oriented differently compared to the point light so its not comparable between the two cards at all.
aslo make sure specular lighting is off (ignore what the default may be and turn it off, possible this cause the enhanced brightend areas.


Thanks for this info; I changed to directional light and it looks better now. My friend''s card still produces some abnormal lighting, but it''s reduced to a minimal level, barely noticable on a still image, but still there. :/
quote:
Original post by DDSquad
Jo ejszakat! (Don''t answer in Hungarian. I know very, very little.)

I would be glad to test it for you on my computer. Just post it. I have one machine with Win 2000 and a GeForce 3 Ti 200, and another with Win 98 and and some old ATI card that I can''t remember right off the top of my head.


It''s amazing how "widespread" our little language is...

You can find the program here.
It outputs a logfile in case something goes wrong.
Video card supporting OpenGL at 800x600x32, and DirectX 8.x required.
Thanks for testing and feedback...

Btw, my new lighting code:

  GLfloat LightAmbient[]=		{ 0.55f, 0.55f, 0.55f, 1.0f };GLfloat LightDiffuse[]=		{ 0.8f, 0.8f, 0.8f, 1.0f };GLfloat LightSpecular[]=	{ 0.8f, 0.8f, 0.8f, 1.0f };GLfloat LightPosition[]=	{ 1.0f, 0.5f, 0.25f, 0.0f };	glLightModelfv(GL_LIGHT_MODEL_AMBIENT, LightAmbient);	glEnable(GL_LIGHTING);	glEnable(GL_LIGHT0);	glLightfv(GL_LIGHT0, GL_AMBIENT, LightAmbient);		// Setup The Ambient Light	glLightfv(GL_LIGHT0, GL_DIFFUSE, LightDiffuse);		// Setup The Diffuse Light	glLightfv(GL_LIGHT0, GL_SPECULAR,LightSpecular);	glLightfv(GL_LIGHT0, GL_POSITION,LightPosition);	// Position The Light  

I got this from a tutorial about the three types of OGL lighting. I hope it''s correct...
Work great with no "anomalies" (don''t you just love that Trekkie word ) on Windows 2000 with my GeForce 3. Looks like this will be a really cool game when finished!

By the way, I spent 8 months in Budapest. It is my favorite city in the whole world! (and I''ve really been around the world) That''s why I know some Hungarian phrases.
-------------------------------------------------------BZZZZTT - CRASH - BANG"What was that?!""Captain, it appears that we have encountered a strange sub-space anomaly. I'm getting a high reading of tracheons beams. The anomaly seems to be some kind of rift in the space-time continuum. -- Never mind, Bones was just using the microwave again."
Advertisement
quote:
Original post by DDSquad
Work great with no "anomalies" (don''t you just love that Trekkie word ) on Windows 2000 with my GeForce 3. Looks like this will be a really cool game when finished!



Yeah, guess what, I saw every series and episode of Trek at least once.
This piece of code you tested is just a framework, but thanks.
I''m glad it works on Win2k, too. Win98(SE), ME?
OK, then is the driver of the ti4200 screwed up or what?
Now I should get back to work on the main code, not just trying to debug something that isn''t there...
Have you got any idea how I should do collision detection? I thought about ellipses/ellipsoids, bacause ships will be usually long. For the asteroids and a few other round things a bounding circle/sphere would be enough, though.
As you may have noticed, the projectiles/beams can "get out" of the plane the ship is moving on, so I essentially need 3D collision detection, not simple 2D. I read a few tutorials on this issue, but none focused on the type that I need (two ellipsoids, at any angle on x-z plane, constant angle at y axis). A really complicated matter, this is.

quote:

By the way, I spent 8 months in Budapest. It is my favorite city in the whole world! (and I''ve really been around the world) That''s why I know some Hungarian phrases.

I heard this sentence from quite a number of people. Budapest is great. When have you been here? (I didn''t even write I live in BP, but your guess is true.) A lot of things changed in the past few years which (finally) made certain parts of the city more attractive...

...thanks for any suggestions,
cpu
I bit more headaces comming you way

The normals of the faces of the planets seem to be wrong sometimes big triangular strips of the planets disaper showing the inside of the planet below is a screen shot of it..

screen shot

Also one of the planets is missing one of its poles (there is a circular hole into the planet - this may be the way you designed it though..)

Also somtimes the space ships seems to blink (as if fully lith and then verry shortly after it has normal ligth - so I havent been able to get a screen shot..) this however im fairly shure is a problem with my driver (since it somtimes happens in other games as well) if it is a similar problem your friend is having you migth suggest to him that he tries switching drivers...

/keep cooding...



/Please excuse my bad spelling - My native language is binary not english
|Visit me
\Take my advice - I don''''t use it...
/Please excuse my bad spelling - My native language is binary not english|Visit meTake my advice - I don''t use it...
Hi!

quote:
Original post by guppy
I bit more headaces comming you way

The normals of the faces of the planets seem to be wrong sometimes big triangular strips of the planets disaper showing the inside of the planet below is a screen shot of it..

screen shot

Also one of the planets is missing one of its poles (there is a circular hole into the planet - this may be the way you designed it though..)



I suppose if the normals were wrong, it would have been noticable on my screen, too, but it wasn''t.
They are precalculated by external programs such as 3D studio max and converted my milkshape3D.
My friend has the same stupid effects, so suppose it''s a driver bug. Which version of the driver is bug-free? None of them.
He has an MSI card, gf4 ti4200+DVI+svideo-out and WinXP.

The pole isn''t missing, normally. Which planet is it? Why should I design moons/planets with holes?

quote:

Also somtimes the space ships seems to blink (as if fully lith and then verry shortly after it has normal ligth - so I havent been able to get a screen shot..) this however im fairly shure is a problem with my driver (since it somtimes happens in other games as well) if it is a similar problem your friend is having you migth suggest to him that he tries switching drivers...



That''s it.
Thanks for testing.
I lived in Budapest (district 2, 5 minute walk from Batthany ter.) during the 98-99 school year. I have also visited it often since then.



[edited by - DDSquad on July 30, 2002 1:05:39 PM]
-------------------------------------------------------BZZZZTT - CRASH - BANG"What was that?!""Captain, it appears that we have encountered a strange sub-space anomaly. I'm getting a high reading of tracheons beams. The anomaly seems to be some kind of rift in the space-time continuum. -- Never mind, Bones was just using the microwave again."

This topic is closed to new replies.

Advertisement