Skip to content

Off-by-one in Robinson projection? #1172

@QuLogic

Description

@QuLogic

In Robinson, i is limited by:
https://github.com/OSGeo/proj.4/blob/330e8bf686f9c4524075ca1ff50cbca6c9e091da/src/PJ_robin.c#L87-L91
to 0 <= i <= NODES - 1 and i + 1 is never used in s_forward. Here, NODES is set to 18, but there are 19 entries in X and Y. In s_inverse, i + 1 is used.

So, is the last entry in the X and Y tables supposed to be applied in s_forward (and accidentally not), or is it only there for s_inverse? If this is intentional, I guess a comment would be helpful to make this clear. Of am I just misreading something here?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions