Marco Crocetta (onyx++at++datamat.it)
Mon, 10 Apr 95 13:40:39 METDST
I have the following problem.
I'd like to draw a plane far away in my scene, that rotate around the
Z axis like my point of view so that it is always in front of the
viewing frustum, i.e. it's always visible.
I created this plane as a gset and than I have attached it to my scene
graph:
static pfVec3 orizzonte[]={
{-1000, 2800.00000,0.0},
{-1000,2800.00000,-500},
{1000, 2800.00000, -500},
{1000, 2800.00000,0.0}
};
....
gset11=pfNewGSet(pfGetSharedArena());
geode=pfNewGeode();
pfNodeName(geode,"GEODE");
pfGSetPrimType(gset11,PFGS_QUADS);
pfGSetNumPrims(gset11,1);
pfGSetAttr(gset11,PFGS_COORD3,PFGS_PER_VERTEX,orizzonte,NULL);
pfAddGSet(geode,gset11);
pfAddChild(Shared->Geo.horDCS,geode);
pfAddChild(Shared->Scene,Shared->Geo.horDCS);
....
Then frame by frame I try to updated the DCS as follows:
pfDCSRot(Shared->Geo.horDCS,Shared->viewCoord.hpr[PF_H],0.0f,0.0f);
Now the problem is that things works well only if I disable
culling (i.e. the perfly cullMode variable is set to 0) otherwise
my plane for a certain heading angle of the viewing frustrum just
disappears.
I must also say that this problem doesn't exist if I draw the plane
by a pfDrawGSet(gset11).
Any Idea of where the problem should be ?
Thanks in Advance.
P.S. Thanks for the help about my Intersection problems!
-------------------------------------
Marco Crocetta
DATAMAT SpA, Rome
e-mail:onyx++at++datamat.it
-------------------------------------
This archive was generated by hypermail 2.0b2 on Mon Aug 10 1998 - 17:51:10 PDT