WxNviz GSoC 2011: Difference between revisions

From GRASS-Wiki
Jump to navigation Jump to search
No edit summary
 
(55 intermediate revisions by 2 users not shown)
Line 17: Line 17:
__TOC__
__TOC__
== Application ==
== Application ==


=== Introduction ===
=== Introduction ===
Line 28: Line 27:
result to replace Tcl/Tk-based nviz in GRASS 7 by modern 3D
result to replace Tcl/Tk-based nviz in GRASS 7 by modern 3D
visualization tool integrated in wxGUI.
visualization tool integrated in wxGUI.


=== Background ===
=== Background ===
Line 57: Line 55:
and [[wxNviz GSoC 2010|2010]] and it
and [[wxNviz GSoC 2010|2010]] and it
should make wxNviz fully functional.
should make wxNviz fully functional.


=== The idea ===
=== The idea ===
Line 73: Line 69:
Prague), was dealing with this issue so new view control could follow
Prague), was dealing with this issue so new view control could follow
his results.
his results.


=== Project plan ===
=== Project plan ===


{| {{table}}
{| {{table}}
|April 26 - May 22 || Bonding period
|-
|-
|May 23 || fixing existing bugs
!Period !! Task !! Status / Notes
|-
|-
|May 30 || improve GUI design
|April 26 - May 22 || Bonding period || {{done}}
|-
|-
|June 6 || implement cutting planes
|May 23 || fixing existing bugs || never ending story ;-)
|-
|-
|June 13 || thematic points
|May 30 || improve GUI design || {{done}}
|-
|-
|June 20 || testing, bug fixing
|June 6 || implement cutting planes || {{done}}
|-
|-
|June 27 || testing, bug fixing
|June 13 || thematic points || postponed, {{done}}
|-
|-
|July 4 || nviz_cmd - "save state"
|June 20 || testing, bug fixing || {{done}}
|-
|-
|July 11 || implement decorations
|June 27 || testing, bug fixing || {{done}}
|-
|-
|'''July 15''' || Mid-term evaluations deadline
|July 4 || nviz_cmd - "save state" || {{done}}
|-
|-
|July 18 || volumes - cross sections
|July 11 || implement decorations || text missing, not working on Mac
|-
|-
|July 25 || better view control
|'''July 15''' || Mid-term evaluations deadline || {{done}}
|-
|-
|August 1 || implement vector data querying
|July 18 || volumes - cross sections || {{done}}
|-
|-
|August 8 || implement scaled difference
|July 25 || better view control || panning to be implemented
|-
|-
|August 15 || testing, documentation
|August 1 || implement vector data querying || {{done}} using {{cmd|v.what}}
|-
|-
|August 22 || Final evaluation
|August 8 || implement scaled difference || missing
|-
|August 15 || testing, documentation || {{done}}
|-
|'''August 22''' || Final evaluation
|}
|}
; TODO (ML)
* text rendering in OpenGL
==== Last TODOs before final pencils down ====
* add few video-tutorials on [[WxNviz#Video_tutorials|wxNviz page]]
== How to test ==
Download {{twiki|DownloadSource#GRASS7|GRASS 7}} from SVN repository.
Please report any bugs, wishes via {{twiki|WikiStart#BugTracking|trac}}:
component: wxGUI
keywords: nviz
See list of [http://trac.osgeo.org/grass/query?status=assigned&status=new&status=reopened&component=wxGUI&order=priority&col=id&col=summary&col=status&col=type&col=priority&col=milestone&col=component&keywords=~nviz known bugs].


== Roadmap ==
== Roadmap ==
Line 117: Line 134:
* GUI enhancements (enable to change range of sliders, foldpanel bar)
* GUI enhancements (enable to change range of sliders, foldpanel bar)


=== Week 1 (May 30) ===
* bug fixing - lights - {{rev|46504}}
* new functionality - constant surfaces, ''look here'' feature - {{rev|46504}}
* selection of surfaces on which vector points/lines should be displayed - {{rev|46558}}
<center>
{|
|-
| [[Image:WxNviz surface page.png|250px|thumb|Surface page of WxNviz modified (2011-06-02)]]
| [[Image:WxNviz_constant_surface_page.png|250px|thumb|Constant surface page added (2011-06-02)]]
| [[Image:WxNviz_lighting.png|250px|thumb|Lighting fixed (2011-05-02)]]
|-
|}
</center>
=== Week 2 (June 6) ===
* cutting planes - {{rev|46654}}
* view page GUI modified
<center>
{|
|-
| [[Image:WxNviz_cutting_planes_1.png|250px|thumb|Cutting planes (shading blend) (2011-06-10)]]
| [[Image:WxNviz_cutting_planes_2.png|250px|thumb|Cutting planes (shading top color) (2011-06-10)]]
| [[Image:WxNviz_view_page.png|150px|thumb|View page modified (2011-06-10)]]
|-
|}
</center>
=== Week 3 (June 13) ===
=== Week 4 (June 20) ===
* new nviz features in workspace: view, light, constant planes ({{rev|46775}})
=== Week 5 (June 27) ===
* nviz light model and fringe problem hopefully fixed
* generating commands for nviz_cmd (view, light, surfaces, vectors, cutting plane, fringe)
* nviz_cmd - cutting planes added
<center>
{|
|-
| [[Image:Nviz_cmd_cutting_planes.png‎|250px|thumb|Picture of surfaces cut by two planes (generated by nviz_cmd)  (2011-06-30)]]
| [[Image:WxNviz_generate_command.png‎|250px|thumb|Command for nviz_cmd generated by wxNviz (2011-07-01)]]
|-
|}
</center>
=== Week 6 (July 4) ===
* north arrow implemented
* fixed some bugs in volumes
* add new functionality to nviz_cmd - north arrow, missing features from volumes
* interactive positioning (x, y) of cutting planes (need to be improved)
<center>
{|
|-
| [[Image:WxNviz_north_arrow.png‎|250px|thumb|North Arrow implemented (2011-07-08)]]
| [[Image:WxNviz_volumes.png‎|250px|thumb|Colored isosurfaces with transparency (2011-07-08)]]
|-
|}
</center>
=== Week 7 (July 11) ===
* volume slices implemented
* volume slices added to nviz_cmd
* transparency added to constant planes
<center>
{|
|-
| [[Image:WxNviz_volume_slices_1.png‎|250px|thumb|Partially transparent slice (2011-07-14)]]
| [[Image:WxNviz_volume_slices_2.png‎|250px|thumb|Combination of slices and isosurface (2011-07-14)]]
|-
|}
</center>
=== Week 8 (July 18) ===
* legend and text labels (reuse 2D mode)
* partly solved latlon maps - sliders for float values (z-exag, position), still problem with lighting
<center>
{|
|-
| [[Image:WxNviz_overlays.png‎|250px|thumb|Raster legend, text label and north arrow (2011-07-22)]]
|-
|}
</center>




=== Week 9 (July 25) ===
* legend and text rendering is still not solved for Mac
* interactive legend resizing for 2D view (not yet implemented in 3D)
=== Week 10 (August 1) ===
* rotation with 3D scene by mouse dragging (it's now bound to pan button -- just temporary solution)
* problem with updating region hopefully fixed
* first implementation of thematic mapping for points
:only colors supported
:entering values is done manually
<center>
{|
|-
| [[Image:WxNviz_thematic_points_colors‎.png|250px|thumb| Thematic mapping (colors) for points (2011-08-05)]]
| [[Image:WxNviz_colorrules_dialog.png|150px|thumb| Dialog for {{cmd|v.colors}} opened from 3D view (2011-08-05)]]
|-
|}
</center>
=== Week 11 and 12 (August 8 and 15) ===
* improvements of thematic mapping, dialog supports both vector color tables (implemented by Martin L.) and attribute columns
* update documentation


== Weekly Reports ==
== Weekly Reports ==
* [http://lists.osgeo.org/pipermail/grass-dev/2011-May/054526.html #0 (2010/05/24)]
* [http://lists.osgeo.org/pipermail/grass-dev/2011-May/054526.html #0 (2011/05/24)]
 
* [http://lists.osgeo.org/pipermail/grass-dev/2011-June/054624.html #1 (2011/06/03)]
* [http://lists.osgeo.org/pipermail/grass-dev/2011-June/054674.html #2 (2011/06/10)]
* [http://lists.osgeo.org/pipermail/grass-dev/2011-June/054754.html #3 (2011/06/17)]
* [http://lists.osgeo.org/pipermail/grass-dev/2011-June/054823.html #4 (2011/06/24)]
* [http://lists.osgeo.org/pipermail/grass-dev/2011-July/054880.html #5 (2011/07/01)]
* [http://lists.osgeo.org/pipermail/grass-dev/2011-July/054956.html #6 (2011/07/08)]
* [http://lists.osgeo.org/pipermail/grass-dev/2011-July/055013.html #7 (2011/07/15)]
* [http://lists.osgeo.org/pipermail/grass-dev/2011-July/055107.html #8 (2011/07/22)]
* [http://lists.osgeo.org/pipermail/grass-dev/2011-July/055202.html #9 (2011/07/29)]
* [http://lists.osgeo.org/pipermail/grass-dev/2011-August/055256.html #10 (2011/08/05)]
* [http://lists.osgeo.org/pipermail/grass-dev/2011-August/055321.html #11 (2011/08/12)]
* [http://lists.osgeo.org/pipermail/grass-dev/2011-August/055422.html #12 (2011/08/19)]
{{wxGUI}}
{{wxGUI}}
{{GSoC}}
{{GSoC}}

Latest revision as of 09:36, 26 September 2011

See wxNviz page.

Accepted Google Summer of Code 2011 project, see also related GSoC 2008 and GSoC 2010 pages.

Student Name: Anna Kratochvilova, Czech University in Prague
Organization: OSGeo - Open Source Geospatial Foundation
Mentor Name: Martin Landa, Helena Mitasova
Title: Completion of wxGUI Nviz extension for 3D data visualization in GRASS GIS
Abstract
This project continues in the development of GRASS GIS 3D visualizaton tool wxNviz based on wxPython and underlying OGSF library. The goal is to add missing functionality so that wxNviz's predecessor written in Tcl/Tk could be replaced by completed wxNviz in GRASS 7. The plan is to add missing features like animations or cutting planes and additionally implement better view control.

Application

Introduction

This project continues in the development of wxNviz as 3D visualization tool for native GRASS GUI (wxGUI). Nviz graphical user interface is originally written in Tcl/Tk. Tcl/Tk-based nviz is planed to be removed in GRASS 7 and still waits for its completed successor. Currently wxNviz lacks many features of original Nviz application. The goal of this project is to add the missing functionality and in the result to replace Tcl/Tk-based nviz in GRASS 7 by modern 3D visualization tool integrated in wxGUI.

Background

GRASS GIS (Geographic Resources Analysis Support System) is one of the largest open source Geographic Information Systems. GRASS GIS is a Free Software project released under the GNU General Public License and it is the part of Open Source Geospatial Foundation. GRASS GIS consists of more than 400 modules for spatial analysis, image processing, manipulation and visualization of many types of data. It is widely used in academic and commercial settings thanks to its powerful tools providing functionality missing in other geographic information systems. GRASS works on multiple platforms, including Linux, Mac OS X and Microsoft Windows.

GRASS was originally controlled via its command line. The first graphical user interface was written in Tcl/Tk, which later appeared to be insufficient. Since 2006 new wxGUI is being developed using wxPython as a GUI toolkit for the Python programming language.

wxNviz is a one of the wxGUI extensions. It enables visualization of multiple surfaces (raster data) in 3D space, volume data (3D raster data), overlaying 2D vector data over surfaces and displaying 3D vector data. wxNviz uses OGSF and Nviz library as an interface for OpenGL. Completion of wxNviz is essential for GRASS 7 which can be released only without dependency on Tcl/Tk. This project picks up on wxNviz development within Google Summer of Code 2008 and 2010 and it should make wxNviz fully functional.

The idea

At present wxNviz provides only partial functionality of Tcl/Tk-based nviz so this project focuses on completion of this wxGUI extension. The plan is to add following missing features: cutting planes, scaled difference, animations, vector data querying, decorations (north arrow, legend, labels, scale bar). Implementation of missing functionality would remove the major obstacle of GRASS 7 release which is the dependency on Tcl/Tk-based Nviz. Additional plan is to improve view controlling which is not very intuitive presently. Petr Voldan, a PhD student of our faculty (FCE CTU in Prague), was dealing with this issue so new view control could follow his results.

Project plan

Period Task Status / Notes
April 26 - May 22 Bonding period
May 23 fixing existing bugs never ending story ;-)
May 30 improve GUI design
June 6 implement cutting planes
June 13 thematic points postponed,
June 20 testing, bug fixing
June 27 testing, bug fixing
July 4 nviz_cmd - "save state"
July 11 implement decorations text missing, not working on Mac
July 15 Mid-term evaluations deadline
July 18 volumes - cross sections
July 25 better view control panning to be implemented
August 1 implement vector data querying using v.what
August 8 implement scaled difference missing
August 15 testing, documentation
August 22 Final evaluation
TODO (ML)
  • text rendering in OpenGL

Last TODOs before final pencils down

How to test

Download GRASS 7 from SVN repository.

Please report any bugs, wishes via trac:

component: wxGUI
keywords: nviz

See list of known bugs.

Roadmap

Week 0 (May 23)

  • bug fixing - r46208
  • GUI enhancements (enable to change range of sliders, foldpanel bar)

Week 1 (May 30)

  • bug fixing - lights - r46504
  • new functionality - constant surfaces, look here feature - r46504
  • selection of surfaces on which vector points/lines should be displayed - r46558
Surface page of WxNviz modified (2011-06-02)
Constant surface page added (2011-06-02)
Lighting fixed (2011-05-02)

Week 2 (June 6)

  • cutting planes - r46654
  • view page GUI modified
Cutting planes (shading blend) (2011-06-10)
Cutting planes (shading top color) (2011-06-10)
View page modified (2011-06-10)

Week 3 (June 13)

Week 4 (June 20)

  • new nviz features in workspace: view, light, constant planes (r46775)

Week 5 (June 27)

  • nviz light model and fringe problem hopefully fixed
  • generating commands for nviz_cmd (view, light, surfaces, vectors, cutting plane, fringe)
  • nviz_cmd - cutting planes added
Picture of surfaces cut by two planes (generated by nviz_cmd) (2011-06-30)
Command for nviz_cmd generated by wxNviz (2011-07-01)

Week 6 (July 4)

  • north arrow implemented
  • fixed some bugs in volumes
  • add new functionality to nviz_cmd - north arrow, missing features from volumes
  • interactive positioning (x, y) of cutting planes (need to be improved)
North Arrow implemented (2011-07-08)
Colored isosurfaces with transparency (2011-07-08)

Week 7 (July 11)

  • volume slices implemented
  • volume slices added to nviz_cmd
  • transparency added to constant planes
Partially transparent slice (2011-07-14)
Combination of slices and isosurface (2011-07-14)

Week 8 (July 18)

  • legend and text labels (reuse 2D mode)
  • partly solved latlon maps - sliders for float values (z-exag, position), still problem with lighting
Raster legend, text label and north arrow (2011-07-22)


Week 9 (July 25)

  • legend and text rendering is still not solved for Mac
  • interactive legend resizing for 2D view (not yet implemented in 3D)


Week 10 (August 1)

  • rotation with 3D scene by mouse dragging (it's now bound to pan button -- just temporary solution)
  • problem with updating region hopefully fixed
  • first implementation of thematic mapping for points
only colors supported
entering values is done manually
Thematic mapping (colors) for points (2011-08-05)
Dialog for v.colors opened from 3D view (2011-08-05)

Week 11 and 12 (August 8 and 15)

  • improvements of thematic mapping, dialog supports both vector color tables (implemented by Martin L.) and attribute columns
  • update documentation

Weekly Reports