简体   繁体   中英

Google maps api v3 hide gray building overlays

I am making a map that can display several trains live driving around inside the station. However there is a grayed out building on top of the station that makes the tracks almost impossible to see. However when I look at google maps itself those buildings don't even appear. Is there a setting in the map options that I can implement to get rid of those buildings?

These are my existing map options:

var mapOptions = {
    zoom: 17,
    center: markerBounds.getCenter(),
    disableDoubleClickZoom: true,
    mapTypeControl: false,
    disableDefaultUI: true,
    scrollwheel: false,
    draggable: false,
    navigationControlOptions: {
        style: google.maps.NavigationControlStyle.SMALL
    },
    mapTypeId: google.maps.MapTypeId.ROADMAP
};

My map:

这是我的地图

Google maps:

在此处输入图片说明

Thanks in advance.

I found out how to fix the issue. Simply change

mapTypeId: google.maps.MapTypeId.ROADMAP

to

mapTypeId: google.maps.MapTypeId.TERRAIN

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM