[GRASS-dev] Map_info with_z

Hi all,

currently dimension of vector map is stored in three different places (vlib)

Map->plus.spidx_with_z (Plus_head) -> spatial index
Map->plus.with_z (Plus_head) -> topology
Map->head.with_z (Map_info) -> head

Is it really needed?

Martin

--
Martin Landa <landa.martin gmail.com> * http://geo.fsv.cvut.cz/~landa

similar for `mode`

  Map->mode = GV_MODE_READ;
  Map->plus.mode = GV_MODE_READ;

2012/1/21 Martin Landa <landa.martin@gmail.com>:

Hi all,

currently dimension of vector map is stored in three different places (vlib)

Map->plus.spidx_with_z (Plus_head) -> spatial index
Map->plus.with_z (Plus_head) -> topology
Map->head.with_z (Map_info) -> head

Is it really needed?

Martin

--
Martin Landa <landa.martin gmail.com> * http://geo.fsv.cvut.cz/~landa

--
Martin Landa <landa.martin gmail.com> * http://geo.fsv.cvut.cz/~landa

Martin Landa wrote:

Hi all,

currently dimension of vector map is stored in three different places (vlib)

Map->plus.spidx_with_z (Plus_head) -> spatial index

That is coming from GRASS 5 and used as a safety check that the
spatial index has the same dimensions like the coordinates. It can
probably be removed.

Map->plus.with_z (Plus_head) -> topology

Needed by diglib, because diglib functions get only Map->plus, not Map itself.

Map->head.with_z (Map_info) -> head

Needed for reading and writing coordinates and if no topology is
available or requested (e.g. v.info, v.surf.*).

Markus M

Martin:

> Map->plus.spidx_with_z (Plus_head) -> spatial index

Markus Metz:

That is coming from GRASS 5 and used as a safety check that the
spatial index has the same dimensions like the coordinates.
It can probably be removed.

please don't remove safety checks [if they are still meaningful].
they are there for a (very good) reason.

thanks,
Hamish