Not enough memory in shdocvw browser control

This forum deals with any kind of web based client technology, whether it is the well known java script based Ajax servlet or the upcoming approaches such as Leaflet, OpenLayers and so on.

Not enough memory in shdocvw browser control

Postby Lauterfeld » Fri Feb 23, 2018 7:43 am

Hi all,

we use the shdocvw browser activex control in our desktop app to work with xserver 1.x and leaflet.
Also we use the js's of Mr. Heilig from github to interact.
We have the problem that when we work a while in the map (just with some polylines of a route) we'll get the error in the pic1.
Für diesen Vorgang ist nicht genügend Speicher verfügbar

The error occurs in the leaflet-xserver.js at pic2.
Memory consumption of our app is also huge. I'm not sure if it is a cache problem in shdocvw or if it is an issue in leaflet-xserver.js. Our main html makes that at the beginning:
<meta http-equiv="X-UA-Compatible" content="IE=Edge">
<meta http-equiv="cache-control" content="no-cache">

Many thanks for any help,
Volker
Attachments
pic2.jpg
pic1.jpg
Volker Lauterfeld
Software-Entwicklung und Projekte
COS GmbH
Gesellschaft für Computersysteme,
Organisation und Softwareentwicklung mbH
Raiffeisenstraße 21
D-77704 Oberkirch
http://www.cosonline.de/
Lauterfeld
 
Posts: 22
Joined: Tue Apr 14, 2015 1:19 pm

Re: Not enough memory in shdocvw browser control

Postby Oliver Heilig » Fri Feb 23, 2018 9:34 am

Hello Volker,

referring to the sample

https://github.com/oliverheilig/leaflet-vb6

Looks like the single-tile overlay for the labels requires too much memory? What you could try:

Remove the foregroundLayer and check if it works without memory-error at:
https://github.com/oliverheilig/leaflet ... dex.js#L57

If it works, try setting useCanvas: false when initializing the foreground layer:
https://github.com/oliverheilig/leaflet ... dex.js#L54

Generally i'd recommend xMap-2, because it doesn't require single-tile overlays, which is more memory-friendly.

Oli
Oliver Heilig
Chief Developer Logistic Services
PTV GROUP - Germany

https://github.com/oliverheilig/
User avatar
Oliver Heilig
 
Posts: 139
Joined: Tue May 13, 2014 12:10 pm
Location: Karlsruhe, Germany

Re: Not enough memory in shdocvw browser control

Postby Lauterfeld » Tue Feb 27, 2018 2:55 pm

Hi Oliver,

tanks a lot!

I tried out your proposals. They did work but the best memory result is to use xMap2.

But one question is left :-)
How can I manipulate the profile for rendering?
In xMap1 I was able to change some entries in silkysand.ini for example. But how can I do that in xMap2?? I don't find it....

Regards,
Volker
Volker Lauterfeld
Software-Entwicklung und Projekte
COS GmbH
Gesellschaft für Computersysteme,
Organisation und Softwareentwicklung mbH
Raiffeisenstraße 21
D-77704 Oberkirch
http://www.cosonline.de/
Lauterfeld
 
Posts: 22
Joined: Tue Apr 14, 2015 1:19 pm

Re: Not enough memory in shdocvw browser control

Postby Joost » Tue Feb 27, 2018 3:00 pm

Are you using the REST API? in that case you can add the parameter storedProfile=<value> to the URL.

A working example can be found at https://xserver2-europe-eu-test.cloud.p ... index.html
Joost Claessen
Senior Technical Consultant
PTV Benelux
Joost
 
Posts: 262
Joined: Fri Apr 25, 2014 1:46 pm

Re: Not enough memory in shdocvw browser control

Postby Lauterfeld » Tue Feb 27, 2018 3:05 pm

Hi Joost,

yes I do so. Example:
xMap2Layer1 = new L.tileLayer("http://" + location.hostname + ":50000/services/rest/XMap/tile/{z}/{x}/{y}?size={tileSize}&storedProfile={profile}&layers={layers}", {
profile: 'silkysand',
layers: 'background,transport,labels',
subdomains: '1234',
minZoom: 0,
maxZoom: 22,
pane: 'tilePane',
tileSize: 256,
format: 'image/png',
opacity: 1,
unloadInvisibleTiles: true,
attribution: "&copy; PTV-AG"
});

But how I can manipulate the silkysand-Profile? in xMap1 I edited the silkysand.ini serverside and for example I change colors of streets or made heights transparent,.... Is that still possible in xMap2?
Volker Lauterfeld
Software-Entwicklung und Projekte
COS GmbH
Gesellschaft für Computersysteme,
Organisation und Softwareentwicklung mbH
Raiffeisenstraße 21
D-77704 Oberkirch
http://www.cosonline.de/
Lauterfeld
 
Posts: 22
Joined: Tue Apr 14, 2015 1:19 pm

Re: Not enough memory in shdocvw browser control

Postby Joost » Tue Feb 27, 2018 3:42 pm

This is not possible, the profiles are hard coded for now. Customer specific rendering profiles in on the wishlist for future development of xMap2, but nothing scheduled atm.
Joost Claessen
Senior Technical Consultant
PTV Benelux
Joost
 
Posts: 262
Joined: Fri Apr 25, 2014 1:46 pm

Re: Not enough memory in shdocvw browser control

Postby Lauterfeld » Tue Feb 27, 2018 3:45 pm

OK, thanks!
Volker Lauterfeld
Software-Entwicklung und Projekte
COS GmbH
Gesellschaft für Computersysteme,
Organisation und Softwareentwicklung mbH
Raiffeisenstraße 21
D-77704 Oberkirch
http://www.cosonline.de/
Lauterfeld
 
Posts: 22
Joined: Tue Apr 14, 2015 1:19 pm


Return to PTV Webclients (Ajax, Leaflet, OpenLayers, WMS, ...) (Admin=LNM)

cron