boostorg / boostorg/geometry

Writing 3D WKT: Z in prefix?

Open
#664 12 comments 0 reactions 0 assignees View on GitHub
enhancement good-first-issue
Dominant language
C++
Stars
517
Forks
232
PR merge metrics
No merged PRs in 30d

Description

When writing 3D objects in WKT, a "Z" is supposed to be added to the prefix, such that a 2D point and a 3D point are differentiated:
```
POINT (1,2)
POINT Z (1,2,3)
```
But as far as I tested, when writing 3D objects using the WKT writer of Boost Geometry, the "Z" prefix is never written, leading to this kind of output:

```
POINT (1,2)
POINT (1,2,3)
```
It seems to be similar for other types of primitives (`LINESTRING`, etc.).

Reading 3D objects with Boost both works with and without "Z" in the input.

Wouldn't it make more sense to add "Z" to the prefix whenever a 3D object is written?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.