Po-Wen Shih (shih++at++cis.ohio-state.edu)
Fri, 20 Jun 1997 16:14:46 -0400 (EDT)
I know this should be a fairly simple question but I just couldn't get it
right.
I need to chnage the global shading model between PFSM_FLAT and PFSM_GOURAUD.
I have tried the follwoing two ways but both gave me 'segmentation fault'.
first approach (got from the 'man' page of 'pfShadeModel'):
pfShadeModel(PFSM_FLAT);
pfOverride(PFSTATE_SHADEMODEL, PF_ON);
second approach (got from the insight manual page of Performer):
pfGeoState *gstate;
gstate = pfNewGState(NULL);
pfGStateMode(gstate, PFSTATE_SHADEMODEL, PFSM_FLAT);
pfApplyGState(gstate);
I am using the ported perfly from Performer 1.2 as a base program. I inserted
the above codes between all the initialization done by perfly and the
'while' simulation loop. Does anyone know what's wrong with my code?
Thanks for any help.
Po-Wen Shih
-----------
=======================================================================
List Archives, FAQ, FTP: http://www.sgi.com/Technology/Performer/
Submissions: info-performer++at++sgi.com
Admin. requests: info-performer-request++at++sgi.com
This archive was generated by hypermail 2.0b2 on Mon Aug 10 1998 - 17:55:29 PDT