Skip to content

Improve -p option to support true perspective projections #8816

@Esteban82

Description

@Esteban82

The -p option currently produces what seems to be an orthographic projection, where all objects appear with the same size regardless of their distance from the viewer. This projection maintains parallel lines and provides no sense of depth.

A true perspective projection would make distant objects appear smaller, with lines converging toward vanishing points — similar to how real cameras or rendering engines represent 3D scenes. You can see this link for some interactive examples.

Implementation:
I would be interested in working on this improvement myself. However, I have not been able to find where in the GMT source the code handling the -p option (projection and 3D transformations) is implemented. Could you please indicate which source file(s) contain this logic?

I believe some of the required functionality might already exist in GMT through the General Perspective projection, so this could potentially be adapted or reused for implementing a true perspective view.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions