next up previous contents index
Next: Advanced Data Types for Up: Basic Data Types for Previous: Generalized polygons with circular   Contents   Index

Parser for well known binary format ( wkb_io )


The class wkb_io provides methods for reading and writing geometries in the well known binary format (wkb). Every non-trivial generalized polygon from LEDA can be written in wkb format. The method for reading supports the wkb types Polygon and MultiPolygon, i.e., those types that can be represented by the LEDA type gen_polygon.

#include < LEDA/geo/wkb_io.h >


wkb_io W creates an instance of type wkb_io.


bool string& filename, gen_polygon& P)
    reads the geometry stored in the given file and converts it to a generalized polygon P.

bool W.write(const string& filename, const gen_polygon& P)
    writes the generalized polygon P to the given file.