Main Page Class Hierarchy Compound List File List Compound Members
iIsoView Struct Reference A view on the isometric world.
More...
#include <iso.h >
Inheritance diagram for iIsoView:
List of all members.
Public Methods
virtual iIsoEngine * GetEngine () const=0
Get the iso engine this view belongs to.
virtual void SetWorld (iIsoWorld *world)=0
Set world to use.
virtual iIsoWorld * GetWorld () const=0
Get world shown in view.
virtual void SetRect (const csRect &rect)=0
Set the rectangle on the screen to draw to.
virtual const csRect & GetRect () const=0
Get the rectangle on the screen to draw to.
virtual void SetAxes (float xscale, float yscale, float zscale, float zskew, float xskew)=0
set the axis of the view on the world. More...
virtual const csVector2 & GetScroll () const=0
See the screen position scrolled to.
virtual csVector3 GetViewScroll () const=0
See the world position scrolled to (as shown in center of viewport).
virtual void SetScroll (const csVector3 &worldpos, const csVector2 &coord)=0
Set the scroll position. Show world space pos as screen space coord.
virtual void MoveScroll (const csVector3 &delta)=0
Move the scroll position by delta (in world space).
virtual void W2S (const csVector3 &world, csVector2 &screen) const=0
Transform world space coordinate into a screen coordinate.
virtual void W2S (const csVector3 &world, csVector3 &screen) const=0
Transform world space coordinate into a screen coordinate. More...
virtual void S2W (const csVector2 &screen, csVector3 &world) const=0
Transform screen coordinate into a world space coordinate. More...
virtual void Draw ()=0
draw the view onto the screen. More...
virtual iCamera * GetFakeCamera (const csVector3 ¢er, iIsoRenderView *rview)=0
Return a fake iCamera implementation, that approximates isometric near the given position (in world space). More...
Detailed Description
A view on the isometric world.
Can be used to render a specific portion of an isoWorld onto a particular part of the screen.
The axes are aligned like this +y | ./+z | ./ | ./ |/ \. \. \. \+x
Member Function Documentation
void iIsoView::Draw (
) [pure virtual]
draw the view onto the screen.
Call this when in 3d mode (with the engine->getBeginDrawFlags passed)
Return a fake iCamera implementation, that approximates isometric near the given position (in world space).
The renderview is also used. This is a very partial implementation of iCamera . For Internal Use!
Transform screen coordinate into a world space coordinate.
The world space coordinate will have y=0.
void iIsoView::SetAxes (
float xscale ,
float yscale ,
float zscale ,
float zskew ,
float xskew ) [pure virtual]
set the axis of the view on the world.
The scale is in pixels, and must be > 0. Default is g3d->height/16. The skew values determine the angle of the z and x axis. it is the amount of vertical change per horizontal change. 1.0 gives perfect isometrical view, 0.5 flattens the lines. skew values must be > 0. For a nice y scale, (sqrt(xskew*xskew+1+sqrt(yskew*yskew+1)/2 can compensate for the lengthening and shortening of the axes due to the skewing.
Transform world space coordinate into a screen coordinate.
The returned z value can be used for a zbuffer, is bigger when further away.
The documentation for this struct was generated from the following file:
Generated for Crystal Space by
doxygen
1.2.5 written by
Dimitri van Heesch ,
©1997-2000