GRASS Programmer's Manual  6.4.4(2014)-r
Todo List
Namespace core.units
Probably will be replaced by Python ctypes fns in the near future(?)
globalScope> Global db_set_default_connection (void)
DB_OK on success, DB_* error code on fail
Global dialogs.ImportDialog.OnAbort (self, event)
not yet implemented
Global frame.GMFrame.LoadWorkspaceFile (self, filename)
Validate against DTD
Global frame.MapFrame.RemoveToolbar (self, name)
Only hide, activate by calling AddToolbar()
globalScope> Global get_vert_intersects (geosurf *gs, float *bgn, float *end, float *dir)
For consistancy, need to decide how last row & last column are displayed - would it look funny to always draw last row/col with finer resolution if necessary, or would it be better to only show full rows/cols?
Global goutput.GMConsole.RunCmd
Display commands (*.d) are captured and processed separately by mapdisp.py. Display commands are rendered in map display widget that currently has the focus (as indicted by mdidx).
Global goutput.PyStc.OnKeyPressed (self, event)
implement code completion (see wxPython demo)
globalScope> Global GP_attmode_color (int id, const char *filename)
make similar routines for attmode_size, attmode_marker (use transform)
globalScope> Global GP_load_site (int id, const char *filename)
load file handle & ready for reading instead of using memory
globalScope> Global gpd_2dsite (geosite *gp, geosurf *gs, int do_fast)
prevent scaling by 0
globalScope> Global gpd_obj (geosurf *gs, int color, float size, int marker, Point3 pt)
add size1, size2 & dir1, dir2 (eg azimuth, elevation) variables
globalScope> Global gs_calc_normals (geosurf *gs)
fix to correctly calculate norms when mapped to sphere!
globalScope> Global gs_clip_segment (geosurf *gs, float *bgn, float *end, float *region)
to use fast clipping and move to gs.c
globalScope> Global GS_draw_legend (const char *name, GLuint fontbase, int size, int *flags, float *range, int *pt)
add legend from list option make font loading more flexible
globalScope> Global GS_get_cat_at_xy (int id, int att, char *catstr, float x, float y)
Allocate catstr using G_store()
globalScope> Global GS_get_to (float *to)
need set_to? - just use viewdir?
globalScope> Global gs_get_zextents (geosurf *gs, float *min, float *max, float *mid)
pass flag to use zminmasked instead of zmin
globalScope> Global gs_get_zrange0 (float *min, float *max)
pass flag to use zminmasked instead of zmin could also have this return a weighted average for vertical "centroid"
globalScope> Global gs_init_surf (geosurf *gs, double ox, double oy, int rows, int cols, double xres, double yres)
Now xmin & ox are the same, right? - get rid of ox, oy in geosurf struct?
globalScope> Global GS_init_view (void)
allow to set center?
globalScope> Global Gs_loadmap_as_char (struct Cell_head *wind, const char *map_name, unsigned char *buff, struct BM *nullmap, int *has_null)
fn body Gs_loadmap_as_float()
globalScope> Global Gs_loadmap_as_int (struct Cell_head *wind, const char *map_name, int *buff, struct BM *nullmap, int *has_null)
fn body of Gs_loadmap_as_float()
globalScope> Global gs_put_label (const char *text, GLuint fontbase, int size, unsigned long color, int *pt)
Allocate label dynamicaly
globalScope> Global gs_set_att_const (geosurf *gs, int desc, float constant)
set typbuf constant
globalScope> Global GS_set_Narrow (int *pt, int id, float *pos2)
scale used to calculate len of arrow still needs work needs go function that returns center / eye distance gsd_get_los function is not working correctly ??
globalScope> Global GS_set_wire_color (int id, int colr)
error-handling
globalScope> Global gsd_coarse_surf_map (geosurf *surf)
normals have to be recalculated before proper low res surface can be drawn
globalScope> Global gsd_display_fringe (geosurf *surf, unsigned long clr, float elev, int where[4])
add elevation for bottom add color option add ruler grid lines
File gsd_fonts.c

This file needs to be re-written in OpenGL

This file needs to be re-written in OpenGL

globalScope> Global gsd_line_onsurf (geosurf *gs, float *v1, float *v2)
remove fudge, instead fudge the Z buffer
globalScope> Global gsd_nline_onsurf (geosurf *gs, float *v1, float *v2, float *pt, int n)
remove fudge, instead fudge the Z buffer
globalScope> Global gsd_surf_const (geosurf *surf, float k)
FIX: do_diff won't work right - needs normals - maybe calculate on the fly
File gsdiff.c
generalize this concept to allow transform functions which are dependent on surfaces that are dependent on other surfaces, etc., as long as the dependency doesn't loop back.
globalScope> Global gsds_alloc_typbuff (int id, int *dims, int ndims, int type)
add ATTY_CONST
Global gselect.GdalSelect.OnSetType
improve showing/hiding widgets
globalScope> Global GV_load_vector (int id, const char *filename)
Load file handle & ready for reading instead of using memory
globalScope> Global GVL_get_window ()
gvl_file.c use this - change
globalScope> Global GVL_isosurf_get_drawres (int id, int *xres, int *yres, int *zres)
error handling
Global layertree.LayerTree.OnNvizProperties (self, event)
vector/volume
Namespace lmgr.pyshell
Run pyshell and evaluate code in a separate instance of python & design the widget communicate back and forth with it
Global mapdisp.MapFrameBase.GetPPM (self)

now computed every time, is it necessary?

enable user to specify ppm (and store it in UserSettings)

Global mapwindow.BufferedWindow.DrawCross (self, pdc, coords, size, rotation=0, text=None, textAlign='lr', textOffset=(5, 5)
implement rotation
Global mapwindow.GLWindow.LoadDataLayers (self)
volumes
Global mapwindow.GLWindow.SaveToFile (self, FileName, FileType, width, height)
fix BufferedPaintDC
Global model.Model.LoadModel (self, filename)
Validate against DTD
globalScope> Global N_calc_solute_transport_disptensor_2d (N_solute_transport_data2d *data)
Change the tensor calculation to a mor realistic algorithm
globalScope> Global N_calc_solute_transport_disptensor_3d (N_solute_transport_data3d *data)
Change the tensor calculation to a mor realistic algorithm
globalScope> Global NetA_allpairs (dglGraph_s *graph, dglInt32_t **dist)
Use only O(W*W) memory where W is the number of nodes present in the graph
globalScope> Global print_256lookup (int *buff)
G_debug ?
globalScope> Global print_frto (float(*ft)[4])
G_debug ?
globalScope> Global print_realto (float *rt)
G_debug ?
globalScope> Global print_surf_fields (geosurf *s)
G_debug ?
globalScope> Global print_view_fields (geoview *gv)
G_debug ?
Global prompt.GPromptSTC.OnChar (self, event)
event.ControlDown() for manual autocomplete
Global render.Layer.__init__
pass cmd as tuple instead of list
File snprintf.c
if needed, implement alternative versions for portability. potential code source:
Class statusbar.SbItem
consider externalizing position (see SbProgress use in SbManager)
Global statusbar.SbItem.__init__
rewrite Update also in derived classes to take in account item position
Class statusbar.SbManager

generalize access to UserSettings (specify group, etc.)

add GetMode method using name instead of index

Global statusbar.SbManager.HideStatusbarChoiceItemsByClass (self, itemClasses)
consider adding similar function which would take item names
Global statusbar.SbRegionExtent.ReprojectRegionFromMap (self, region, useDefinedProjection, precision, format)
reorganize this method to remove code useful only for derived class SbCompRegionExtent
File strings.c
merge interesting functions from ../datetime/scan.c here
Global toolbars.BaseToolbar.FixSize (self, width)
Determine why combobox causes problems here
Global utils.GetTempfile
Fix path on MS Windows/MSYS
Global utils.GetValidLayerName (name)
: Better use directly Ctypes to reuse venerable libgis C fns...
Namespace vdigit.wxdigit
Read large amounts of data from Vlib into arrays, which could then be processed using NumPy and rendered using glDrawArrays or glDrawElements, so no per-line/per-vertex processing in Python. Bulk data processing with NumPy is much faster than iterating in Python (and NumPy would be an excellent candidate for acceleration via e.g. OpenCL or CUDA; I'm surprised it hasn't happened already).
globalScope> Global Vedit_add_vertex (struct Map_info *Map, struct ilist *List, struct line_pnts *coord, double thresh)
3D
globalScope> Global Vedit_get_min_distance (struct line_pnts *Points1, struct line_pnts *Points2, int with_z, int *mindistidx)
LL projection
globalScope> Global Vedit_remove_vertex (struct Map_info *Map, struct ilist *List, struct line_pnts *coord, double thresh)
3D
Global wxdigit.IVDigit.OpenBackgroundMap (self, bgmap)
support more background maps then only one
Global wxdigit.IVDigit.SelectLinesByQuery (self, bbox)
layer / 3D
Global wxdisplay.DisplayDriver.UpdateSettings
map units
Global wxnviz.Nviz.SetIsosurfaceMask (self, id, isosurf_id, invert, value)
invert
Global wxnviz.Nviz.SetSurfaceMask (self, id, invert, value)
invert
Global wxnviz.Nviz.SetSurfaceTransp (self, id, map, value)
invert
Global wxnviz.Nviz.SetWireColor (self, id, color_str)
all