Java Code Examples for com.baidu.mapapi.map.BitmapDescriptorFactory#fromAssetWithDpi()

The following examples show how to use com.baidu.mapapi.map.BitmapDescriptorFactory#fromAssetWithDpi() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: BusLineOverlay.java    From BmapLite with GNU General Public License v3.0 5 votes vote down vote up
public BitmapDescriptor getStationMarker() {
    if (type == PoiInfo.POITYPE.SUBWAY_LINE){
        return BitmapDescriptorFactory.fromAssetWithDpi("icon_subway_station.png");
    }else {
        return BitmapDescriptorFactory.fromAssetWithDpi("icon_bus_station.png");
    }
}
 
Example 2
Source File: TransitRouteOverlay.java    From BmapLite with GNU General Public License v3.0 5 votes vote down vote up
private BitmapDescriptor getIconForStep(TransitRouteLine.TransitStep step) {
    switch (step.getStepType()) {
        case BUSLINE:
            return BitmapDescriptorFactory.fromAssetWithDpi("icon_bus_station.png");
        case SUBWAY:
            return BitmapDescriptorFactory.fromAssetWithDpi("icon_subway_station.png");
        case WAKLING:
            return BitmapDescriptorFactory.fromAssetWithDpi("icon_walk_route.png");
        default:
            return null;
    }
}
 
Example 3
Source File: MassTransitRouteOverlay.java    From BmapLite with GNU General Public License v3.0 5 votes vote down vote up
private BitmapDescriptor getIconForStep(MassTransitRouteLine.TransitStep step) {
    switch (step.getVehileType()) {
        case ESTEP_WALK:
            return BitmapDescriptorFactory.fromAssetWithDpi("icon_walk_route.png");
        case ESTEP_TRAIN:
            return BitmapDescriptorFactory.fromAssetWithDpi("icon_subway_station.png");
        case ESTEP_DRIVING:
        case ESTEP_COACH:
        case ESTEP_PLANE:
        case ESTEP_BUS:
            return BitmapDescriptorFactory.fromAssetWithDpi("icon_bus_station.png");
        default:
            return null;
    }
}
 
Example 4
Source File: BusLineOverlay.java    From BmapLite with Apache License 2.0 5 votes vote down vote up
public BitmapDescriptor getStationMarker() {
    if (type == PoiInfo.POITYPE.SUBWAY_LINE){
        return BitmapDescriptorFactory.fromAssetWithDpi("icon_subway_station.png");
    }else {
        return BitmapDescriptorFactory.fromAssetWithDpi("icon_bus_station.png");
    }
}
 
Example 5
Source File: TransitRouteOverlay.java    From BmapLite with Apache License 2.0 5 votes vote down vote up
private BitmapDescriptor getIconForStep(TransitRouteLine.TransitStep step) {
    switch (step.getStepType()) {
        case BUSLINE:
            return BitmapDescriptorFactory.fromAssetWithDpi("icon_bus_station.png");
        case SUBWAY:
            return BitmapDescriptorFactory.fromAssetWithDpi("icon_subway_station.png");
        case WAKLING:
            return BitmapDescriptorFactory.fromAssetWithDpi("icon_walk_route.png");
        default:
            return null;
    }
}
 
Example 6
Source File: MassTransitRouteOverlay.java    From BmapLite with Apache License 2.0 5 votes vote down vote up
private BitmapDescriptor getIconForStep(MassTransitRouteLine.TransitStep step) {
    switch (step.getVehileType()) {
        case ESTEP_WALK:
            return BitmapDescriptorFactory.fromAssetWithDpi("icon_walk_route.png");
        case ESTEP_TRAIN:
            return BitmapDescriptorFactory.fromAssetWithDpi("icon_subway_station.png");
        case ESTEP_DRIVING:
        case ESTEP_COACH:
        case ESTEP_PLANE:
        case ESTEP_BUS:
            return BitmapDescriptorFactory.fromAssetWithDpi("icon_bus_station.png");
        default:
            return null;
    }
}
 
Example 7
Source File: TransitRouteOverlay.java    From Mobike with Apache License 2.0 5 votes vote down vote up
private BitmapDescriptor getIconForStep(TransitRouteLine.TransitStep step) {
    switch (step.getStepType()) {
        case BUSLINE:
            return BitmapDescriptorFactory.fromAssetWithDpi("Icon_bus_station.png");
        case SUBWAY:
            return BitmapDescriptorFactory.fromAssetWithDpi("Icon_subway_station.png");
        case WAKLING:
            return BitmapDescriptorFactory.fromAssetWithDpi("Icon_walk_route.png");
        default:
            return null;
    }
}
 
Example 8
Source File: MassTransitRouteOverlay.java    From Mobike with Apache License 2.0 5 votes vote down vote up
private BitmapDescriptor getIconForStep(MassTransitRouteLine.TransitStep step) {
    switch (step.getVehileType()) {
        case ESTEP_WALK:
            return BitmapDescriptorFactory.fromAssetWithDpi("Icon_walk_route.png");
        case ESTEP_TRAIN:
            return BitmapDescriptorFactory.fromAssetWithDpi("Icon_subway_station.png");
        case ESTEP_DRIVING:
        case ESTEP_COACH:
        case ESTEP_PLANE:
        case ESTEP_BUS:
            return BitmapDescriptorFactory.fromAssetWithDpi("Icon_bus_station.png");
        default:
            return null;
    }
}
 
Example 9
Source File: TransitRouteOverlay.java    From react-native-baidu-map with MIT License 5 votes vote down vote up
private BitmapDescriptor getIconForStep(TransitRouteLine.TransitStep step) {
    switch (step.getStepType()) {
        case BUSLINE:
            return BitmapDescriptorFactory.fromAssetWithDpi("Icon_bus_station.png");
        case SUBWAY:
            return BitmapDescriptorFactory.fromAssetWithDpi("Icon_subway_station.png");
        case WAKLING:
            return BitmapDescriptorFactory.fromAssetWithDpi("Icon_walk_route.png");
        default:
            return null;
    }
}
 
Example 10
Source File: MassTransitRouteOverlay.java    From react-native-baidu-map with MIT License 5 votes vote down vote up
private BitmapDescriptor getIconForStep(MassTransitRouteLine.TransitStep step) {
    switch (step.getVehileType()) {
        case ESTEP_WALK:
            return BitmapDescriptorFactory.fromAssetWithDpi("Icon_walk_route.png");
        case ESTEP_TRAIN:
            return BitmapDescriptorFactory.fromAssetWithDpi("Icon_subway_station.png");
        case ESTEP_DRIVING:
        case ESTEP_COACH:
        case ESTEP_PLANE:
        case ESTEP_BUS:
            return BitmapDescriptorFactory.fromAssetWithDpi("Icon_bus_station.png");
        default:
            return null;
    }
}
 
Example 11
Source File: OverlayManager.java    From BmapLite with GNU General Public License v3.0 2 votes vote down vote up
/**
 * 覆写此方法以改变默认起点图标
 *
 * @return 起点图标
 */
public BitmapDescriptor getStartMarker() {
    return BitmapDescriptorFactory.fromAssetWithDpi("icon_start.png");
}
 
Example 12
Source File: OverlayManager.java    From BmapLite with GNU General Public License v3.0 2 votes vote down vote up
/**
 * 覆写此方法以改变默认终点图标
 *
 * @return 终点图标
 */
public BitmapDescriptor getTerminalMarker() {
    return BitmapDescriptorFactory.fromAssetWithDpi("icon_end.png");
}
 
Example 13
Source File: OverlayManager.java    From BmapLite with Apache License 2.0 2 votes vote down vote up
/**
 * 覆写此方法以改变默认起点图标
 *
 * @return 起点图标
 */
public BitmapDescriptor getStartMarker() {
    return BitmapDescriptorFactory.fromAssetWithDpi("icon_start.png");
}
 
Example 14
Source File: OverlayManager.java    From BmapLite with Apache License 2.0 2 votes vote down vote up
/**
 * 覆写此方法以改变默认终点图标
 *
 * @return 终点图标
 */
public BitmapDescriptor getTerminalMarker() {
    return BitmapDescriptorFactory.fromAssetWithDpi("icon_end.png");
}