vectorlib_ogr.dox 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. /*! \page vlibOgr OGR interface
  2. by GRASS Development Team (http://grass.osgeo.org)
  3. \par Table of contents
  4. - \ref vlibOgrIface
  5. - \ref vlibFrmtFileFormat
  6. - \ref vlibFidxFileFormat
  7. \section vlibOgrIface OGR interface
  8. \subsection vLibPseudoTopo Pseudo-topology
  9. Reduced topology: each boundary is attached to one area only,
  10. i.e. smoothing, simplification, removing small areas etc. will not
  11. work properly for adjacent areas or areas within areas.
  12. Full topology is only available for native GRASS vectors or can only
  13. be built after all polygons are converted to areas and cleaned as done
  14. by <tt>v.in.ogr</tt>.
  15. \subsection vlibFrmtFileFormat Frmt file format specification
  16. Frmt is a plain text file which contains basic information about
  17. external format of linked vector map. Each line contains key, value
  18. pairs separated by comma.
  19. OGR specific format is described by:
  20. - FORMAT - ogr
  21. - DSN - OGR datasource name
  22. - LAYER - OGR layer name
  23. Example:
  24. \verbatim
  25. FORMAT: ogr
  26. DSN: /path/to/shapefiles
  27. LAYER: cities
  28. \endverbatim
  29. OGR layer can be linked via <tt>v.external</tt> command. When linking
  30. OGR layer pseudo-topology ('topo') is built including spatial index
  31. file ('sidx') and category index file ('cidx'). Additionally also
  32. feature index file (see \ref vlibFidxFileFormat) is created.
  33. \subsection vlibFidxFileFormat Fidx file format specification
  34. Note: <tt>finfo</tt> is an instance of \ref Format_info structure.
  35. <table border="1" style="border-collapse: collapse" cellpadding="5">
  36. <tr><td><b>Name</b></td><td><b>Type</b></td><td><b>Number</b></td><td><b>Description</b></td></tr>
  37. <tr><td>Version_Major </td><td>C</td><td>1</td><td>file version (major)</td></tr>
  38. <tr><td>Version_Minor </td><td>C</td><td>1</td><td>file version (minor)</td></tr>
  39. <tr><td>Back_Major</td><td>C</td><td>1</td><td>supported from GRASS version (major)</td></tr>
  40. <tr><td>Back_Minor</td><td>C</td><td>1</td><td>supported from GRASS version (minor)</td></tr>
  41. <tr><td>byte_order</td><td>C</td><td>1</td><td>little or big endian
  42. flag; files are written in machine native order but
  43. files in both little and big endian order may be
  44. readl; zero for little endian</td></tr>
  45. <tr><td>length</td><td>L</td><td>1</td><td>header size</td></tr>
  46. <tr><td>fInfo.ogr.offset_num</td><td>I</td><td>1</td><td>number of records</td></tr>
  47. <tr><td>fInfo.ogr.offset</td><td>I</td><td>offset_num</td><td>offsets</td></tr>
  48. </table>
  49. */