Return to Issues Table 

verifyLinkReferent cannot handle parameterized URL for PhotoOverlay

Issue ID#:
942
Category:
KML 2.2
Type:
Issue
Status:
Closed (No Change Required)
Priority:
Normal
Entered By:
Martell, Richard
Created On:
2014-03-24 16:27:22
Updated By:
Bermudez, Luis
Last Update:
2014-07-24 09:04:30
Assigned To:
Martell, Richard

Original Issue Details:

If a PhotoOverlay element contains an ImagePyramid for tiling a large image, the kml:Icon/kml:href element will contain a URL with tile parameters.


Example:


 <PhotoOverlay id="test.10">
<Camera>
<longitude>2.2946</longitude>
<latitude>48.8583</latitude>
<altitude>20</altitude>
<heading>0</heading>
<tilt>90</tilt>
<roll>0</roll>
<altitudeMode>relativeToGround</altitudeMode>
</Camera>
<Icon>
<href>http://tile.openstreetmap.org/$[level]/$[x]/$[y].png</href>;
</Icon>
<ViewVolume>
<leftFov>-60</leftFov>
<rightFov>60</rightFov>
<bottomFov>-60</bottomFov>
<topFov>60</topFov>
<near>100</near>
</ViewVolume>
<ImagePyramid>
<tileSize>256</tileSize>
<maxWidth>512</maxWidth>
<maxHeight>512</maxHeight>
<gridOrigin>upperLeft</gridOrigin>
</ImagePyramid>
<Point>
<coordinates>2.2945,48.85825,0</coordinates>
</Point>
</PhotoOverlay>

In the verifyLinkReferent test no values are substituted so the URL is invalid and cannot be dereferenced.


Status: new
Assigned To: Martell, Richard



The KML spec (cl. 11.4.3)  is not very clear about the syntax for the tile parameter references, although one can assume that the "example" URL (which is inconsistent) shows the standard syntax: $[paramName].


A simple fix is to just substitute 0 (zero) for all values; this should refer to the lowest resolution image (e.g. http://tile.openstreetmap.org/0/0/0.png).

Hours Worked: 0.00
Entered By: Martell, Richard - 2014-10-23 11:54:13
Status: Fixed - Requires Review
Assigned To: Martell, Richard

Fixed (r9). In LinkTests.checkOverlayIconReferent(), substitute 0 (zero) for all tile parameter references in kml:Icon/kml:href.

Hours Worked: 0.00
Entered By: Martell, Richard - 2014-03-25 11:23:56
Status: Fixed - Requires Review
Assigned To: Martell, Richard



Added unit test (verifyParameterizedLinkInPhotoOverlay) and refactored LinkTests so that image tile params are substituted in the getLinkHref() method.

Hours Worked: 0.00
Entered By: Martell, Richard - 2014-04-07 11:58:38
Status: Closed (No Change Required)
Assigned To: Martell, Richard

Hours Worked: 0.00
Entered By: Bermudez, Luis - 2014-07-24 09:04:30