class csPortal This class represents a portal
This class represents a portal. It belongs to some polygon which is then considered a portal to another sector.
't' is the transformation from world to camera space.
'new_clipper' is the new 2D polygon to which all things drawn
should be clipped.
Return true if succesful, false otherwise.
Failure to draw through a portal does not need to
be harmful. It can just mean that some maximum number is
reached (like the maximum number of times a certain sector
can be drawn through a mirror).
This function returns the destination.
int cfg_alpha
bool do_warp_space
bool do_mirror
bool do_clip_portal
bool static_dest
csReversibleTransform warp_obj
csReversibleTransform warp_wor
ITextureHandle* filter_texture
float filter_r
csPortal()
virtual ~csPortal()
csSector* GetSector()
void SetSector(csSector* s)
void ObjectToWorld(const csReversibleTransform& t)
void SetWarp(const csTransform& t)
void SetWarp(const csMatrix3& m_w, const csVector3& v_w_before, const csVector3& v_w_after)
bool IsSpaceWarped()
void DisableSpaceWarping()
void SetClippingPortal(bool c)
bool IsClippingPortal()
void SetStaticDest(bool sd)
bool IsStaticDest()
void SetTexture(ITextureHandle* ft)
void SetFilter(float r, float g, float b)
int GetAlpha()
void SetAlpha(int a)
void WarpSpace(csReversibleTransform& t, bool& mirror)
'mirror' is true if the camera transformation transforms all polygons
so that the vertices are ordered anti-clockwise. 'mirror' will be modified
by warp_space if needed.
virtual bool Draw(csPolygon2D* new_clipper, csPolygon3D* portal_polygon, csRenderView& rview)
'portal_polygon' is the polygon containing this portal. This routine
will use the camera space plane of the portal polygon.
'rview' is the current csRenderView.
virtual csPolygon3D* HitBeam(csVector3& start, csVector3& end)
virtual csPolygon3D* IntersectSphere(csVector3& center, float radius, float* pr = NULL)
virtual csSector* FollowSegment(csReversibleTransform& t, csVector3& new_position, bool& mirror)
virtual void CalculateLighting(csLightView& lview)
this page has been generated automatically by doc++
(c)opyright by Malte Zöckler, Roland Wunderling
contact: doc++@zib.de