[6.5.0][overlay] 绘线添加自定义纹理选项
This commit is contained in:
@@ -52,6 +52,8 @@ data class Polyline(val id: String, val owner: String, val level: Level, val opt
|
||||
|
||||
val lightSpeed: Float = builder.lightSpeed
|
||||
|
||||
val customTexture: Bitmap? = builder.customTexture
|
||||
|
||||
fun builder(): Builder {
|
||||
return builder
|
||||
}
|
||||
@@ -92,6 +94,8 @@ data class Polyline(val id: String, val owner: String, val level: Level, val opt
|
||||
|
||||
internal var lightSpeed: Float = 0f
|
||||
|
||||
internal var customTexture: Bitmap? = null
|
||||
|
||||
fun setId(id: String) = apply {
|
||||
this.id = id
|
||||
}
|
||||
@@ -160,6 +164,10 @@ data class Polyline(val id: String, val owner: String, val level: Level, val opt
|
||||
this.lightSpeed = speed
|
||||
}
|
||||
|
||||
fun setCustomTexture(texture: Bitmap) = apply {
|
||||
this.customTexture = texture
|
||||
}
|
||||
|
||||
fun build(): Options {
|
||||
if (TextUtils.isEmpty(id)) {
|
||||
id = UUID.randomUUID().toString()
|
||||
|
||||
Reference in New Issue
Block a user