wxGUI.Nviz.html 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329
  1. <h2>DESCRIPTION</h2>
  2. Note: <b>wxNviz is currently under development. Not
  3. all functionality is implemented.</b>
  4. <p>
  5. <b>wxNviz</b> is a <em><a href="wxGUI.html">wxGUI</a></em> <b>3D view
  6. mode</b> which allows users to realistically render multiple
  7. <em>surfaces</em> (raster data) in a 3D space, optionally using
  8. thematic coloring, draping 2D <em>vector</em> data over the surfaces,
  9. displaying 3D vector data in the space, and visualization
  10. of <em>volume</em> data (3D raster data).
  11. <p>
  12. To start the wxGUI 3D view mode, choose '3D view' from the map
  13. toolbar.
  14. <p>
  15. wxNviz is emphasized on the ease and speed of viewer positioning and
  16. provided flexibility for using a wide range of data. A low resolution
  17. surface or wire grid (optional) provides real-time viewer positioning
  18. capabilities. Coarse and fine resolution controls allow the user to
  19. further refine drawing speed and detail as needed. Continuous scaling
  20. of elevation provides the ability to use various data types for the
  21. vertical dimension.
  22. <p>
  23. For each session of wxNviz, you might want the same set of 2D/3D
  24. raster and vector data, view parameters, or other attributes. For
  25. consistency between sessions, you can store this information in the
  26. GRASS <em>workspace</em> file (gxw). Workspace contains information to
  27. restore "state" of the system in 2D and if wxNviz is enabled also in
  28. the 3D display mode.
  29. <h2>3D View Toolbar</h2>
  30. <center>
  31. <br><img src="wxGUI_nviz_toolbar.jpg" border="1"><br><br>
  32. </center>
  33. <dl>
  34. <dt><img src="icons/grass2/3d-view.png">&nbsp;
  35. <em>Switch to view page</em></dt>
  36. <dd>Switch 3D Layer Manager Toolbox's page to the <b>view</b>
  37. control page.</dd>
  38. <dt><img src="icons/grass2/3d-raster.png">&nbsp;
  39. <em>Switch to surface page</em></dt>
  40. <dd>Switch 3D Layer Manager Toolbox's page to the <b>surface</b>
  41. control page (data properties).</dd>
  42. <dt><img src="icons/grass2/3d-vector.png">&nbsp;
  43. <em>Switch to vector page</em></dt>
  44. <dd>Switch 3D Layer Manager Toolbox's page to the <b>vector</b>
  45. control page (data properties).</dd>
  46. <dt><img src="icons/grass2/3d-volume.png">&nbsp;
  47. <em>Switch to volume page</em></dt>
  48. <dd>Switch 3D Layer Manager Toolbox's page to the <b>volume</b>
  49. control page (data properties).</dd>
  50. <dt><img src="icons/grass2/3d-light.png">&nbsp;
  51. <em>Switch to light page</em></dt>
  52. <dd>Switch 3D Layer Manager Toolbox's page to the <b>light</b>
  53. control page (appearance).</dd>
  54. <dt><img src="icons/grass2/3d-fringe.png">&nbsp;
  55. <em>Switch to fringe page</em></dt>
  56. <dd>Switch 3D Layer Manager Toolbox's page to the <b>fringe</b>
  57. control page (appearance).</dd>
  58. <dt><img src="icons/grass2/settings.png">&nbsp;
  59. <em>Show 3D view mode settings</em></dt>
  60. <dd>Show dialog with settings for wxGUI 3D view mode. The user
  61. settings can be stored in wxGUI settings file.</dd>
  62. <dt><img src="icons/grass2/help.png">&nbsp;
  63. <em>Show help</em></dt>
  64. <dd>Show this help.</dd>
  65. <dt><img src="icons/grass2/quit.png">&nbsp;
  66. <em>Quit</em></dt>
  67. <dd>Quit 3D view mode and switch map display to the 2D view
  68. mode.</dd>
  69. </dl>
  70. <h2>3D View Layer Manager Toolbox</h2>
  71. The 3D view toolbox is integrated in the Layer Manager. The toolbox
  72. has several tabs:
  73. <ul>
  74. <li><b>View</b> for view controling,</li>
  75. <li><b>Data</b> for data properties,</li>
  76. <li><b>Appearance</b> for appearance settings (lighting, fringes, ...).</li>
  77. </ul>
  78. <h3>View</h3>
  79. You can use this panel to set the <em>position, direction, and
  80. perspective</em> of the view. The position box shows a puck with a
  81. direction line pointing to the center. The direction line indicates
  82. the look direction (azimuth). You click and drag the puck to change
  83. the current eye position. The box annotations are North, South,
  84. East, and West. You can also set exact position using <em>Look
  85. at</em> choice control.
  86. <center>
  87. <br><img src="wxGUI_nviz_tools_view.jpg" border="1"><br><br>
  88. </center>
  89. You can adjust the viewer's height above the scene, angle of view or
  90. twist value to rotate the scene about the horizontal axis. An angle of
  91. 0 is flat. The scene rotates between -90 and 90 degrees.
  92. <p>
  93. You can also adjusts the vertical exaggeration of the surface. As an
  94. example, if the easting and northing are in meters and the elevation
  95. in feet, a vertical exaggeration of 0.305 would produce a true
  96. (unexaggerated) surface.
  97. <p>
  98. <em>Reset</em> returns all current settings to their default values.
  99. <h3>Data properties - Surface</h3>
  100. Each active raster map layer from the current layer tree is displayed
  101. as surface in the 3D space. Separate raster data or constants can be
  102. used for various attributes of the surface:
  103. <ul>
  104. <li><b>topography</b> - raster map or constant values used as elevation (z
  105. values) for the current surface.</li>
  106. <li><b>color</b> - raster map or constant color to drape over the current
  107. surface. This option is useful for draping imagery such as aerial
  108. photography over a DEM.</li>
  109. <li><b>mask</b> - raster map that controls the areas displayed from
  110. the current surface.</li>
  111. <li><b>transparency</b> - raster map or constant value that controls
  112. the transparency of the current surface. The default is completely
  113. opaque. Range from 0 (opaque) to 255 (transparent).</li>
  114. <li><b>shininess</b> - raster map or constant value that controls
  115. the shininess (reflectivity) of the current surface. Range from 0 to
  116. 255.</li>
  117. <li><b>emission</b> - raster map or constant value that controls the
  118. light emitted from the current surface. Range from 0 to 255.</li>
  119. </ul>
  120. This panel controls how loaded surfaces are drawn. The top half of the
  121. panel has options to set, unset or modify attributes of the current
  122. surface. The bottom half has drawing style options, masking or
  123. changing surface position in the space.
  124. <center>
  125. <br><img src="wxGUI_nviz_tools_surface.jpg" border="1"><br><br>
  126. </center>
  127. Surface can be drawn as a wire mesh or using filled polygons (most
  128. realistic). You can set draw <b>mode</b> to <em>coarse</em> (fast
  129. display mode), <em>fine</em> (draws surface as filled polygons with
  130. fine resolution) or <em>both</em> (which combines coarse and fine
  131. mode). Additionally set coarse <b>style</b> to <em>wire</em> to draw
  132. the surface as wire mesh (you can also choose color of the wire)
  133. or <em>surface</em> to draw the surface using coarse resolution filled
  134. polygons. This is a low resolution version of the polygon surface
  135. style.
  136. E.g. surface is drawn as a wire mesh if you set <b>mode</b>
  137. to <em>coarse</em> and <b>style</b> to <em>wire</em>. Note that it
  138. differs from the mesh drawn in fast display mode because hidden lines
  139. are not drawn. To draw the surface using filled polygons, but with
  140. wire mesh draped over it, choose <b>mode</b> <em>both</em>
  141. and <b>style</b> <em>wire</em>.
  142. Beside mode and style you can also choose style of <b>shading</b> used
  143. for the surface. <em>Gouraud</em> style draws the surfaces with a
  144. smooth shading to blend individual cell colors together, <em>flat</em>
  145. draws the surfaces with flat shading with one color for every two
  146. cells. The surface appears faceted.
  147. <p>
  148. To set given draw settings for all loaded surfaces press button "All".
  149. <h3>Data properties - Vector</h3>
  150. 2D vector data can be draped on the selected surfaces with various
  151. markers to represent point data; you can use attribute of vector
  152. features to determine size, color, shape of glyph.
  153. 3D vector data including volumes (closed group of faces with one
  154. kernel inside) is also supported.
  155. This panel controls how loaded 2D or 3D vector data are drawn.
  156. <p>
  157. You can define the width (in pixels) of the line features, the color
  158. used for lines or point markers.
  159. <center>
  160. <br><img src="wxGUI_nviz_tools_vector.jpg" border="1"><br><br>
  161. </center>
  162. If vector map is 2D you can display vector features as flat at a
  163. specified elevation or drape it over a surface(s) at a specified
  164. height. Use the height control to set the flat elevation or the drape
  165. height above the surface(s).
  166. <p>
  167. For display purposes, it is better to set the height slightly above
  168. the surface. If the height is set at zero, portions of the vector may
  169. disappear into the surface(s).
  170. <p>
  171. For 2D/3D vector points you can also set the size of the markers and
  172. the width (in pixels) of the line used to draw the point markers (only
  173. applies to wire-frame markers). Currently are implemented these
  174. markers:
  175. <ul>
  176. <li><b>x</b> sets the current points markers to a 2D "X",</li>
  177. <li><b>sphere</b> - solid 3D sphere,</li>
  178. <li><b>diamond</b> - solid 3D diamond,</li>
  179. <li><b>cube</b> - solid 3D cube,</li>
  180. <li><b>box</b> - hollow 3D cube,</li>
  181. <li><b>gyroscope</b> - hollow 3D sphere,</li>
  182. <li><b>asterisk</b> - 3D line-star.</li>
  183. </ul>
  184. <h3>Data properties - Volume</h3>
  185. Volumes can be displayed either as isosurfaces or slices. Various
  186. attributes of the isosurface can be defined, similarly to surface
  187. attributes:
  188. <ul>
  189. <li><b>level</b> - reference isosurface level (height in map
  190. units).</li>
  191. <li><b>color</b> - raster map or constant color to drape over the
  192. current volume.</li>
  193. <li><b>mask</b> - raster map that controls the areas displayed from
  194. the current volume.</li>
  195. <li><b>transparency</b> - raster map or constant value that controls
  196. the transparency of the current volume. The default is completely
  197. opaque. Range from 0 (opaque) to 255 (transparent).</li>
  198. <li><b>shininess</b> - raster map or constant value that controls
  199. the shininess (reflectivity) of the current volume. Range from 0 to
  200. 255.</li>
  201. <li><b>emission</b> - raster map or constant value that controls the
  202. light emitted from the current volume. Range from 0 to 255.</li>
  203. </ul>
  204. <p>
  205. This panel controls how loaded volumes are drawn. Volume can be drawn
  206. in two different modes: <b>isosurface</b> or <b>slice</b>. The top
  207. part of the panel has drawing style options. The middle part has
  208. controls to add, delete, move up/down selected isosurface or
  209. slices. The bottom part has options to set, unset or modify attributes
  210. of the current isosurface or slice.
  211. <center>
  212. <br><img src="wxGUI_nviz_tools_volume.jpg" border="1"><br><br>
  213. </center>
  214. Similarly to surface panel you can define draw <b>shading</b>
  215. - <em>gouraud</em> (draws the volumes with a smooth shading to blend
  216. individual cell colors together) and <em>flat</em> (draws the volumes
  217. with flat shading with one color for every two cells. The volume
  218. appears faceted). As mentioned above currently are supported two
  219. visualization modes:
  220. <ul>
  221. <li><b>isosurface</b> - the levels of values for drawing the
  222. volume(s) as isosurfaces,</li>
  223. <li>and <b>slice</b> - the levels of values for drawing the volume
  224. as cross-sections.</li>
  225. </ul>
  226. <h2>Settings</h2>
  227. This panel has controls which allows user to set default surface,
  228. vector and volume data attributes. You can also modify default view
  229. parameters, or to set the background color of the Map Display Window
  230. (the default color is white).
  231. <h2>To be implement</h2>
  232. <ul>
  233. <li>Improve intuitive navigation (mouse, fly mode)</li>
  234. <li>Animation capabilities</li>
  235. <li>Arbitrary cutting planes</li>
  236. <li>Labels, decoration, etc.</li>
  237. <li>Scripting capabilities</li>
  238. <li>Better workspace support (view settings, lighting)
  239. <li>Surface - mask by zero/elevation, more interactive positioning</li>
  240. <li>Vector points - implement display mode flat/surface for 2D points</li>
  241. <li>Volume - slice draw mode</li>
  242. <li>...</li>
  243. </ul>
  244. <p>
  245. <b>Please note that wxNviz is under active development and
  246. distributed as &quot;Experimental Prototype&quot;.</b>
  247. <h2>SEE ALSO</h2>
  248. <em>
  249. <a href="wxGUI.html">wxGUI</a>
  250. </em>
  251. <p>
  252. Other wxGUI components:<br>
  253. <em>
  254. <a href="wxGUI.Vector_Digitizer.html">Vector Digitizer</a><br>
  255. <a href="wxGUI.Attribute_Table_Manager.html">Attribute Table Manager</a><br>
  256. <a href="wxGUI.Modeler.html">Graphical Modeler</a><br>
  257. <a href="wxGUI.GCP_Manager.html">Manage Ground Control Points</a><br>
  258. </em>
  259. <p>
  260. See also <a href="http://grass.osgeo.org/wiki/WxNVIZ">wiki</a> page.
  261. <br><br>
  262. Command-line module <em><a href="nviz_cmd.html">nviz_cmd</a></em>.
  263. <br><br>
  264. Original <a href="nviz.html">TCL/TK-based</a> Nviz.
  265. <h2>AUTHORS</h2>
  266. Martin
  267. Landa, <a href="http://grass.osgeo.org/wiki/WxNviz_GSoC_2008">Google
  268. Summer of Code 2008</a> (mentor: Michael Barton)
  269. and <a href="http://grass.osgeo.org/wiki/WxNviz_GSoC_2010">Google
  270. Summer of Code 2010</a> (mentor: Helena Mitasova)
  271. <p>
  272. <i>$Date$</i>