RE: [Plib-devel] Double-sided material fix to 3DS loader for
Brought to you by:
sjbaker
From: Dave M. <Dav...@dy...> - 2000-04-04 16:15:15
|
> > Per Liedman writes: > > > By the way, I use a modified version of the tux_example > to test the > > > 3ds-loader, and have stumbled across something I think is sort of > > > odd. If I load one of the models supplied by Wolfram Kuss > (550.3ds), > > > it looks what I think it should look like (a large > building), but if > > > I also load the pedestal model from the original tux_example, the > > > whole building turns white (no lighting or anything)! Any > > > suggestions to what might cause this? (The loader does not use > > > GL_COLOR_MATERIAL, if that is of any interest.) > > Curtis L. Olson writes: > > I've noticed similar behavior with ssg ... I've never been > able to get > > an ssgSimpleState to work consistantly if it doesn't use > > gl_color_material and if it doesn't have a texture. I've seen this > > enough times to speculate that either: > > > > a) there is some state changing bug in ssg > > > > b) there is some non-obvious thing that needs to get done > to make this > > work right > > Just in case what I wrote was confusing. If I'm trying to create a > simplestate that sets material properties without enabling > gl_color_material and at the same time doesn't have a texture applied, > then I see really inconsistant results ... it will work at times and > not work at times depending on view direction and position. Work > being defined as I get what I think I should get, and not-work being > defined as I get an all white shaded surface. My guess is that as > various objects are culled or drawn, this has a side effect on the > objects in question so that sometimes they are rendered correctly, and > sometimes not. > in tux_example, if you load something without state then you should get current color as last set by glColor since lighting is disabled. current color is inconsistant because it depends on the last call to glColor. if you have a simple test case that demonstrates the bug, let's have it because we really need to nail this down. alternatively, SSG could use a "default simplestate" or just initialize glColor when it renders. Anyone want to define a "default simplestate"? -- Dave McClurg |