Show directions on Kakao maps, start/destination encoded in url - directions

I have manged to encode destination: https://map.kakao.com/link/to/37.402056,127.108212
But I have not succeeded to also add start location for directions on Kakao maps? I need both start and destination encoded in url so that directions are drown on page after click on url.

Like this?
we can get it after select a location.
https://map.kakao.com/
?sX=500000 <-- startX[ Wcongnamul coordinates.]
&sY=1084098 <-- startY[ Wcongnamul coordinates.]
&sName=startName <-- depend on you
&eX=523953 <-- startX[ Wcongnamul coordinates.]
&eY=1084098 <-- startY[ Wcongnamul coordinates.]
&eName=destinationName <-- depend on you
Full URL
https://map.kakao.com/?sX=500000&sY=1084098&sName=startName&eX=523953&eY=1084098&eName=destinationName
X and Y it mean... Wcongnamul coordinates.
Can be get it easily by Kakao Map API
How to get LatLng by Coords
ToLatLng()
Returns the coordinates of the object in WGS84 coordinates.
How to get Coord by LatLng
ToCoords()
Returns the coordinates of the object in Wcongnamul coordinates.

Unfortunely because this
Get directions(web)
You can use the coordinates or place ID to create a directions URL that specifies that location as your destination.
URL Pattern Example
/ link / to / name, latitude, longitude
https://map.kakao.com/link/to/KakaoPangyo+Office,37.402056,127.108212
/ link / to / place ID
https://map.kakao.com/link/to/18577297
But i found it can do in Android/iOS with this
Get Directions (Android/iOs)
Android
daummaps://route?sp=37.537229,127.005515&ep=37.4979502,127.0276368&by=CAR
iOS
kakaomap://route?sp=37.537229,127.005515&ep=37.4979502,127.0276368&by=CAR

Related

Can't match coordinates of NWD and POTREE on Forge Viewer

I'm testing the example https://github.com/petrbroz/forge-potree-demo trying to import a NWD and point cloud into the Forge Viewer but can't make them match the coordinates.
I confirmed on Navisworks that both PC and model are aligned at 0,0,0. But they are displaced more than 200' in the Viewer.
What we did tried
Point cloud was converter using Potree converted 1.6 and 1.7 https://github.com/potree/PotreeConverter/releases/tag/1.7
The point cloud is scaled from meters to feet using let scale = new THREE.Vector3(3.28084,3.28084,3.28084);.
The models are being inserted with a global offset of 0,0,0. globalOffset: {x:0,y:0,z:0}
We created a sphere at a know point directly in Threejs using coordinates in foots and it matches the location on the NWD.
We found that potree converter is not 100% compatible with the sample, a quick fix is needed on the line 464 to read categories created by the converter.
var pointAttributeName = pointAttributes[i].name.toUpperCase().replaceAll(' ','_');
Also we needed to add a new category around line 434
PointAttribute.RGBA = new PointAttribute(PointAttributeNames.COLOR_PACKED, PointAttributeTypes.DATA_TYPE_INT8, 4);
Without those two latest fixes we can't load the point cloud.
What are we missing?
We can override the location by hand but the final coordinates doesn't make sense with the project. Too arbitrary. Could the two fixes be the problem? What should be an alternative?
We found the problem, potree was using a bounding box based on absolute units from the actual point cloud bounding box.
This makes sense if you want the point cloud to be on the center of the scene. But not at our case.
So, if you override this feature by changing potree.js bounding box set from
boundingBox.min.sub(offset);
boundingBox.max.sub(offset);
tightBoundingBox.min.sub(offset);
tightBoundingBox.max.sub(offset);
to
tightBoundingBox.min.sub(offset);
tightBoundingBox.max.sub(offset);
boundingBox.copy(tightBoundingBox);
the point cloud will align with the model.
FYI: The fixes we made where actually making us able to run potree converter 1.7 instead of 1.6 as specified in the demo readme.

Get Co-ordinates based on the marker location over the google map

Aoa,
I am working on a web application where a shop vendor must put a latitude and longitude of his/her shop.
It is easy to get if he/she is using application from the shop. But if he/she is somewhere else i want to show a map option to the vendor where he/she could search his/her shop point it. And I could get co-ordinates from that marker position.
I have studied google map api found a lot of useful things but couldn't understand how to achieve this as I am unable to find anything regarding getting co-ordinates from the marker.
It will be great if anybody could guide me that where should I look or what should I study to solve my issue.
Thanks in advance..
You can use the Maps JavaScript API to put a marker every time a certain point in the map was clicked then get the coordinates of the point and display it so that your user can directly get the exact coordinate of the marker. Here is a simple code I made to demonstrate this.
In the code, I used a listener to the map to check for every click on the map and put a marker on it. It will then update the label display with the coordinate of the marker.
map.addListener('click', function(event) {
addMarker(event.latLng);
document.getElementById("text").innerHTML = event.latLng.lat() + ',' + event.latLng.lng();
});
Hope this helps!
Right-click on the red marker on Google Maps after searching the location, select "what's here?" and you will see the coordinates in a pop-up.

Passing coordinates values from google sheets columns in static map URL

I've been trying to fill a google spreadsheet column with static satellite maps giving the coords from latitude and longitude columns.
Something like this:
=IMAGE("https://api.mapbox.com/styles/v1/mapbox/streets-v10/static/"&K1&","&J1&",14.25,0,60/600x600?access_token=API_KEY")
My problem is constructing the API call using Lat, long pairs stored in the Google Sheet cells.
I am getting a range of errors from both Google sheets and mapbox, so obviously my syntax within sheets is bad. When I type the url in a browser, with hard-coded lat,lng the correct map image is displayed.
A typical Google error is
Function ADD parameter 1 expects number values. But
'https://api.mapbox.com/styles/v1/mapbox/streets-v10/static/' is a
text and cannot be coerced to a number
Can someone please assist?
I think you had Lat, long wrong way around. Some mapping systems require Lat, Lng and others Lng, Lat (go figure!)
If you change as below, you will get an image, but you may need to play with other parameters to get it working as you need.
=IMAGE("https://api.mapbox.com/styles/v1/mapbox/streets-v10/static/"&K3&","&J3&",14.25,0,60/600x600?access_token=API_KEY")
You can also use the form below which is another way to construct the API string from the component parts.
=image(concatenate("https://api.mapbox.com/styles/v1/mapbox/streets-v10/static/",K3,",",J3,",14.25,0,60/600x600?access_token=ACCESS_KEY"))
In both cases, the parameters after the Coordinates represent the desired zoom, orientation angles and image resolution. You can play around with image formats here https://www.mapbox.com/help/static-api-playground/.
Also note that you have options in Google sheets to adjust how the image is displayed (resize, stretch etc) in the cell, using the IMAGE parameters. This is explained here https://support.google.com/docs/answer/3093333?hl=en

How can i get the rotaciĆ³n of a node from the JSON document in Figma?

I'm using Figma API to get a figma document but I can not get the rotation of a node. How is the rotation of an object calculated?
If you are using the Figma plugin API, you can just access rotation property. See the documentation here.
If you are using the Figma REST API, you can get it from the relativeTransform property. Given a transform value of [[m00, m01, m02], [m10, m11, m12]], I believe the rotation should be atan2(-m10, m00). This ends up being the angle of the x axis of the transform. Note that relativeTransform is only present if you pass geometry=paths. See the documentation here for more information.

How to manually set the GPS coordinates if the app is always asking user's location

What I have achieved so far is implement this tutorial http://www.androidhive.info/2012/08/Android-working-with-Google-places-and-maps-tutorial/
And now what I want is to implement a way in which GPStracker class which enables GPS for my device and detects where I am right now instead of my location, I want to show my app users a particular area let's say north of Bangalore (India); I know how to setup different types but I'm asking help in this
i.putExtra("user_latitude", Double.toString(gps.getLatitude()));
i.putExtra("user_longitude", Double.toString(gps.getLongitude()));
gps.getLatitude ()
Is asking GPSTracker.java for coordinates and the location manager is simply pulling the same from my location, but what I want is fake the users location to some coordinates in the north of the city so that I can show them the results of that area (places -restaurants)

Resources