|
立得地图iOS SDK 地图&搜索服务参考手册 V1.7.0
|
该类是地图覆盖物View的基类, 提供绘制overlay的接口但并无实际的实现 更多...
#import <LMKOverlayView.h>
属性 |
|
| id< LMKOverlay > | overlay |
| 关联的overlay对象 更多... |
|
| int * | g20MapPoints |
| 缓存的G20坐标 更多... |
|
| NSUInteger | g20MapPointCount |
| 缓存的G20坐标 个数 更多... |
|
| GLuint | strokeTextureID |
| 笔触纹理id 修改纹理id参考 - (GLuint)loadStrokeTextureImage:textureImage;
更多... |
|
该类是地图覆盖物View的基类, 提供绘制overlay的接口但并无实际的实现
| - (void) drawMapRect: | (LMKMapRect) | mapRect | |
| zoomScale: | (CGFloat) | zoomScale | |
| inContext: | (CGContextRef) | context | |
绘制overlay view的内容
| mapRect | 该LMKMapRect范围内需要更新 |
| zoomScale | 当前的缩放比例值 |
| context | 绘制操作的graphics context |
| - (int*) g20PointsForMapPoints: | (LMKMapPoint *) | mapPoints | |
| count: | (NSUInteger) | count | |
批量将LMKMapPoint转换为opengles可以直接使用的坐标
| mapPoints | LMKMapPoint坐标数据指针 |
| count | 个数 |
| - (void) glRender |
绘制函数(子类需要重载来实现)
| - (CGFloat) glWidthForWindowWidth: | (CGFloat) | windowWidth |
将屏幕尺寸转换为OpenGLES尺寸
| windowWidth | 屏幕尺寸 |
| - (id) initWithOverlay: | (id< LMKOverlay >) | overlay |
初始化并返回一个overlay view
| overlay | 关联的overlay对象 |
| - (GLuint) loadStrokeTextureImage: | (UIImage *) | textureImage |
加载纹理图片,纹理ID存储在成员strokeTextureID中。纹理图片为nil时,清空原有纹理。
| textureImage | 纹理图片(需满足:长宽相等,且宽度值为2的次幂)。若为nil,则清空原有纹理。 |
| - (LMKMapPoint) mapPointForPoint: | (CGPoint) | point |
| - (LMKMapRect) mapRectForRect: | (CGRect) | rect |
| - (CGPoint) pointForMapPoint: | (LMKMapPoint) | mapPoint |
将LMKMapPoint转化为相对于receiver的本地坐标
| mapPoint | 要转化的LMKMapPoint |
| - (CGRect) rectForMapRect: | (LMKMapRect) | mapRect |
将LMKMapRect转化为相对于receiver的本地rect
| mapRect | 要转化的LMKMapRect |
| - (void) referenceDidChange |
OpenGLES坐标系发生改变, 重新计算缓存的OpenGLES坐标
| - (void) renderIconWithTextureID: | (GLuint) | textureID | |
| points: | (int *) | points | |
使用OpenGLES 绘制图片
| textureID | OpenGLES纹理ID |
| points | OpenGLES坐标系点指针,纹理矩形的四个顶点坐标,其第一个坐标为图片左上角,依次顺时针传入其他顶点 ,参考- (CGPoint)glPointForMapPoint:(LMKMapPoint)mapPoint, - (CGPoint *)glPointsForMapPoints:(LMKMapPoint *)mapPoints count:(NSUInteger)count , |
| - (void) renderLinesWithPoints: | (int *) | points | |
| pointCount: | (NSUInteger) | pointCount | |
| strokeColor: | (UIColor *) | strokeColor | |
| lineWidth: | (CGFloat) | lineWidth | |
| lineTextureID: | (GLint) | lineTextureID | |
| texLen: | (CGFloat) | texLen | |
| looped: | (BOOL) | looped | |
| complex: | (BOOL) | complex | |
使用OpenGLES 绘制线
| points | OpenGLES坐标系点指针, 参考- (CGPoint)glPointForMapPoint:(LMKMapPoint)mapPoint, - (CGPoint *)glPointsForMapPoints:(LMKMapPoint *)mapPoints count:(NSUInteger)count |
| pointCount | 点个数 |
| strokeColor | 线颜色 |
| lineWidth | OpenGLES支持线宽尺寸, 参考 - (CGFloat)glWidthForWindowWidth:windowWidth |
| lineTextureID | OpenGLES纹理ID |
| texLen | 纹理长度 |
| looped | 是否闭合, 如polyline会设置NO, polygon会设置YES. |
| complex | 是否是复杂纹理 |
| - (void) renderLinesWithPoints: | (int *) | points | |
| pointCount: | (NSUInteger) | pointCount | |
| strokeColor: | (UIColor *) | strokeColor | |
| lineWidth: | (CGFloat) | lineWidth | |
| looped: | (BOOL) | looped | |
使用OpenGLES 绘制线
| points | OpenGLES坐标系点指针, 参考- (CGPoint)glPointForMapPoint:(LMKMapPoint)mapPoint, - (CGPoint *)glPointsForMapPoints:(LMKMapPoint *)mapPoints count:(NSUInteger)count |
| pointCount | 点个数 |
| strokeColor | 线颜色 |
| lineWidth | OpenGLES支持线宽尺寸, 参考 - (CGFloat)glWidthForWindowWidth:windowWidth |
| looped | 是否闭合, 如polyline会设置NO, polygon会设置YES. |
| - (void) renderLinesWithPoints: | (int *) | points | |
| pointCount: | (NSUInteger) | pointCount | |
| strokeColor: | (UIColor *) | strokeColor | |
| lineWidth: | (CGFloat) | lineWidth | |
| looped: | (BOOL) | looped | |
| lineDash: | (BOOL) | lineDash | |
| complex: | (BOOL) | complex | |
使用OpenGLES 绘制线
| points | OpenGLES坐标系点指针, 参考- (CGPoint)glPointForMapPoint:(LMKMapPoint)mapPoint, - (CGPoint *)glPointsForMapPoints:(LMKMapPoint *)mapPoints count:(NSUInteger)count |
| pointCount | 点个数 |
| strokeColor | 线颜色 |
| lineWidth | OpenGLES支持线宽尺寸, 参考 - (CGFloat)glWidthForWindowWidth:windowWidth |
| looped | 是否闭合, 如polyline会设置NO, polygon会设置YES. |
| lineDash | 是否是虚线 |
| complex | 是否是复杂纹理 |
| - (void) renderLinesWithPoints: | (int *) | points | |
| pointCount: | (NSUInteger) | pointCount | |
| strokeColor: | (UIColor *) | strokeColor | |
| lineWidth: | (CGFloat) | lineWidth | |
| looped: | (BOOL) | looped | |
| LineJoinType: | (LMKLineJoinType) | lineJoinType | |
| LineCapType: | (LMKLineCapType) | lineCapType | |
| lineDash: | (BOOL) | lineDash | |
使用OpenGLES 绘制线
| points | OpenGLES坐标系点指针, 参考- (CGPoint)glPointForMapPoint:(LMKMapPoint)mapPoint, - (CGPoint *)glPointsForMapPoints:(LMKMapPoint *)mapPoints count:(NSUInteger)count |
| pointCount | 点个数 |
| strokeColor | 线颜色 |
| lineWidth | OpenGLES支持线宽尺寸, 参考 - (CGFloat)glWidthForWindowWidth:windowWidth |
| looped | 是否闭合, 如polyline会设置NO, polygon会设置YES. |
| lineJoinType | 线连接点样式 |
| lineCapType | 线端点样式 |
| lineDash | 是否是虚线 |
| - (void) renderRegionWithPoints: | (int *) | points | |
| pointCount: | (NSUInteger) | pointCount | |
| fillColor: | (UIColor *) | fillColor | |
| usingTriangleFan: | (BOOL) | usingTriangleFan | |
使用OpenGLES 绘制区域
| points | OpenGLES坐标系点指针, 参考- (CGPoint)glPointForMapPoint:(LMKMapPoint)mapPoint, - (CGPoint *)glPointsForMapPoints:(LMKMapPoint *)mapPoints count:(NSUInteger)count |
| pointCount | 点个数 |
| fillColor | 填充颜色 |
| usingTriangleFan | 若必为凸多边形输入YES,可能为凹多边形输入NO |
|
readwritenonatomicassign |
缓存的G20坐标 个数
|
readwritenonatomicassign |
缓存的G20坐标
|
readnonatomicstrong |
关联的overlay对象
|
readnonatomicassign |
笔触纹理id 修改纹理id参考 - (GLuint)loadStrokeTextureImage:textureImage;
1.8.10