d.vect.html 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127
  1. <h2>DESCRIPTION</h2>
  2. <em>d.vect</em> displays vector maps in the active frame on the
  3. graphics monitor.
  4. <h2>NOTES</h2>
  5. <em>d.vect</em> can simply be used typing <tt>d.vect
  6. map=vector_map</tt>. There are a large variety of optional parameters
  7. which allow the user to specify vector type, colors, data fields, SQL
  8. queries, label size and justification, etc.
  9. <p>By default <em>d.vect</em> areas are filled with <b>fill_color</b> and
  10. outlined with <b>color</b>. Area outlines can be suppressed with
  11. <div class="code"><pre>
  12. d.vect map=vector_map color=none
  13. </pre></div>
  14. and areas can be made transparent with
  15. <div class="code"><pre>
  16. d.vect map=vector_map fill_color=none
  17. </pre></div>
  18. <p>In order to display attributes in the map, <b>attribute_column</b> must
  19. be specified.
  20. <p>Feature colors may be specified
  21. by <em><a href="v.colors.html">v.colors</a></em> in a form of color
  22. table or in an attribute table column containing <tt>RRR:GGG:BBB</tt>
  23. values.
  24. <p>A table for a vector map might look like this:
  25. <div class="code"><pre>
  26. db.select sql="select * from testisola"
  27. cat|label|GRASSRGB
  28. 0|no data|255:255:255
  29. 90|FRASSILONGO|23:245:67
  30. 104|LEVICO|23:145:67
  31. 139|PERGINE VALSUGANA|223:45:237
  32. 168|SANT'ORSOLA|223:45:67
  33. 190|TENNA|123:45:67
  34. </pre></div>
  35. <p>To add the GRASSRGB color column, use <em><a href="v.db.addcolumn.html">v.db.addcolumn</a></em>:
  36. <div class="code"><pre>
  37. v.db.addcolumn map=testisola columns="GRASSRGB varchar(11)"
  38. </pre></div>
  39. <p>To add/change a color, use <em><a href="v.db.update.html">v.db.update</a></em>:
  40. <div class="code"><pre>
  41. v.db.update map=testisola column=GRASSRGB value="123:45:237" where="cat=139"
  42. </pre></div>
  43. <p>A much simpler method of color coding is by using the <b>-c</b> flag
  44. which displays vector elements of like category number with a random
  45. color.
  46. <p>This module can use FreeType/TrueType fonts if they have already been selected with
  47. <em><a href="d.font.html">d.font</a></em>.
  48. <p>Parameter <b>width</b> is set by default to '0'. XDRIVER specifies the
  49. precise behaviour for non-zero line width, but drivers have some
  50. freedom as to how zero-width lines are handled, so they can use the
  51. hardware's &quot;thin line&quot; drawing primitive, if it has one. A
  52. width of zero can potentially result in significantly faster operation. On
  53. drivers where there is no such thing as a "thin" line, the driver will
  54. use a sensible default (which might not be the same as '1').
  55. <h2>EXAMPLES</h2>
  56. Spearfish examples:
  57. <div class="code"><pre>
  58. # display roads with category numbers:
  59. d.vect map=roads display=shape,cat label_color=green
  60. # display randomly colorized soils map with attributes
  61. d.vect -c map=soils attribute_column=label
  62. # display randomly colorized selected vectors from soils map
  63. d.vect -c map=soils where="label='VBF'" display=shape attribute_column=label
  64. </pre></div>
  65. <p>3D points, 3D lines and 3D polygons colorized according to z height:
  66. <div class="code"><pre>
  67. g.region raster=elevation.10m
  68. r.random input=elevation.10m n=5000 vector=random3d -d
  69. d.mon start=x0
  70. # display as black points
  71. d.vect map=random3d
  72. # display 3D points colorized according to z height
  73. d.vect map=random3d zcolor=gyr
  74. # 3D contour lines
  75. r.contour input=elevation.10m output=contour20m step=20
  76. d.vect map=contour20m zcolor=gyr
  77. # generate 3D triangles
  78. v.delaunay input=random3d output=random3d_del
  79. # display 3D polygons colorized according to z height
  80. d.vect map=random3d_del type=area zcolor=gyr
  81. </pre></div>
  82. <h2>SEE ALSO</h2>
  83. <em>
  84. <a href="v.colors.html">v.colors</a>,
  85. <a href="d.erase.html">d.erase</a>,
  86. <a href="d.rast.html">d.rast</a>,
  87. <a href="v.colors.html">v.colors</a>,
  88. <a href="v.db.addcolumn.html">v.db.addcolumn</a>,
  89. <a href="v.db.update.html">v.db.update</a>
  90. </em>
  91. <p>
  92. <em>
  93. <a href="sql.html">GRASS SQL interface</a>
  94. </em>
  95. <h2>AUTHORS</h2>
  96. CERL<br>
  97. Radim Blazek, ITC-Irst, Trento, Italy<br>
  98. Support for color tables by Martin Landa, Czech Technical University in Prague (8/2011)<br>
  99. and many other GRASS developers
  100. <p><i>Last changed: $Date$</i>