BaiduMap_IOSSDK_v7.2.0_Docs 7.2.0

BMKBackgroundMapView.h
浏览该文件的文档.
1 //
2 // BMKBackgroundMapView.h
3 // MapComponent
4 //
5 // Created by zhaoxiangru on 2024/2/29.
6 // Copyright © 2024 Baidu. All rights reserved.
7 //
8
9 #import <UIKit/UIKit.h>
10 #import "BMKBackgroundRoadNetView.h"
11 #import "BMKBackgroundNavigationView.h"
12 #import "BMKMapView.h"
13
14 NS_ASSUME_NONNULL_BEGIN
16 @interface BMKBackgroundMapView : UIView
18 @property (nonatomic, weak) BMKMapView *mapview;
20 @property (nonatomic, assign) NSInteger frameRate;
22 @property (nonatomic, assign) CGPoint mapScreenExtOffset;
24 @property (nonatomic, assign) BOOL enable3D;
26 @property (nonatomic, readonly) BOOL isRendering;
28 @property (nonatomic, readonly) CGFloat fitScale;
30 @property (nonatomic, readonly) UIView *backgroundView;
32 @property (nonatomic, readonly) BMKBackgroundRoadNetView *roadNetView;
35 @property (nonatomic, weak) BMKBackgroundNavigationView *navigationView;
37 @property (nonatomic, assign) BMKLogoPosition logoPosition;
39 @property (nonatomic, assign) BOOL showScaleBar;
41 @property (nonatomic, assign) CGPoint scaleBarPosition;
43 @property (nonatomic, readonly) CGSize scaleBarSize;
45 @property (nonatomic, strong) UIColor *scaleBarColor;
47 @property (nonatomic, strong) UIColor *scaleBarTextColor;
48
50 - (void)startRender;
52 - (void)stopRender;
54 - (nullable UIImage *)takeSnapshot:(CGRect)rect;
56 - (nullable UIImage *)takeSnapshot:(CGRect)rect needLogo:(BOOL)needLogo;
57 @end
58
59 NS_ASSUME_NONNULL_END
BMKBackgroundMapView::scaleBarPosition
CGPoint scaleBarPosition
比例尺的位置，设定坐标以左上角为原点，向右向下增长，默认左上角00
Definition: BMKBackgroundMapView.h:41
BMKBackgroundMapView::mapScreenExtOffset
CGPoint mapScreenExtOffset
设置地图额外偏移量,x轴负值向左偏，y轴负值向上偏，默认地图中心点targetScreenPt，可用于微调小车位置等
Definition: BMKBackgroundMapView.h:22
BMKBackgroundMapView::scaleBarSize
CGSize scaleBarSize
比例尺的宽高,宽最大值为mapview宽度的一半
Definition: BMKBackgroundMapView.h:43
BMKMapView
地图View类，使用此View可以显示地图窗口，并且对地图进行相关的操作
Definition: BMKMapView.h:132
BMKBackgroundMapView::mapview
BMKMapView * mapview
关联源地图，用于同步数据
Definition: BMKBackgroundMapView.h:18
BMKBackgroundMapView::roadNetView
BMKBackgroundRoadNetView * roadNetView
获取路网图层，用于自定义路网颜色
Definition: BMKBackgroundMapView.h:32
BMKBackgroundMapView::showScaleBar
BOOL showScaleBar
设定是否显式比例尺，默认NO
Definition: BMKBackgroundMapView.h:39
BMKBackgroundMapView::scaleBarColor
UIColor * scaleBarColor
比例尺颜色，默认黑色
Definition: BMKBackgroundMapView.h:45
BMKBackgroundMapView::fitScale
CGFloat fitScale
当前适配后缩放比例
Definition: BMKBackgroundMapView.h:28
BMKBackgroundMapView::isRendering
BOOL isRendering
当前是否在渲染
Definition: BMKBackgroundMapView.h:26
BMKBackgroundMapView::scaleBarTextColor
UIColor * scaleBarTextColor
比例尺文本颜色，默认与比例尺颜色一致
Definition: BMKBackgroundMapView.h:47
BMKBackgroundRoadNetView.h
-[BMKBackgroundMapView startRender]
void startRender()
开始渲染
BMKBackgroundMapView::enable3D
BOOL enable3D
3D绘制，默认YES
Definition: BMKBackgroundMapView.h:24
-[BMKBackgroundMapView stopRender]
void stopRender()
结束渲染
BMKLogoPosition
BMKLogoPosition
枚举：logo位置
Definition: BMKMapView.h:59
BMKBackgroundMapView::logoPosition
BMKLogoPosition logoPosition
logo位置，默认BMKLogoPositionLeftBottom
Definition: BMKBackgroundMapView.h:37
BMKBackgroundMapView
进入后台或锁屏时的地图渲染View，配合后台保活和关联源地图BMKMapView用于后台投屏，
Definition: BMKBackgroundMapView.h:17
BMKBackgroundRoadNetView
Definition: BMKBackgroundRoadNetView.h:15
BMKBackgroundMapView::frameRate
NSInteger frameRate
帧率控制，默认30帧/s，范围10～60帧/s
Definition: BMKBackgroundMapView.h:20
BMKBackgroundMapView::backgroundView
UIView * backgroundView
获取背景图层,用于自定义背景颜色
Definition: BMKBackgroundMapView.h:30
BMKBackgroundMapView::navigationView
BMKBackgroundNavigationView * navigationView
Definition: BMKBackgroundMapView.h:35
BMKMapView.h