Giter VIP home page Giter VIP logo

postgis_layertransform's Introduction

postgis_LayerTransform

一个在postgis中结合**国情,批量对数据进行加偏到百度坐标,高德谷歌的火星坐标,或者逆向纠偏

安装:

在postgresql-postgis空间数据库中,执行sql文件中语句即可。

使用:

select LayerTransform( in inputlayer text,--输入图层名字 in transformtype transform_type--转换类型枚举型。 ) 如在psql中输入: select LayerTransform('road','GCJ2WGS'); 回车执行该语句即可,等待完成。该示例代码是将 road表从火星坐标系转往84坐标系。

参数说明:

inputlayer:输入的表名称,是个要加/纠偏的table名称,table是个空间表。
transformtype:加/纠偏方式,支持以下6种'BD2GCJ', 'GCJ2BD', 'WGS2GCJ','GCJ2WGS','BD2WGS','WGS2BD',分别代表 百度转谷歌高德,谷歌高德转百度,84转火星,火星转84,百度转84,84转百度。

效果图

转换前:底图是osm,非偏移的84墨卡托投影,'road'是火星坐标的墨卡托投影。 这里写图片描述 转换后: 这里写图片描述

postgis_layertransform's People

Watchers

mn3711698 avatar

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.