Re: Re: [Plib-devel] LoadASE problem.
Brought to you by:
sjbaker
From: Dave M. <dp...@ef...> - 2000-02-23 18:40:01
|
Christian wrote: >I tried to compile a new plib checkout, but MSVC complaind about a few >parts in the ASE load/save routines Thanks for checking this out. I added the fixed to other changes i'm making. I noticed the plib.dsw/dsp in CVS is missing the new files and ssgContext.cxx. i'll send Steve the changes for a commit later today >Using the save.cxx SSG example with loading the tuxedo.ac and saving it >then as tuxedo.ase I get > >*MATERIAL_AMBIENT -431602080.000000 -431602080.000000 -431602080.000000 >*MATERIAL_DIFFUSE -431602080.000000 -431602080.000000 -431602080.000000 > >in all materials. This doesn't lok right (it looks like some unitialized >floats). Is that correct? > correct. AC format specifies rgb,amb,emis,and spec where as ASE specifies amb,diff,spec. ssgLoadAC does this: st -> setMaterial ( GL_SPECULAR, mat -> spec ) ; st -> setMaterial ( GL_EMISSION, mat -> emis ) ; and ssgLoadASE does this: st -> setMaterial ( GL_AMBIENT, mat -> amb ) ; st -> setMaterial ( GL_DIFFUSE, mat -> diff ) ; st -> setMaterial ( GL_SPECULAR, mat -> spec ) ; therefore, when you load AC and save ASE you get undefined amb and diff. before i fix this, i'd like to understand it more fully. anyone want to comment on how the state should be initialized for unknown properties? thanks, --Dave |