Convert Figma logo to code with AI

mapsme logoomim

πŸ—ΊοΈ MAPS.ME β€” Offline OpenStreetMap maps for iOS and Android

4,571
1,148
4,571
1,005

Top Related Projects

4,641

OsmAnd

3,357

πŸ†” The easy-to-use OpenStreetMap editor in JavaScript.

Interactive, thoroughly customizable maps in native Android, iOS, macOS, Node.js, and Qt applications, powered by vector tiles and OpenGL

Interactive, thoroughly customizable maps in the browser, powered by vector tiles and WebGL

OpenMapTiles Vector Tile Schema Implementation

Open source routing engine for OpenStreetMap. Use it as Java library or standalone web server.

Quick Overview

OMIM (Open Maps in Minutes) is an open-source mapping project that powers the MAPS.ME mobile application. It provides offline maps and navigation for iOS and Android devices, using OpenStreetMap data. The project aims to create a fast, detailed, and globally available mapping solution that works without an internet connection.

Pros

  • Offline functionality, allowing users to access maps and navigation without an internet connection
  • Based on OpenStreetMap data, providing detailed and community-driven map information
  • Cross-platform support for both iOS and Android devices
  • Open-source nature allows for community contributions and improvements

Cons

  • Large initial download size for offline maps
  • May not have as frequent updates as online mapping solutions
  • Limited real-time traffic information due to offline nature
  • Learning curve for contributors due to the complexity of the codebase

Code Examples

// Example 1: Initializing the Framework
Framework framework;
framework.Init();

This code initializes the OMIM framework, which is the core component for map rendering and operations.

// Example 2: Loading a map for a specific location
m2::PointD const center(27.56781, 53.90056);
framework.ShowRect(center, 10);

This code loads and displays a map centered on the specified coordinates with a zoom level of 10.

// Example 3: Adding a marker to the map
place_page::Info info;
info.SetMercator(center);
info.SetTitle("My Marker");
framework.AddBookmark("My Category", info);

This code adds a marker (bookmark) to the map at the specified location with a title and category.

Getting Started

To get started with OMIM development:

  1. Clone the repository:

    git clone https://github.com/mapsme/omim.git
    
  2. Install dependencies (varies by platform, check the project's README for details)

  3. Build the project:

    cd omim
    ./configure.sh
    make -j4
    
  4. Run the desktop version:

    ./out/debug/desktop/desktop
    

For more detailed instructions and platform-specific setup, refer to the project's documentation on GitHub.

Competitor Comparisons

4,641

OsmAnd

Pros of OsmAnd

  • More extensive offline functionality, including advanced navigation features
  • Greater customization options for map appearance and data display
  • Larger and more active community, resulting in frequent updates and improvements

Cons of OsmAnd

  • Steeper learning curve due to complex interface and numerous features
  • Slower map rendering and navigation calculations compared to OMIM
  • Larger app size and higher resource consumption

Code Comparison

OsmAnd (Java):

public class MapActivity extends ActionBarActivity {
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_map);
        // Initialize map view and controls
    }
}

OMIM (C++):

namespace map
{
class Framework
{
public:
  void ShowMap();
  void SetViewport(m2::PointD const & center, double zoom);
};
}

OsmAnd uses Java for its Android app, while OMIM primarily uses C++ for cross-platform development. OsmAnd's code structure is more Android-specific, whereas OMIM's codebase is designed for multi-platform support. OMIM's use of C++ may contribute to its faster performance in certain areas, while OsmAnd's Java implementation allows for easier integration with Android-specific features and libraries.

3,357

πŸ†” The easy-to-use OpenStreetMap editor in JavaScript.

Pros of iD

  • Web-based editor, accessible from any browser without installation
  • User-friendly interface, suitable for both beginners and experienced mappers
  • Frequent updates and active community support

Cons of iD

  • Limited offline functionality compared to OMIM's robust offline capabilities
  • Less comprehensive mapping features for complex scenarios

Code Comparison

OMIM (C++):

void Framework::ShowPlacePage(place_page::Info const & info, bool animated)
{
  m_work.GetGuiThread().PostTask([this, info, animated]()
  {
    GetPlatform().RunTask(Platform::Thread::Gui, [this, info, animated]()
    {
      m_currentPlacePageInfo = info;
      ShowPlacePageImpl(info, animated);
    });
  });
}

iD (JavaScript):

iD.modes.Browse = function(context) {
    var mode = {
        id: 'browse',
        button: 'browse',
        title: t('modes.browse.title'),
        description: t('modes.browse.description')
    };

    mode.enter = function() {
        context.history().checkpoint('entered browse mode');
        context.selection().call(context.behaviors.hover());
        context.ui().sidebar.select(null);
    };

    return mode;
};

The code snippets showcase different programming languages and approaches, with OMIM using C++ for native performance and iD utilizing JavaScript for web-based functionality.

Interactive, thoroughly customizable maps in native Android, iOS, macOS, Node.js, and Qt applications, powered by vector tiles and OpenGL

Pros of mapbox-gl-native

  • More extensive documentation and examples
  • Wider platform support, including iOS, Android, and web
  • Larger community and more frequent updates

Cons of mapbox-gl-native

  • Requires a Mapbox account and API key for full functionality
  • More complex setup process for beginners
  • Larger file size and potentially higher resource usage

Code Comparison

omim:

#include "map/framework.hpp"

Framework framework;
framework.ShowCountry("USA");

mapbox-gl-native:

#include <mbgl/map/map.hpp>

mbgl::Map map(view);
map.setStyle(mbgl::style::Style("mapbox://styles/mapbox/streets-v11"));

Both repositories provide mapping solutions, but they differ in their approach and target audience. omim is more focused on offline mapping and navigation, while mapbox-gl-native offers a more comprehensive set of features for online mapping and customization. The code examples show that omim has a simpler API for basic operations, while mapbox-gl-native provides more granular control over map styling and rendering.

Interactive, thoroughly customizable maps in the browser, powered by vector tiles and WebGL

Pros of mapbox-gl-js

  • More extensive documentation and examples
  • Wider community support and active development
  • Better performance for web-based applications

Cons of mapbox-gl-js

  • Requires an API key and potentially incurs usage costs
  • Less suitable for offline use cases
  • More limited customization options for map data sources

Code Comparison

omim (C++):

void Framework::ShowTrack(kml::TrackId trackId)
{
  auto const & track = GetBookmarkManager().GetTrack(trackId);
  ShowTrackImpl(track);
}

mapbox-gl-js (JavaScript):

map.on('load', () => {
  map.addSource('route', {
    'type': 'geojson',
    'data': {
      'type': 'Feature',
      'properties': {},
      'geometry': {
        'type': 'LineString',
        'coordinates': [
          [-122.48369693756104, 37.83381888486939],
          [-122.48348236083984, 37.83317489144141]
        ]
      }
    }
  });
});

Both repositories offer mapping solutions, but omim is more focused on offline capabilities and native applications, while mapbox-gl-js is geared towards web-based mapping with extensive customization options. The code examples demonstrate the different approaches: omim uses C++ for native development, while mapbox-gl-js utilizes JavaScript for web integration.

OpenMapTiles Vector Tile Schema Implementation

Pros of OpenMapTiles

  • More focused on vector tile generation and styling
  • Extensive documentation and tutorials for users
  • Active community with frequent updates and contributions

Cons of OpenMapTiles

  • Limited to OpenStreetMap data, while OMIM supports multiple data sources
  • Less comprehensive mobile app development features compared to OMIM
  • Smaller scope, focusing primarily on map tiles rather than full navigation

Code Comparison

OMIM (C++):

void Framework::ShowPlacePage(place_page::Info const & info, bool animated)
{
  m_work.GetGuiThread().PostTask([this, info, animated]()
  {
    GetPlatform().RunTask(Platform::Thread::Gui, [this, info, animated]()
    {
      m_currentPlacePageInfo = info;
      ShowPlacePageImpl(info, animated);
    });
  });
}

OpenMapTiles (SQL):

CREATE OR REPLACE FUNCTION layer_transportation(bbox geometry, zoom_level int)
RETURNS TABLE(osm_id bigint, geometry geometry, class text, ramp int, oneway int, brunnel text, service text) AS $$
    SELECT osm_id, geometry, class, ramp, oneway, brunnel, service
    FROM osm_transportation_merge_linestring_gen_z11
    WHERE zoom_level >= 11 AND geometry && bbox
    UNION ALL
    SELECT osm_id, geometry, class, ramp, oneway, brunnel, service
    FROM osm_transportation_merge_linestring
    WHERE zoom_level < 11 AND geometry && bbox;
$$ LANGUAGE SQL IMMUTABLE;

Open source routing engine for OpenStreetMap. Use it as Java library or standalone web server.

Pros of GraphHopper

  • More focused on routing and navigation algorithms
  • Better documentation and API reference
  • Active community with frequent updates and contributions

Cons of GraphHopper

  • Limited offline functionality compared to OMIM
  • Less comprehensive mapping features
  • Smaller ecosystem of related tools and applications

Code Comparison

OMIM (C++):

void Framework::ShowTrack(Track const & track)
{
  m_bmManager.GetEditSession().ShowTrack(track);
  m_drapeEngine->UpdateGpsTrackPoints(track);
}

GraphHopper (Java):

public void route(GHRequest req, Consumer<GHResponse> consumer) {
    GHResponse res = new GHResponse();
    List<Path> paths = getPaths(req, res);
    consumer.accept(res);
}

Summary

OMIM is a comprehensive mapping solution with strong offline capabilities, while GraphHopper focuses on efficient routing algorithms. OMIM offers a wider range of features for map rendering and manipulation, but GraphHopper excels in route planning and optimization. OMIM is primarily written in C++, which may provide better performance for mobile devices, while GraphHopper's Java codebase might be more accessible for web-based applications. Both projects have their strengths, and the choice between them depends on the specific requirements of your mapping or routing project.

Convert Figma logo designs to code with AI

Visual Copilot

Introducing Visual Copilot: A new AI model to turn Figma designs to high quality code using your components.

Try Visual Copilot

README

MAPS.ME

MAPS.ME is an open source cross-platform offline maps application, built on top of crowd-sourced OpenStreetMap data. It was publicly released for iOS and Android.

Submodules

This repository contains submodules. Clone it with git clone --recursive. If you forgot, run git submodule update --init --recursive.

Translations

If you want to improve app translations or add more search synonyms, please check our wiki.

Compilation

To compile the project, you would need to initialize private key files. Run configure.sh and press Enter to create empty files, good enough to build desktop and Android debug packages.

For detailed installation instructions and Android/iOS building process, see INSTALL.md.

Building maps

To create one or many map files, first build the project, then use python module maps_generator.

Map styles

MAPS.ME uses its own binary format for map styles, drules_proto.bin, which is compiled from MapCSS using modified Kothic library. Feature set in MWM files depends on a compiled style, so make sure to rebuild maps after releasing a style.

For development, use MAPS.ME Designer app along with its generator tool: these allow for quick rebuilding of a style and symbols, and for producing a zoom-independent feature set in MWM files.

See STYLES.md for the format description, instructions on building a style and some links.

Development

You would need Qt 5 for development, most other libraries are included into the repository: see 3party directory. The team uses mostly XCode and Qt Creator, though these are not mandatory. We have an established c++ coding style and Objective-C coding style.

You can turn on experimental public transport support. For details please read simple instruction.

See CONTRIBUTING.md for the repository initialization process, the description of all the directories of this repository and other development-related information.

All contributors must sign a Contributor Agreement, so both our and their rights are protected.

Feedback

Please report bugs and suggestions to the issue tracker, or by mail to bugs@maps.me.

Authors and License

This source code is Copyright (C) 2020 My.com B.V. (Mail.Ru Group), published under Apache Public License 2.0, except third-party libraries. See NOTICE and data/copyright.html files for more information.