|
This thread is locked; no one can reply to it. |
1
2
|
[OL] GeForce FX 5600XT |
CursedTyrant
Member #7,080
April 2006
|
That sort of thing did not happen on my Radeon 9550. It does on this particular gfx card tough. Any ideas why and how can I fix it (tough I probably can't and I'll have to harass Flad to take a look at it)? I know it's been asked dozens of times, but I don't recall it ever being fixed. And yes, I'm using the latest snapshot. {"name":"590216","src":"\/\/djungxnpq2nug.cloudfront.net\/image\/cache\/3\/1\/310539626e66f098e8e384e3dc626376.jpg","w":791,"h":589,"tn":"\/\/djungxnpq2nug.cloudfront.net\/image\/cache\/3\/1\/310539626e66f098e8e384e3dc626376"} --------- |
Richard Phipps
Member #1,632
November 2001
|
Are you using blending? Does this occur if using an ADDITIVE_BLEND mode? |
CursedTyrant
Member #7,080
April 2006
|
Yes, I'm using blending, but not on this screenshot (shadows are disabled, so no blending is actually done). It occurs anyway tough, shadows on or off. --------- |
Richard Phipps
Member #1,632
November 2001
|
If you look at those lines with a paint program you will see that they are not perfectly black, but instead about half brightness. That suggests that it's a blending issue with the two triangles. Can you turn on additive blending for those floor tiles and check if that helps? |
Fladimir da Gorf
Member #1,565
October 2001
|
You could try turning off the anti-aliasing. OpenLayer has reached a random SVN version number ;) | Online manual | Installation video!| MSVC projects now possible with cmake | Now alvailable as a Dev-C++ Devpack! (Thanks to Kotori) |
Mr. Big
Member #6,196
September 2005
|
Try calling 'glDisable(GL_POLYGON_SMOOTH)'. |
CursedTyrant
Member #7,080
April 2006
|
Yeah, it fixed it, but with the shadows and lights on, everything else looks rather BAD. I didn't have any problems on my Radeon 9550 tough, is there any way to fix it without rewriting the code? I don't want to spend another week trying to figure out a good blender combination EDIT: I'll try. EDIT2: Ah, thanks a lot, glDisable(GL_POLYGON_SMOOTH) fixed everything. Thanks again. --------- |
Richard Phipps
Member #1,632
November 2001
|
Would glDisable(GL_POLYGON_SMOOTH) have any negative effects (apart from removing anti-aliasing on untextured polygons when you might want it?) I.e. should this be added to the OpenLayer setup code? |
Fladimir da Gorf
Member #1,565
October 2001
|
Well, it makes the polygon edges not to appear anti-aliased. OpenLayer has reached a random SVN version number ;) | Online manual | Installation video!| MSVC projects now possible with cmake | Now alvailable as a Dev-C++ Devpack! (Thanks to Kotori) |
Richard Phipps
Member #1,632
November 2001
|
What I am concerned with is that this problem will affect all OpenLayer programs that use blitting operations on a GeForce FX 5600XT. So, would it be better to disable the smoothing to avoid the problem on this card? |
CursedTyrant
Member #7,080
April 2006
|
I think turning it off by default would be ok, as long as it's clearly stated somewhere (for those of us who are not so proficient at OpenGL) that you can use something like that to smooth the polygons. After all, I didn't even know such an option existed before today It would also benefit people with gfx cards like mine, because I don't think many people using OpenLayer turn that particular option off. OTOH, my Snake clone runs perfectly fine on this video card, tough it might be becase I use one large bitmap for the background and additive blending (which fixes the problem as well) for the snake and bonuses. --------- |
Bob
Free Market Evangelist
September 2000
|
Quote: glDisable(GL_POLYGON_SMOOTH) fixed everything. Thanks again. Polygon smoothing is disabled by default. You had to explicitly turn it on... so just don't do that Polygon smoothing is just the wrong option for antialiasing. It just doesn't work. It's great if what you want is smoothing though, but you do need to keep in mind that your edges will "bleed" into adjacent polygons when you do that. -- |
Epsi
Member #5,731
April 2005
|
I had this problem too with a GeForce Go 6200. With the polygon smoothing off you jts have to keep in mind that your Shapes will be aliased (eg. Circles). ___________________________________ piccolo: "soon all new 2d alegro games will be better. after i finsh my MMRPG. my game will serve as a code reference. so you can understand and grab code from." |
Bob
Free Market Evangelist
September 2000
|
Quote: With the polygon smoothing off you jts have to keep in mind that your Shapes will be aliased (eg. Circles). Or you can turn on multisampling, which does actually work for edge anti-aliasing. -- |
CursedTyrant
Member #7,080
April 2006
|
SetupProgram(MOUSE | KEYBOARD | TIMER); else { SetupProgram(MOUSE | KEYBOARD); } SetupScreen(sW, sH, sF, desktop_color_depth()); srand(time(0)); Game = true; I don't see how any of these lines "explicitly turn on" GL_POLYGON_SMOOTH. --------- |
Epsi
Member #5,731
April 2005
|
You don't see it because OL enable it by default (it's the antialiasing function). The polygon smoothing line is located in Settings.cpp of the OL lib. void Settings:: SetAntialiasing( bool turnedOn ) { useAntiAlias = turnedOn; if( useAntiAlias ) { glEnable( GL_LINE_SMOOTH ); glEnable( GL_POINT_SMOOTH ); // comment this because of a GeForce bug //glEnable( GL_POLYGON_SMOOTH ); } else { glDisable( GL_LINE_SMOOTH ); glDisable( GL_POINT_SMOOTH ); glDisable( GL_POLYGON_SMOOTH ); } } Rebuild the lib afterwards. ___________________________________ piccolo: "soon all new 2d alegro games will be better. after i finsh my MMRPG. my game will serve as a code reference. so you can understand and grab code from." |
Bob
Free Market Evangelist
September 2000
|
Quote: // comment this because of a GeForce bug I take offense. This is not a GeForce bug. GeForce is 100% OpenGL compliant here. -- |
Richard Phipps
Member #1,632
November 2001
|
Bob, how come this effect is not visible on other GeForce cards? |
CursedTyrant
Member #7,080
April 2006
|
Quote: You don't see it because OL enable it by default (it's the antialiasing function). I was referring to this: Quote: Polygon smoothing is disabled by default. You had to explicitly turn it on... so just don't do that
--------- |
Epsi
Member #5,731
April 2005
|
Quote: I was referring to this Yes and I was explaining why you have not activated it yourself, it's just that OL does it for you behind the scene Bob, no offense. Maybe it's the way it's supposed to look with that OpenGL feature, but from an end user point of view it just looks wrong. ___________________________________ piccolo: "soon all new 2d alegro games will be better. after i finsh my MMRPG. my game will serve as a code reference. so you can understand and grab code from." |
Thomas Fjellstrom
Member #476
June 2000
|
Quote: Maybe it's the way it's supposed to look with that OpenGL feature, but from an end user point of view it just looks wrong. That was his point. -- |
Bob
Free Market Evangelist
September 2000
|
Quote: Bob, how come this effect is not visible on other GeForce cards? It is. Really, try it. Polygon smoothing + blending / alpha testing = teh loss. Polygon smoothing basically draws lines with attenuated alpha around the edges of the polygon, on the outside of it. That looks great if you never use blending, have one polygon by itself over some background, or are drawing only lines. Otherwise, you see a "seam" between polygons, which is really one polygon bleeding and overlapping onto the next. That's because connected smoothed polygons don't tightly fit (by design); they overlap. -- |
HappyMonster @Home
Member #1,607
October 2001
|
I see. Thanks for explaining it clearly. |
kdevil
Member #1,075
March 2001
|
I was also seeing this issue, on a GeForce 7900GT, and commenting out glEnable(GL_POLYGON_SMOOTH) worked. That line should be removed from OpenLayer entirely, otherwise OL games are going to look horrible on a lot cards. Besides, on other cards I don't see any real difference after removing that line. ----- |
Fladimir da Gorf
Member #1,565
October 2001
|
I guess you're right. After all the polygon smoothing isn't that important at all. OpenLayer has reached a random SVN version number ;) | Online manual | Installation video!| MSVC projects now possible with cmake | Now alvailable as a Dev-C++ Devpack! (Thanks to Kotori) |
|
1
2
|