Modify

Opened 14 years ago

Closed 14 years ago

Last modified 14 years ago

#6834 closed enhancement (fixed)

[Patch] Imagery providers slippy map enhancements

Reported by: Don-vip Owned by: team
Priority: normal Milestone:
Component: Core Version: latest
Keywords: Cc:

Description (last modified by Don-vip)

Hi,
Please find attached a proposed patch (V2) to enhance further the one I submitted in #6825.
This patch allows to:

  • display several bounds for a single provider (useful for imagery providers that have distinct, non-adjacent, bounds)
  • display polygon shapes (it's going to be very useful for the French "GéoLittoral" bounds that cover the entire Atlantic coasts, rather than draw a simple rectangle across all the country)

Here's what it looks like:

The Maps wiki page has to be improved as described in the attached XML file (V2), but this change should be backward-compatible with older JOSM version.

Attachments (6)

josm_imagery_enhanced.png (102.2 KB ) - added by Don-vip 14 years ago.
Maps-CRAIG-Auvergne.xml (2.3 KB ) - added by Don-vip 14 years ago.
patch.diff (39.5 KB ) - added by Don-vip 14 years ago.
patchV2.diff (39.3 KB ) - added by Don-vip 14 years ago.
Maps-CRAIG-Auvergne-V2.xml (2.5 KB ) - added by Don-vip 14 years ago.
patchMinSize.diff (798 bytes ) - added by Don-vip 14 years ago.

Download all attachments as: .zip

Change History (20)

by Don-vip, 14 years ago

Attachment: josm_imagery_enhanced.png added

by Don-vip, 14 years ago

Attachment: Maps-CRAIG-Auvergne.xml added

by Don-vip, 14 years ago

Attachment: patch.diff added

comment:1 by Don-vip, 14 years ago

Description: modified (diff)

comment:2 by Don-vip, 14 years ago

Description: modified (diff)

comment:3 by stoecker, 14 years ago

Did you handle the case, that bounds contains a low resolution all-over-bounds and shape a more detailed one? In this case only the shapes should be displayed.

comment:4 by bastiK, 14 years ago

What about this format:

    <imagery>
        <entry>
            <name>CRAIG - Auvergne 30 cm</name>
            <type>wms</type>
            <url><![CDATA[http://wms.craig.fr/osm?service=wms&request=getmap&version=1.1.1&layers=auvergne&format=image/jpeg&]]></url>
            <bounds min-lat='44.604' min-lon='2.045' max-lat='46.822' max-lon='4.507'>
                <shape>
                    <point lat='45.4023663' lon='2.4599585' />
                    <point lat='45.4286348' lon='2.3254017' />
                    <point lat='44.9943663' lon='2.0451281' />
                    <point lat='44.6038115' lon='2.1840500' />
                    <point lat='44.6327309' lon='2.5051357' />
                </shape>
                <shape>
                    <point lat='46.3179797' lon='4.0296102' />
                    <point lat='46.4658971' lon='4.0317945' />
                    <point lat='46.5490366' lon='3.7600585' />
                    <point lat='46.7794611' lon='3.6255192' />
                </shape>
            </bounds>
            <attribution-text mandatory='true'>Orthophotographie CRAIG/TopoGEODIS 2009-2010</attribution-text>
            <attribution-url>http://wiki.openstreetmap.org/wiki/WikiProject_France/CRAIG</attribution-url>
            <country-code>FR</country-code>
        </entry>
    </imagery>

After all the shape describes the bounds and you could specify multiple polygons if that is needed.

comment:5 by Don-vip, 14 years ago

I like it. I will change the format to multiple <shape> inside a single <bounds> tag.
The bounds rectangle will only be displayed if it doesn't contain shapes.

by Don-vip, 14 years ago

Attachment: patchV2.diff added

by Don-vip, 14 years ago

Attachment: Maps-CRAIG-Auvergne-V2.xml added

comment:6 by Don-vip, 14 years ago

Description: modified (diff)

comment:7 by Don-vip, 14 years ago

Okay, V2 should do the trick.

comment:8 by bastiK, 14 years ago

Resolution: fixed
Status: newclosed

In [4423/josm]:

applied #6834 - Imagery providers slippy map enhancements: polygon support (patch by Don-vip, modified)

comment:9 by bastiK, 14 years ago

In [o26652].

comment:10 by bastiK, 14 years ago

The component layout is still a little erratic. Especially for the default size of the preferences dialog, the table next to the map is somewhat squeezed.

comment:11 by stoecker, 14 years ago

@Don-Vip:

The format description at Maps must be updated to reflect changes.

comment:12 by Don-vip, 14 years ago

Done :)

by Don-vip, 14 years ago

Attachment: patchMinSize.diff added

comment:13 by Don-vip, 14 years ago

@bastiK:

You're right. See patchMinSize.diff to fix that :)

comment:14 by bastiK, 14 years ago

In [4425/josm]:

applied #6834 - component layout (patch by Don-vip)

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain team.
as The resolution will be set.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.