I have not checked closely but Geo::Point seems to be for geographic coordinates, so latitude and longitude and not projected coordinates such as UTM. (Edit: actually it does but it uses proj4 which is long deprecated). It also seems not to handle Z and M coordinates, and neither does the parent Geo::Shape class.

For a single part polygon or polyline one just needs an array of coordinates (vertices), so an array of arrays would do. Maybe each vertex could be blessed into an array based object if that makes other things easier.

Multipart features are collections of polygons, polylines and points (one type per feature) so would be a different object class.

Then there are geometry collections which can be a mix of feature types. e.g. http://postgis.net/workshops/postgis-intro/geometries.html


In reply to Re: WKB Reader (was: Re^2: Solved! (was: Re^10: Geo Package files)) by swl
in thread Geo Package files by Bod

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.