全部服务产品
开发者频道
定价
登录
绘制动态轨迹
下载开发文档
简介

Since 3.5.0 动态轨迹支持渐变色绘制和.gltf+.bin模型加载,并支持动画播放。

示例代码如下:

/// 构造动态轨迹动画参数
BMFTraceOverlayAnimateOption traceOverlayAnimateOption =
BMFTraceOverlayAnimateOption(
animate: true,
delay: 0.0,
duration: 8,
fromValue: 0.0,
toValue: 1.0,
easingCurve: BMFTraceOverlayAnimationEasingCurve.Linear,
trackMove: false,
isPointMove: true,
isRotateWhenTrack: true,
modelOption: BMFTrace3DModelOption(
modelName: "scenes",
modelPath: 'resoures/Model3D',
yawAxis: BMFTraceOverlay3DModelYawAxis.YawAxisX,
scale: 3.0,
zoomFixed: true,
animationIsEnable: true,
animationIndex: 1,
type: BMF3DModelType.BMF3DModelTypeGLTF),
);
/// 构造动态轨迹
_traceOverlay = BMFTraceOverlay(
coordinates: coords,
traceOverlayAnimateOption: traceOverlayAnimateOption,
isThined: true,
isTrackBloom: true,
isGradientColor: true,
bloomSpeed: 5.0,
isCornerSmooth: false,
strokeColors: colors);
await myMapController.addTraceOverlay(_traceOverlay);

显示效果如图:

上一篇

绘制3D模型

下一篇

绘制海量点

本篇文章对您是否有帮助?