"Fully open source" Baidu Map Web service API C #. NET version with map display controls, navigation controls, POI lookup controls

Source: Internet
Author: User

Directory

    • Overview
    • Function
    • How to use
    • Reference Help

Overview

The source code consists of three items, Bmap.net, BMap.NET.WindowsForm, and BMap.NET.WinformDemo.

    • Bmap.net

For some packages of the Baidu map Web Service API, each interface returns a Jobject type (see Json.NET);

    • BMap.NET.WindowsForm (began to write less a s, and then has not changed)

Provides a series of controls that you can use in WinForm, including map display controls, navigation controls, POI lookup controls, and so on;

    • BMap.NET.WinfromDemo

A simple demo that shows how to use the individual controls.

This project is entirely based on c#.net and does not use other scripts such as JavaScript. All wheels are hand-crafted.

GitHub Address

1. A search input box with hints

2. Location Search

3. Navigation

4. Add markers, Drawings

5. Regional Search

6. Quickly switch cities

Function

Bmap.net includes the following features:

    • POI Lookup
    • Location suggestions
    • Geographic (inverse) coding
    • Navigation (bus, car, walk)
    • IP location
    • Coordinate conversion (Mercator, GPS, Mars, Baidu coordinates)

The following features are included in the BMap.NET.WindowsForm:

    • Map display (basic operations such as drag, zoom, etc.)
    • Select map mode (satellite, normal, road network)
    • Set map load mode (local, local priority, server)
    • Drawing
    • Distance measurement
    • Add tag
    • Location Input Search Control
    • Navigation controls
    • Location List control

Does not include the following features:

    • 3D Map
    • Street View
    • The navigation does not take into account the real-time traffic information (or the departure time of the First Bus)

In addition, this project is only aimed at Baidu map, so in terms of scalability is seriously insufficient, compared with gmap.net is far from poor. But you can modify the code yourself to meet your requirements.

How to use

Bmap.net is very simple to use, and each interface returns the Jobject type (representing a JSON data), not much more.

Only 5 controls are exposed in BMap.NET.WindowsForm: Bplacebox,bmapcontrol,bplacesboard,bdirectionboard and Btabcontrol. Just drag them into the form designer, and then simply set their properties to correlate with each other:

1.BPlaceBox Property settings

2.BMapControl Property settings

3.BPlacesBoard Property settings

4.BDirectionBoard Property settings

You can then press F5 to run it without writing any code.

Note that the Btabcontrol control is just to mimic the tab effect on the left side of Baidu Map, which organizes Bplacesboard and Bdirectionboard controls.

Reference Help

1. Baidu Map API documentation

2.json.net

3.Json Visualization

Description

1) This article is just a brief introduction of some of the contents of this project, after the introduction of a number of key technologies, such as Baidu coordinate conversion, Baidu Map tile row number calculation (Baidu map and other maps are not the same) and so on. If you need a friend, you can follow this blog.

2) The project I know that there are several bugs, due to worry about the Baidu map API upgrade caused by the previously written function can not be used, so rush to complete a version. Then I will continue to refine this project.

Note: This project and all of its source code are subject to the MIT open source agreement. Feel helpful can point a praise, open source beneficial.

"Fully open source" Baidu Map Web service API C #. NET version with map display controls, navigation controls, POI lookup controls

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.