How to I get location when click bingmap in Windows 8.1 Store App? - xaml

I have to a Windows 8.1 store project and I must use bingmap or other maps for this project( I tried Bing Map). When I click on the map I want to take location(Latidude , Longtitude) of the this point.
How can I do?

To get the coordinate of where the user clicked you will need to first add a click event to the map. In the event handler you will be able to get the pixel coordinates of the click event. You can pass these through the maps TryPixelToLocation method which will convert the pixel coordinates into a map coordinate. You can find a full code sample here: https://code.msdn.microsoft.com/Bing-Maps-C-Pixel-to-3eb9fff0#content

Related

Gray out entire map except a portion in Google maps iOS

I am using Google maps in iOS using iOS SDK, letting users mark an area using few markers, creating a polygon.
I want to highlight that area and gray out the rest of the map, something like this:
Is this possible somehow?
You have to draw your own UIImage where you create the gray area, clear area, and polygon borders. After that add it as an overlay tile using GMSGroundOverlay. This will fix it in place for when the user scrolls.
https://developers.google.com/maps/documentation/ios/overlays
This is similar to how radar overlays are drawn for weather apps.
I would approach this problem using several steps.
1) collect your points from the user that will define your polygon.
2) send the collection of points to your server.(ajax post)
3) server side, dynamically create a grey image with a transparent hole in it that is your polygon.
4) store image on server, send back response with info telling browser how to retrieve it(url,id,whatever).
5) using javascript + google maps api, apply an overlay referencing your newly created image.
each step may have its challenges but the problem becomes manageable if you focus on the different steps.
1) and 2) will involve using javascript, capturing 'clicks' and having feedback to the user in the form of a line or something on the map. Once finished, the server call can be initiated by the user or by your programming.
3) I would use python with an image library(skimage, etc.) and a mapping library (gdal). Making an image is not hard but combining it with GIS and getting the right projection, etc. will take some fiddling.
4) shouldn't be a problem once you've got that far.
5) using zimmryan's comment about creating a ground overlay could be helpful for this step.
good luck!

Taking Control of ARCamera on Unity3D with Vuforia

The position and rotation of Vuforia's ARcam are determined by their algorithms to give the AR effect. I'd like to know how to do the following:
When some object is clicked the camera goes to some specific position (for that I need to somehow take control of the camera).
Also have to possibility to yield control of the camera back to Vuforia.
You'll want to use a second camera in this instance. Position the second camera at the AR Camera position, then adjust the depths to make the new camera the view that you see. Then you can tween its position to the predefined one you have.
Do the reverse to get control back to the AR Camera.

Can I cache Apple Maps?

So here is the scenario,
I am working on this piece where direction tab holding the map and there is a pin on address and callout bubble is automatically been shown as view appears. if you click button get driving directions it take user to apple maps for direction.
As this map is static I was thinking instead of download every time on when view appears, Is it possible to Cache the map, let say 1 sq Kilomerters or the area which is shown in the view.
Apple caches the map for you.
If the user will not load other map data, it will be in the cache.
You cannot force your part of the map to stay in the cache.
Edit:
I tried it with disabling wlan, so the device cannot load the map data anymore from net. It looks like it is loading, but this is more a building up ob the map data.
it shows the map data previously loaded, but cannot load new one.
No, there is no way to control the caching in MapKit. Check out the Mapbox iOS SDK or MBXMapKit.

Drawing on Petrel map window

I'm working on a plug in for petrel in I require drawing lines, polygons on a petrel map window, can it be possible using mouse events?
Yes, you can create a process that takes mouse button clicks in a map window and creates lines or polygons from the input picks provided (MapPickedPoint). The process could create a new polyline object in a folder in the Petrel input tree that would be updated with each pick, or you can create your own custom domain object that is updated with each point pick. If you create a custom domain object you will need to also provide the method to draw the object in the map window.

Gmaps4rails make marker draggable and get its coordinates

Is it possible to make a marker draggable and to get its coordinates in gmaps4rails, that the user could drag marker to choose the point he wants and get his chosen point coordinates?
It's not implemented in the gem.
But don't forget that you have access to all objects created. Example, the map could be retrieved with: Gmaps4Rails.map
You could take inspiration from: https://github.com/apneadiving/Google-Maps-for-Rails/wiki/Javascript-goodies