Enviro application
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
Public Member Functions | Public Attributes | List of all members
EnviroGUI Class Reference
Inheritance diagram for EnviroGUI:
Inheritance graph
[legend]

Public Member Functions

 EnviroGUI ()
 
 ~EnviroGUI ()
 
virtual void ShowPopupMenu (const IPoint2 &pos)
 
virtual void SetTerrainToGUI (vtTerrain *pTerrain)
 
virtual void ShowLayerView ()
 
virtual void RefreshLayerView ()
 
virtual void UpdateLayerView ()
 
virtual void CameraChanged ()
 
virtual void EarthPosUpdated ()
 
virtual void ShowDistance (const DPoint2 &p1, const DPoint2 &p2, double fGround, double fVertical)
 
virtual void ShowDistance (const DLine2 &path, double fGround, double fVertical)
 
virtual vtTagArrayGetInstanceFromGUI ()
 
virtual bool OnMouseEvent (vtMouseEvent &event)
 
virtual void SetupScene3 ()
 
virtual void SetTimeEngineToGUI (class vtTimeEngine *pEngine)
 
virtual bool IsAcceptable (vtTerrain *pTerr)
 
virtual void OnCreateTerrain (vtTerrain *pTerr)
 
virtual void ShowMessage (const vtString &str)
 
virtual void SetFlightSpeed (float speed)
 
virtual void SetState (AppState s)
 
virtual vtString GetStringFromUser (const vtString &title, const vtString &msg)
 
virtual void ShowProgress (bool bShow)
 
virtual void SetProgressTerrain (vtTerrain *pTerr)
 
virtual void UpdateProgress (const char *msg1, const char *msg2, int amount1, int amount2)
 
virtual void AddVehicle (CarEngine *eng)
 
virtual void RemoveVehicle (CarEngine *eng)
 
void SetScenario (int num)
 
bool SaveVegetation (bool bAskFilename)
 
bool SaveStructures (bool bAskFilename)
 
void OnSetDelete (vtFeatureSet *set)
 
- Public Member Functions inherited from Enviro
 Enviro ()
 
virtual ~Enviro ()
 
void Startup ()
 
void Shutdown ()
 
virtual void StartupArgument (int i, const char *str)
 
void LoadAllTerrainDescriptions ()
 
void LoadGlobalContent ()
 
void StartControlEngine ()
 
void DoControl ()
 
void DoControlOrbit ()
 
void DoControlTerrain ()
 
void SwitchToTerrain (vtTerrain *pTerrain)
 
void SelectInitialViewpoint (vtTerrain *pTerrain)
 
vtGroupGetRoot ()
 
void StoreTerrainParameters ()
 
osgText::Font * GetArial ()
 
void ShowElevationLegend (bool bShow)
 
bool GetShowElevationLegend ()
 
void ShowCompass (bool bShow)
 
bool GetShowCompass ()
 
void ShowMapOverview (bool bShow)
 
bool GetShowMapOverview ()
 
void TextureHasChanged ()
 
float GetFlightSpeed ()
 
virtual void SetNavDamping (float factor)
 
float GetNavDamping ()
 
void SetFlightAccel (bool bAccel)
 
bool GetFlightAccel ()
 
void SetTopDown (bool bTopDown)
 
void SetCurrentNavigator (vtTerrainFlyer *pE)
 
void EnableFlyerEngine (bool bEnable)
 
void SetNavType (NavType nav)
 
NavType GetNavType ()
 
void SetMaintain (bool bOn)
 
bool GetMaintain ()
 
void ResetCamera ()
 
void SetMode (MouseMode mode)
 
void DumpCameraInfo ()
 
void SetSpeed (float x)
 
float GetSpeed ()
 
void GetStatusString (int which, vtString &str1, vtString &str2)
 
void ActivateAStructureLayer ()
 
void ActivateAVegetationLayer ()
 
void FlyToSpace ()
 
bool RequestTerrain (const char *name)
 
void RequestTerrain (vtTerrain *pTerr)
 
vtIcoGlobeGetGlobe ()
 
vtIcoGlobeGetOverlayGlobe ()
 
void SetEarthShading (bool bShade)
 
bool GetEarthShading ()
 
void SetEarthTilt (bool bTilt)
 
bool GetEarthTilt ()
 
void SetEarthShape (bool Flat)
 
bool GetEarthShape ()
 
void SetEarthUnfold (bool Flat)
 
bool GetEarthUnfold ()
 
void SetSpaceAxes (bool bShow)
 
bool GetSpaceAxes ()
 
int AddGlobeAbstractLayer (const char *fname)
 
void RemoveGlobeAbstractLayer (GlobeLayer *glay)
 
void UpdateEarthArc ()
 
void SetDisplayedArc (const DPoint2 &g1, const DPoint2 &g2)
 
void SetDisplayedArc (const DLine2 &path)
 
void SetEarthLines (double lon, double lat)
 
void ShowEarthLines (bool bShow)
 
vtTerrainFindTerrainOnEarth (const DPoint2 &p)
 
vtString GetMessage1 ()
 
vtString GetMessage2 ()
 
void SetMessage (const vtString &str1, const vtString &str2="", float time=0.0f)
 
void FormatCoordString (vtString &str, const DPoint3 &coord, LinearUnits units, bool seconds=false)
 
void DescribeCoordinatesEarth (vtString &str1, vtString &str2)
 
void DescribeCoordinatesTerrain (vtString &str1, vtString &str2)
 
void DescribeCLOD (vtString &str)
 
bool OnMouse (vtMouseEvent &event)
 
void OnMouseLeftDownTerrain (vtMouseEvent &event)
 
void OnMouseLeftDownTerrainSelect (vtMouseEvent &event)
 
void OnMouseLeftDownTerrainMove (vtMouseEvent &event)
 
void OnMouseLeftDownOrbit (vtMouseEvent &event)
 
void OnMouseLeftUp (vtMouseEvent &event)
 
void OnMouseLeftUpBox (vtMouseEvent &event)
 
void OnMouseRightDown (vtMouseEvent &event)
 
void OnMouseRightUp (vtMouseEvent &event)
 
void OnMouseMove (vtMouseEvent &event)
 
void OnMouseMoveTerrain (vtMouseEvent &event)
 
void OnMouseSelectRayPick (vtMouseEvent &event)
 
void OnMouseSelectCursorPick (vtMouseEvent &event)
 
bool OnMouseCompass (vtMouseEvent &event)
 
void AddElasticPoint (const DPoint2 &p)
 
bool IsMakingElastic ()
 
void CancelElastic ()
 
void FinishLinear ()
 
void SetFenceOptions (const vtLinearParams &param, bool bProfileChanged=false)
 
void FinishBuilding ()
 
void FlipBuildingFooprints ()
 
void SetBuildingEaves (float fLength)
 
void CopyBuildingStyle ()
 
void PasteBuildingStyle ()
 
bool HaveBuildingStyle ()
 
void CreateInstance ()
 
void CreateInstanceAt (const DPoint2 &pos, vtTagArray *tags)
 
void StartPowerline ()
 
void FinishPowerline ()
 
void SetPowerOptions (const vtString &sStructType)
 
void LoadSpeciesList ()
 
vtSpeciesList3dGetSpeciesList ()
 
PlantingOptionsGetPlantOptions ()
 
bool PlantATree (const DPoint2 &epos)
 
void SetPlantOptions (const PlantingOptions &opt)
 
void SetVehicleOptions (const VehicleOptions &opt)
 
CarEngine * CreateGroundVehicle (const VehicleOptions &opt)
 
bool ImportModelFromKML (const char *kmlfile)
 
vtAbstractLayerGetLabelLayer () const
 
int NumSelectedAbstractFeatures () const
 
void SetDistanceToolMode (bool bPath)
 
void SetDistanceTool (const DLine2 &line)
 
void ResetDistanceTool ()
 
void UpdateDistanceTool ()
 
void SetWind (int iDirection, float fSpeed)
 
void UpdateCompass ()
 
void SetHUDMessageText (const char *message)
 
void ShowVerticalLine (bool bShow)
 
bool GetShowVerticalLine ()
 
void MakeDemoGlobe ()
 
void ToggleDemo ()
 
void CreateSomeTestVehicles (vtTerrain *pTerrain)
 
void MakeOverlayGlobe (vtImage *image, bool progress_callback(int)=NULL)
 
- Public Member Functions inherited from vtTerrainScene
vtGroupBeginTerrainScene ()
 
void AppendTerrain (vtTerrain *pTerrain)
 
void SetCurrentTerrain (vtTerrain *pTerrain)
 
vtGroupBuildTerrain (vtTerrain *pTerrain)
 
uint NumTerrains ()
 
vtTerrainGetCurrentTerrain () const
 
vtTerrainFindTerrainByName (const char *name)
 
vtTransformGetSunLightTransform ()
 

Public Attributes

vtJoystickEnginem_pJFlyer
 
- Public Attributes inherited from Enviro
DPoint3 m_EarthPos
 
TerrainPickerm_pTerrainPicker
 
GlobePickerm_pGlobePicker
 
vtMovGeodem_pCursorMGeom
 
vtTerrainFlyerm_pTFlyer
 
VFlyerm_pVFlyer
 
vtOrthoFlyerm_pOrthoFlyer
 
QuakeFlyerm_pQuakeFlyer
 
vtTerrainFlyerm_pCurrentFlyer
 
GrabFlyerm_pGFlyer
 
FlatFlyerm_pFlatFlyer
 
vtPanoFlyerm_pPanoFlyer
 
vtHeightConstrainm_pHeightEngine
 
VehicleManager m_VehicleManager
 
VehicleSet m_Vehicles
 
AppState m_state
 
MouseMode m_mode
 
NavType m_nav
 
bool m_bOnTerrain
 
vtString m_strMessage1
 
vtString m_strMessage2
 
bool m_bDragging
 
bool m_bDragUpDown
 
bool m_bRotating
 
bool m_bSelectedStruct
 
bool m_bSelectedPlant
 
bool m_bSelectedUtil
 
bool m_bSelectedVehicle
 
vtFence3dm_pDraggingFence
 
int m_iDraggingFencePoint
 
DPoint3 m_EarthPosDown
 
DPoint3 m_EarthPosLast
 
vtLine3dm_pCurUtilLine
 
vtPole3dm_pSelUtilPole
 
IPoint2 m_MouseDown
 
IPoint2 m_MouseLast
 
float m_StartRotation
 
bool m_bConstrainAngles
 
bool m_bShowVerticalLine
 
vtGroupm_pDemoGroup
 
vtGeodem_pDemoTrails
 

Additional Inherited Members

- Protected Member Functions inherited from Enviro
void LoadTerrainDescriptions (const vtString &path)
 
void SetupScene1 ()
 
void SetupScene2 ()
 
void DoCursorOnEarth ()
 
void DoCursorOnTerrain ()
 
void MakeGlobe ()
 
void SetupGlobe ()
 
void LookUpTerrainLocations ()
 
void SetupTerrain (vtTerrain *pTerr)
 
void SetupArcMaterials ()
 
void SetupArcMesh ()
 
void FreeArc ()
 
void FreeArcMesh ()
 
void SetTerrainMeasure (const DPoint2 &g1, const DPoint2 &g2)
 
void SetTerrainMeasure (const DLine2 &path)
 
void CreateElevationLegend ()
 
void CreateCompass ()
 
void CreateMapOverview ()
 
void StartFlyIn ()
 
void FlyInStage1 ()
 
void FlyInStage2 ()
 
bool IsFlyingInFromSpace ()
 
void SetWindowBox (const IPoint2 &ul, const IPoint2 &lr)
 
void MakeVerticalLine ()
 
void UpdateVerticalLine ()
 
- Protected Attributes inherited from Enviro
vtSpeciesList3dm_pSpeciesList
 
PlantingOptions m_PlantOpt
 
bool m_bPlantsLoaded
 
VehicleOptions m_VehicleOpt
 
vtLinearParams m_FenceParams
 
vtBuilding m_BuildingStyle
 
ElasticPolyline m_Elastic
 
bool m_bActiveUtilLine
 
vtString m_sStructType
 
vtGeodem_pArc
 
vtMaterialArraym_pArcMats
 
double m_fArcLength
 
float m_fDistToolHeight
 
bool m_bMeasurePath
 
DLine2 m_distance_path
 
vtGeodem_pVertLine
 
vtCameraPtr m_pNormalCamera
 
vtCameraPtr m_pTopDownCamera
 
bool m_bTopDown
 
vtEnginem_pNavEngines
 
vtGroupm_pRoot
 
vtTimeEnginem_pGlobeTime
 
vtGroupm_pGlobeContainer
 
vtIcoGlobem_pIcoGlobe
 
vtIcoGlobem_pOverlayGlobe
 
bool m_bEarthShade
 
bool m_bGlobeFlat
 
float m_fFlattening
 
float m_fFlattenDir
 
bool m_bGlobeUnfolded
 
float m_fFolding
 
float m_fFoldDir
 
vtTrackballm_pTrackball
 
vtGeodem_pSpaceAxes
 
vtGeodem_pEarthLines
 
vtMeshm_pLineMesh
 
FPQ m_SpaceLoc
 
FPQ m_FlatLoc
 
ControlEnginem_pControlEng
 
int m_iInitStep
 
vtTerrainm_pTargetTerrain
 
FPoint3 m_SpaceTrackballState [3]
 
bool m_bFlyIn
 
int m_iFlightStage
 
int m_iFlightStep
 
FPoint3 m_TrackStart [3]
 
FPoint3 m_TrackPosDiff
 
vtAnimPath m_FlyInAnim
 
DPoint2 m_FlyInCenter
 
float m_fTransitionHeight
 
vtMaterialArrayPtr m_pHUDMaterials
 
vtHUDm_pHUD
 
vtTextMeshm_pHUDMessage
 
vtFontPtr m_pArial
 
float m_fMessageStart
 
float m_fMessageTime
 
vtGeodem_pLegendGeom
 
bool m_bCreatedLegend
 
vtSpriteSizerm_pCompassSizer
 
vtGeodem_pCompassGeom
 
bool m_bCreatedCompass
 
bool m_bDragCompass
 
float m_fDragAngle
 
vtMeshm_pWindowBoxMesh
 
MapOverviewEnginem_pMapOverview
 

Detailed Description

The core GUI class of the application. Handles GUI implementations of all the functionality of the Enviro class.

Constructor & Destructor Documentation

EnviroGUI::EnviroGUI ( )
EnviroGUI::~EnviroGUI ( )

Member Function Documentation

void EnviroGUI::AddVehicle ( CarEngine *  eng)
virtual

Reimplemented from Enviro.

void EnviroGUI::CameraChanged ( )
virtual

Reimplemented from Enviro.

void EnviroGUI::EarthPosUpdated ( )
virtual

Reimplemented from Enviro.

vtTagArray * EnviroGUI::GetInstanceFromGUI ( )
virtual

Reimplemented from Enviro.

vtString EnviroGUI::GetStringFromUser ( const vtString title,
const vtString msg 
)
virtual

Implements Enviro.

bool EnviroGUI::IsAcceptable ( vtTerrain pTerr)
virtual

Reimplemented from Enviro.

void EnviroGUI::OnCreateTerrain ( vtTerrain pTerr)
virtual

Reimplemented from Enviro.

bool EnviroGUI::OnMouseEvent ( vtMouseEvent event)
virtual

Reimplemented from Enviro.

void EnviroGUI::OnSetDelete ( vtFeatureSet set)
void EnviroGUI::RefreshLayerView ( )
virtual

Reimplemented from Enviro.

void EnviroGUI::RemoveVehicle ( CarEngine *  eng)
virtual

Reimplemented from Enviro.

bool EnviroGUI::SaveStructures ( bool  bAskFilename)
bool EnviroGUI::SaveVegetation ( bool  bAskFilename)
void EnviroGUI::SetFlightSpeed ( float  speed)
virtual

Reimplemented from Enviro.

void EnviroGUI::SetProgressTerrain ( vtTerrain pTerr)
virtual

Reimplemented from Enviro.

void EnviroGUI::SetScenario ( int  num)
void EnviroGUI::SetState ( AppState  s)
virtual

Reimplemented from Enviro.

void EnviroGUI::SetTerrainToGUI ( vtTerrain pTerrain)
virtual

Reimplemented from Enviro.

void EnviroGUI::SetTimeEngineToGUI ( class vtTimeEngine pEngine)
virtual

Reimplemented from Enviro.

void EnviroGUI::SetupScene3 ( )
virtual

Reimplemented from Enviro.

void EnviroGUI::ShowDistance ( const DPoint2 p1,
const DPoint2 p2,
double  fGround,
double  fVertical 
)
virtual

Reimplemented from Enviro.

void EnviroGUI::ShowDistance ( const DLine2 path,
double  fGround,
double  fVertical 
)
virtual

Reimplemented from Enviro.

void EnviroGUI::ShowLayerView ( )
virtual

Reimplemented from Enviro.

void EnviroGUI::ShowMessage ( const vtString str)
virtual

Reimplemented from Enviro.

void EnviroGUI::ShowPopupMenu ( const IPoint2 pos)
virtual

Reimplemented from Enviro.

void EnviroGUI::ShowProgress ( bool  bShow)
virtual

Reimplemented from Enviro.

void EnviroGUI::UpdateLayerView ( )
virtual

Reimplemented from Enviro.

void EnviroGUI::UpdateProgress ( const char *  msg1,
const char *  msg2,
int  amount1,
int  amount2 
)
virtual

Reimplemented from Enviro.

Member Data Documentation

vtJoystickEngine* EnviroGUI::m_pJFlyer