Hexagon Geospatial
MENU

Developer Discussions

Discuss topics with other Hexagon Geospatial Power Portfolio developers and experts to get the most out of our products.
Showing results for 
Search instead for 
Do you mean 
Reply
Super Contributor
Posts: 301
Registered: ‎02-09-2016

Geospatial portal displays differently scaled data

Hi all,

 

Our client is using geospatial 2016. We implement a custom javascript function that take feature name, instance id provided from the site url, call a web service to get the bounding box of the instance, then zoom into the area and set input instance into the selection cache. On our client environment, they intermittently experience that some of features such as roads which are displayed in high scales (overall scales 30000) somehow still show in the background when we already zoom into the detail area (low scale 4000). The client is using IE11.

 

We appriciate if someone can give us some suggestions on how to solve this issue

 

Kind regards 

Staff
Posts: 294
Registered: ‎11-05-2015

Re: Geospatial portal displays differently scaled data

If this is not actually a dumb bug, you might be experiencing one of two problems. Or both.
1. There was a rounding discrepancy error between the MapSvr and the Geospatial Portal which made the Portal say that you are viewing the map at 3000 and the MapSvr was still thinking it was 2999.999968. This will be fixed in 15.0.6 and 16.0.1 I believe. A hotfix has been shared with the support.
2. Portal aligns its scale ranges to the OSM tile levels and possibly other tiled services. This is by design and should be reflected in the scale denominator tool in Portal.

The third (bug) possibility is that Portal uses overlapping layers to achieve smooth zooming experience. We are already aware of some problems with this approach but it only emerged as double requests sometimes.
Are you using Portal's scale bands functionality or are you talking about having scale range display configured in the legend of the service source?
Super Contributor
Posts: 301
Registered: ‎02-09-2016

Re: Geospatial portal displays differently scaled data

Hi hbm, 

 

Thank you for looking at this issue. All the map features are comming from a WMPS instance, so the scale is set in GeoMedia.

 

Here is the detail of what my script does (in order)

 

  1. When the document is ready, start parsing parameters and values from the url
  2. Listen to events such as 'mapInitialized', 'mapRendering' and 'mapRendered' to make sure the portal components such as 'legend loading' and map are ready. (In the past, we experienced that if we jumped into the instance's area too soon, it could cause the legend control to be malfunctional, not all legend items can be initialized successfully). 
  3. Call an external web service to get the bounding box.
  4. Add the selected feature instance into the selection cache.
  5. Create an analysis layer of this feature on the fly (fileter by id value) and add to the top.
  6. Zoom into the instance's area. 

Image of the overall map (Road and road center lines are displaying)

 

Overall scaled map

 

Image of an Parcel instance's area

 

 

The problem only happens on client's environment with their IE 9 and 11 (not Chrome), we also test it on our environment with IE11, but haven't observed the issue.

We also notice that their server machine is a little slow and their maps have a lot of features, so it could contribute to the issue.

 

From the order of actions above, I delibrately call "add feature instance into the selection cache" before zooming in, because if I do another way around (zoom in first and then add instance to selection cache), I occasionally observe that the feature instance does not have selection style (filled with green color). I think step 5, creating an analysis on the fly before zoomming in likely triggers the issue, interferes with map engine when it cleans the high scaled features road and road centre lines.

 

Appreciate all insights and suggestions 

 

Kind regards

 

 

 

Staff
Posts: 294
Registered: ‎11-05-2015

Re: Geospatial portal displays differently scaled data

Are those SVG format maps? In IE11 on Win7 there is a known issue with this display format that we tried to overcome by removing the SVG from the page when needed in a very contrived way. This might backfire on you. Is there any indication of an error in the Javascript console output?
Super Contributor
Posts: 301
Registered: ‎02-09-2016

Re: Geospatial portal displays differently scaled data

[ Edited ]

Hi hbm, 

 

Road and road centre lines are svgz format. Their scale range defined in Gemedia are (50,000-500,001) and (30,000-500,001) respectively. But from the image, we can see that somehow they appear in the parcel scale (< 5000).

 

The feature that needs to be highlighted Land Parcel is also in svgz format with scale range (1-5001)

 

Kind regards,

Staff
Posts: 294
Registered: ‎11-05-2015

Re: Geospatial portal displays differently scaled data

My hunch is that their environment is IE 11 on Windows 7 or Windows Server 2008. Would that be correct? If so, then it looks like a bug in a workaround we made for some other deficiencies of this platform. Notice that the offending layer is grayed out like it should. Does the same happen if you zoom into the same area with portal's usual controls instead of programmatically?
Super Contributor
Posts: 301
Registered: ‎02-09-2016

Re: Geospatial portal displays differently scaled data

HI hbm,

 

We try a work around which is calling $GP.map.refresh() at the end our function and it seems to overcome the displaying issue. The testing on the client enviornment looks positive at the moment. Hopefully there is no more work around.

 

Kind regards, 

Highlighted
Super Contributor
Posts: 301
Registered: ‎02-09-2016

Re: Geospatial portal displays differently scaled data

[ Edited ]

Hi all,

 

We fix the displaying scaled data by calling map refresh at the end. However, our custom does not function correctly on IE11 with window 7. The code that adds the input instance to the selection cache throws exception and that exception happens in the function _onSelectedFeaturesChanged in the dll Intergraph.WebSolutions.Core.WebClient.Controls.Map.MapControl.

 

2016-09-28 11_46_29-Liz Leighfield's Screen.png

 

In this highlighted function, the is a typo, in the setTimeout function _selectSetTimeoutId is supposed to be used but they instead use the variable _selectSetTimeout which is undefined (not declared). This causes exception in IE 11, we fix that by initializing the variable _selectSetTimeout in the mapConfig.js file for the javascript object 

Intergraph.WebSolutions.Core.WebClient.Controls.Map.MapControl, but somehow IE11 still does complaints about this function.

 

Appreciate all suggestions and work-around on the issue.

Our clients mainly use IE 9 and 11 and portal peforms so far quite inconsistently especially about svgz layers; if we have a png layer on the top, then the svgz layer next to it becomes unselectable (it does not behave like that on Chrome), and SDK functions is not really reliable, so we also appreciate if anyone can share their experience, work-around on these IE problems.

 

Kind regards,

 

 

 

 

 

Staff
Posts: 294
Registered: ‎11-05-2015

Re: Geospatial portal displays differently scaled data

Be advised that IE11 on Windows 7 is not supported by Microsoft anymore (at least fun tonal bugs, I've stopped tracking whether they still make security fixes). There is a seemingly stochastic issue with portal's SVG handling on this platform which will be observed as a total browser freeze after a map view change. We suspect an internal timing issue between Microsoft's HTML and SVG renderers. We've spent a month trying to come up with a solution workaround with Microsoft's dev support and applied a workaround. There have been reports of it not being entirely foolproof.
As for the SVG behaving inconsistently, that's the thing with browsers, I think. Some bubble events up and some down. The practice we encourage is to have as little vector data as possible and preferably only as the top most layer.
Super Contributor
Posts: 301
Registered: ‎02-09-2016

Re: Geospatial portal displays differently scaled data

Hi hbm,

 

Thank you for the advices. Our client is a local council, IE11 and Window 7 are their main software, IE is used to talk to other software (due to ActiveX controls), so they are likely not going away soon. Just hope that when the problems occurr, we can somehow fix or work around them. 

 

Kind regards,

 

Do you need immediate support?
Please submit a Ticket through our
Development Ticket Portal.