World Wind v1.4 API Specification

From World Wind Wiki

(Difference between revisions)
Jump to: navigation, search
Revision as of 22:46, 28 April 2005 (edit)
Mashiharu (Talk | contribs)

← Previous diff
Revision as of 22:47, 28 April 2005 (edit) (undo)
Mashiharu (Talk | contribs)

Next diff →
Line 1: Line 1:
'''Key Interfaces that will be defined in the Plugin API''' '''Key Interfaces that will be defined in the Plugin API'''
==IRenderable== ==IRenderable==
-**Methods+*Methods
-***void Dispose()+**void Dispose()
-***<s>void Initialize(AppContext appContext)</s>+**<s>void Initialize(AppContext appContext)</s>
-***void Render(AppContext appContext)+**void Render(AppContext appContext)
-***<s>void Update(AppContext appContext)</s> Replaced by Event Handlers to the Camera (and other objects)+**<s>void Update(AppContext appContext)</s> Replaced by Event Handlers to the Camera (and other objects)
-**Properties+*Properties
-***bool Disposed{get;}+**bool Disposed{get;}
-***<s>bool Initialized{get;}</s> should be private...+**<s>bool Initialized{get;}</s> should be private...
-***Hashtable MetaData{get;set;}+**Hashtable MetaData{get;set;}
-***string Name{get;} //should this be "set" as well?+**string Name{get;} //should this be "set" as well?
-***byte Opacity{get;set;}+**byte Opacity{get;set;}
-***Vector3 Orientation{get;set;}+**Vector3 Orientation{get;set;}
-***Vector3 Position{get;set;}+**Vector3 Position{get;set;}
-***bool Visible{get;set;} //used to be "IsOn", perhaps this shouldn't be "Visible" because being "Visible" doesn't mean that an object is actually in the View Frustum.+**bool Visible{get;set;} //used to be "IsOn", perhaps this shouldn't be "Visible" because being "Visible" doesn't mean that an object is actually in the View Frustum.
==IInteractive== ==IInteractive==
//perhaps there are interfaces in .Net already for this...similar to JAVA KeyListener and MouseListener ? //perhaps there are interfaces in .Net already for this...similar to JAVA KeyListener and MouseListener ?
-**Methods+*Methods
-***void OnKeyDown(KeyEventArgs e)+**void OnKeyDown(KeyEventArgs e)
-***void OnKeyUp(KeyEventArgs e)+**void OnKeyUp(KeyEventArgs e)
-***void OnMouseDown(MouseEventArgs e)+**void OnMouseDown(MouseEventArgs e)
-***void OnMouseEnter(EventArgs e) //??+**void OnMouseEnter(EventArgs e) //??
-***void OnMouseLeave(EventArgs e)+**void OnMouseLeave(EventArgs e)
-***void OnMouseMove(MouseEventArgs e)+**void OnMouseMove(MouseEventArgs e)
-***void OnMouseUp(MouseEventArgs e)+**void OnMouseUp(MouseEventArgs e)
-***void OnMouseWheel(MouseEventArgs e)+**void OnMouseWheel(MouseEventArgs e)
==ICamera== ==ICamera==
-** Vector3 Eye{get;set;}+* Vector3 Eye{get;set;}
-** Vector3 LookAt{get;set;}+* Vector3 LookAt{get;set;}
-** Vector3 Up{get;set;} //could be just {0, 0, 1} with Quaternion rotations applied afterwards+* Vector3 Up{get;set;} //could be just {0, 0, 1} with Quaternion rotations applied afterwards
-** Quaternion EyeOrientation{get;set;} // Bank, Heading, and Tilt should be calculated from this+* Quaternion EyeOrientation{get;set;} // Bank, Heading, and Tilt should be calculated from this
-** Quaternion LookAtOrientation{get;set} // Heading and Tilt should should be calculated from this+* Quaternion LookAtOrientation{get;set} // Heading and Tilt should should be calculated from this
-** Angle Fov{get;set;}+* Angle Fov{get;set;}
==IWorld== ==IWorld==
-** double Flattening{get;}+* double Flattening{get;}
-** double EquatorialRadius{get;}+* double EquatorialRadius{get;}
-** double PolarRadius{get;}+* double PolarRadius{get;}
==RenderableList <class>== ==RenderableList <class>==
-**Methods+*Methods
-***void Add(IRenderable renderable)+**void Add(IRenderable renderable)
-***void Dispose()+**void Dispose()
-***void Initialize(AppContext appContext)+**void Initialize(AppContext appContext)
-***void Remove(string name)+**void Remove(string name)
-***void Render(AppContext appContext)+**void Render(AppContext appContext)
-***void Update(AppContext appContext)+**void Update(AppContext appContext)
-**Properties+*Properties
-***ArrayList ChildRenderables{get;set;}+**ArrayList ChildRenderables{get;set;}
-***bool Disposed{get;}+**bool Disposed{get;}
-***bool Initialized{get;}+**bool Initialized{get;}
-***Hashtable MetaData{get;set;}+**Hashtable MetaData{get;set;}
-***string Name+**string Name
-***byte Opacity{get;set;}+**byte Opacity{get;set;}
-***bool Visible{get;set;}+**bool Visible{get;set;}
==GUIHelper <class>== ==GUIHelper <class>==
-** string[] .Menus.GetTopLevel()+* string[] .Menus.GetTopLevel()
-** string[] .Menu[item].GetChildren()+* string[] .Menu[item].GetChildren()
-** .Menus[item].Insert(string text, method to call...)+* .Menus[item].Insert(string text, method to call...)
-** .IconBar.Count+* .IconBar.Count
-** .IconBar.Add(Bitmap icon, int position, method to call...)+* .IconBar.Add(Bitmap icon, int position, method to call...)
-** methods to get/set each WWSetting (sticking each property get/set '''only''' in the Class might cumbersome. What is best way to get all names and types?)+* methods to get/set each WWSetting (sticking each property get/set '''only''' in the Class might cumbersome. What is best way to get all names and types?)
==AppContext <class>== ==AppContext <class>==
-**Direct3D.Device Direct3D_Device+*Direct3D.Device Direct3D_Device
-**int ScreenWidth+*int ScreenWidth
-**int ScreenHeight+*int ScreenHeight
-**...+*...
One issue that has always bothered me was whether to exclusively make the camera "focus" on a "World" or whether to make it focus on a "RenderableObject". Of course, you cannot really define what a view range is if you focus on something like the International Space Station, but perhaps someone '''would''' want to focus on that... One issue that has always bothered me was whether to exclusively make the camera "focus" on a "World" or whether to make it focus on a "RenderableObject". Of course, you cannot really define what a view range is if you focus on something like the International Space Station, but perhaps someone '''would''' want to focus on that...

Revision as of 22:47, 28 April 2005

Key Interfaces that will be defined in the Plugin API

Contents

IRenderable

  • Methods
    • void Dispose()
    • void Initialize(AppContext appContext)
    • void Render(AppContext appContext)
    • void Update(AppContext appContext) Replaced by Event Handlers to the Camera (and other objects)
  • Properties
    • bool Disposed{get;}
    • bool Initialized{get;} should be private...
    • Hashtable MetaData{get;set;}
    • string Name{get;} //should this be "set" as well?
    • byte Opacity{get;set;}
    • Vector3 Orientation{get;set;}
    • Vector3 Position{get;set;}
    • bool Visible{get;set;} //used to be "IsOn", perhaps this shouldn't be "Visible" because being "Visible" doesn't mean that an object is actually in the View Frustum.

IInteractive

//perhaps there are interfaces in .Net already for this...similar to JAVA KeyListener and MouseListener ?

  • Methods
    • void OnKeyDown(KeyEventArgs e)
    • void OnKeyUp(KeyEventArgs e)
    • void OnMouseDown(MouseEventArgs e)
    • void OnMouseEnter(EventArgs e) //??
    • void OnMouseLeave(EventArgs e)
    • void OnMouseMove(MouseEventArgs e)
    • void OnMouseUp(MouseEventArgs e)
    • void OnMouseWheel(MouseEventArgs e)

ICamera

  • Vector3 Eye{get;set;}
  • Vector3 LookAt{get;set;}
  • Vector3 Up{get;set;} //could be just {0, 0, 1} with Quaternion rotations applied afterwards
  • Quaternion EyeOrientation{get;set;} // Bank, Heading, and Tilt should be calculated from this
  • Quaternion LookAtOrientation{get;set} // Heading and Tilt should should be calculated from this
  • Angle Fov{get;set;}

IWorld

  • double Flattening{get;}
  • double EquatorialRadius{get;}
  • double PolarRadius{get;}

RenderableList <class>

  • Methods
    • void Add(IRenderable renderable)
    • void Dispose()
    • void Initialize(AppContext appContext)
    • void Remove(string name)
    • void Render(AppContext appContext)
    • void Update(AppContext appContext)
  • Properties
    • ArrayList ChildRenderables{get;set;}
    • bool Disposed{get;}
    • bool Initialized{get;}
    • Hashtable MetaData{get;set;}
    • string Name
    • byte Opacity{get;set;}
    • bool Visible{get;set;}

GUIHelper <class>

  • string[] .Menus.GetTopLevel()
  • string[] .Menu[item].GetChildren()
  • .Menus[item].Insert(string text, method to call...)
  • .IconBar.Count
  • .IconBar.Add(Bitmap icon, int position, method to call...)
  • methods to get/set each WWSetting (sticking each property get/set only in the Class might cumbersome. What is best way to get all names and types?)

AppContext <class>

  • Direct3D.Device Direct3D_Device
  • int ScreenWidth
  • int ScreenHeight
  • ...

One issue that has always bothered me was whether to exclusively make the camera "focus" on a "World" or whether to make it focus on a "RenderableObject". Of course, you cannot really define what a view range is if you focus on something like the International Space Station, but perhaps someone would want to focus on that...

Personal tools