Git Product home page Git Product logo

amap_view_muka's Introduction

amap_view_muka

Flutter高德地图插件

引入方式

    amap_view_muka: ^0.1.0

支持

  • 显示地图
    • 显示定位蓝点
    • 显示室内地图
    • 切换地图图层
    • 使用离线地图 [目前只支持官方UI]
    • 显示英文地图
    • 自定义地图 [写了方法但不起作用,不知道啥问题]
  • 与地图交互
    • 控件交互
    • 手势交互
    • 调用方法交互
    • 地图截屏功能
  • 在地图上绘制
    • 绘制点标记
    • 绘制线
    • 绘制面
    • 绘制热力图
    • 绘制3D模型
    • 点平滑移动
    • 绘制海量点图层

Android

AndroidManifest.xml添加如下代码 <meta-data android:name="com.amap.api.v2.apikey" android:value="你的key" />

IOS

Info.plist添加如下代码

    // 默认
    <key>NSLocationWhenInUseUsageDescription</key>
    <string>App需要您的同意,才能访问位置</string>
    <key>NSLocationAlwaysAndWhenInUseUsageDescription</key>
    <string>App需要您的同意,才能访问位置</string>
    <key>amap_key</key>
    <string>你的key</string>

    // 导航 [后台持续定位只需要location]
    <key>UIBackgroundModes</key> 
    <array> 
        <string>location</string>
        <string>audio</string> 
    </array>
  • 2022/08/19 flutter Widget 转为icon使用
/// 增加android AMapViewImage.uint8List

RenderRepaintBoundary render = _globalKey.currentContext!.findRenderObject() as RenderRepaintBoundary;
ui.Image image = await render.toImage();
ByteData? byteData = await image.toByteData(format: ui.ImageByteFormat.png);
print(byteData?.buffer.asUint8List());
AmapMarker newMarker = AMapDefaultMarker(
    id: '3',
    position: LatLng(30.573961, 104.066301),
    icon: AMapViewImage.uint8List(byteData!.buffer.asUint8List(), size: AMapImageSize(height: 90, width: 90)),
);
print(newMarker.toJson());
await _amapViewController.addMarker(newMarker);

amap_view_muka's People

Contributors

spicely avatar

Watchers

James Cloos avatar  avatar

Forkers

mflaugh

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.