geo

Post DbGeography data type in odata v4 api

一世执手 提交于 2021-02-19 06:18:07
问题 What i receive from a DbGeography data type is in Location. { "@odata.context":"http://subdomain.mydomain.me/odata/$metadata#Pois","value":[ { "Id":"d57e6603-5530-4457-b041-6398b7182173","Name":"Demo Home","Address":"Zuidstraat 8 8630 Veurne","Location":{ "Geography":{ "CoordinateSystemId":4326,"WellKnownText":"POINT (51.515574 2.025285)","WellKnownBinary":null } },"TagId":"ec32e8f3-c0b8-4bcc-af6c-7059b1ef1a65","RouteId":null } ] } I have tried multiple POSTS, but none of them seem to succeed

Convert canvas' mouse coords to geographic coords

落爺英雄遲暮 提交于 2021-02-19 06:10:51
问题 I'm trying to create a map with all the cities of Italy using Python-Tkinter and Canvas . I found a picture of a map of Italy with a few highlighted cities online and inserted it to my Canvas . After that I used a function to determine what are the canvas coordinates of the 2 highlighted cities using: import tkinter as tk class Map(): #Creator-Function def __init__(self,parent): self.canvas=tk.Canvas(width=995,height=971,bg='black') self.canvas.pack(expand=0,fill='none') self.gif=tk

Convert canvas' mouse coords to geographic coords

非 Y 不嫁゛ 提交于 2021-02-19 06:10:18
问题 I'm trying to create a map with all the cities of Italy using Python-Tkinter and Canvas . I found a picture of a map of Italy with a few highlighted cities online and inserted it to my Canvas . After that I used a function to determine what are the canvas coordinates of the 2 highlighted cities using: import tkinter as tk class Map(): #Creator-Function def __init__(self,parent): self.canvas=tk.Canvas(width=995,height=971,bg='black') self.canvas.pack(expand=0,fill='none') self.gif=tk

in d3.geo MultiPoint how can I provide different shapes for different poins?

天大地大妈咪最大 提交于 2021-02-19 04:47:04
问题 I have some geoJson data that I am charting using d3.geo. When I write something like d3.select("svg") ... .attr("d", function(d) { return path({ type:"MultiPoint", coordinates: get_activity_coords_(d.activities) }); }) I always get a circle for each coordinate. The coordinates represent locations of various stopping points of a journey. What I would prefer is a different shape for the first and the last coordinate. Is it possible to do this using MultiPoint, is there an example that I can

How can I retrieve Latitude and Longitude of a postal address using Bing Maps?

故事扮演 提交于 2021-02-18 22:22:09
问题 I want to be able to retrieve the geographical coordinates (latitude and longitude) for a given address. I'm hoping I can do that if I have the full address (street address + city + state + zip). If it matters, I am using Bing Maps. The skeleton code I've got is this (fullAddress, AddPushpin(), and getGeoCordsForAddress() are the most pertinent parts): private void btnSave_Click(object sender, EventArgs e) { string fullAddress = string.Empty; if (MissingValues()) return; mapName = cmbxMapName

Showing geographic location on a world map of a user

我是研究僧i 提交于 2021-02-10 15:49:57
问题 I'm trying to make a simple script that takes lon/lat as an argument and places an dot on a word map image, simple. <?php if(empty($long))$long = 56.946536; if(empty($lat)) $lat = 24.10485; $im = imagecreatefromjpeg("earth_310.jpg"); $red = imagecolorallocate ($im, 255,0,0); $scale_x = imagesx($im); $scale_y = imagesy($im); $pt = getlocationcoords($lat, $long, $scale_x, $scale_y); imagefilledrectangle($im,$pt["x"]-2,$pt["y"]-2,$pt["x"]+2,$pt["y"]+2,$red); header("Content-Type: image/png");

Extracting data from raster file to match with shp file

家住魔仙堡 提交于 2020-12-15 05:41:28
问题 UPDATE: UPDATE: The problem was that my way to produce the grid cells has led to a wrong projection of my shapefile which resulted in the above mentioned error. I was able to produce another form of grid cells that worked perfectly with my projection. After I successfully created a raster grid for the world map (How to generate 10x10km grid cells of all countries?) library(sf) library(stars) library(rnaturalearth) # Polygon world = ne_countries(scale = "small", returnclass = "sf") world = st