Hi,
I have a map in my application using display of TMS layers, which is only available in the openlayers implementation, but I also need to display custom images in my map, which can only be done in the google maps implementation.
I've seen there is the possibility of 'dynamic switching' of the service when using the TMSFNCMaps object. But I cannot 'cast' or transform the map to a different implementation at runtime, can I?
What would you recommend how to handle this most sufficiently?
Ideas:
Have two instances of the maps objects and only display one?
Create at runtime and throw away the one I am not using and recreate, when in need again?
to be more specific: I do not need to use both features (tms overlays / image overlays) at the same time, hence the idea of switching between both 'modes'.
You will need to create both and then dynamically switch between the two by toggling the Visible property. Alternatively, in the latest TMS FNC Maps implementation we introduced Labels, which can be used in the abstract TTMSFNCMaps class.
Thanks for the quick reply!
re: creating both - would I have to except performance impacts by the double amount of edge threads created etc? That would be my concern.
Can you elaborate a bit more on the labels? How would I make use of them? Or where can I look up how to use them?
re: labels - Ah, I understand.Unfortunately I need to scale the overlay (i.e. a contained image displaying a plan of a construction site of similar) to bounds, so I would need to have the element container be depending on not only a coordinate, but bounds, just as the overlay feature in Google maps works. That is not supported I assume?
I have passed this through to the responsive developer, he will assess this feature and see what is feasible. No time-frame yet, but next week we are planning an update of the whole FNC family and will see if this makes it in the release. If not, then most likely this will be for the next iteration which happens at least once or twice every month.
Support for bounds positioning has been added to the Labels feature of the TTMSFNCMaps component. The update is scheduled for release later this week.
This new option is independent of the mapping service so it works and looks the same for all mapping services.
This is an example of how you will be able to display an image in a label positioned inside predefined bounds:
Great!
One question about usage: Since I have to work with an TMSFNCOpenLayers instance, beause I need the TMS layers feature: Will I be able to call the addLabel(...) also on the TMSFNCOpenLayers object?