[3.4.0][mogo-adas]Taxi和清扫车共用后摄像头接口,改为主动订阅接口方式

This commit is contained in:
xinfengkun
2023-07-12 16:02:41 +08:00
parent 494a3e51db
commit cfc36e03a3
15 changed files with 78 additions and 51 deletions

View File

@@ -21,7 +21,7 @@ import mogo.telematics.pad.MessagePad.SetParamReq
import java.util.concurrent.atomic.AtomicInteger
import kotlin.concurrent.*
internal class MoGoLookAroundProviderImpl: IMoGoLookAroundProvider, IMoGoSweeperFutianBackCameraVideoListener, IMoGoRoboBusJinlvM1StitchedVideoListener, IMoGoGetParamResponseListener {
internal class MoGoLookAroundProviderImpl: IMoGoLookAroundProvider, IMoGoBackCameraVideoListener, IMoGoRoboBusJinlvM1StitchedVideoListener, IMoGoGetParamResponseListener {
companion object {
private const val TAG = "MoGoLookAroundProvider"
@@ -58,7 +58,7 @@ internal class MoGoLookAroundProviderImpl: IMoGoLookAroundProvider, IMoGoSweeper
private var job: Job? = null
override fun init(ctx: Context) {
CallerSweeperFutianBackCameraVideoListenerManager.addListener(TAG, this)
CallerBackCameraVideoListenerManager.addListener(TAG, this)
CallerRoboBusJinlvM1StitchedVideoListenerManager.addListener(TAG, this)
CallerAutopilotGetParamResponseDispatcher.addListener(TAG, this)
if (AppIdentityModeUtils.isM1(FunctionBuildConfig.appIdentityMode)) {
@@ -116,7 +116,7 @@ internal class MoGoLookAroundProviderImpl: IMoGoLookAroundProvider, IMoGoSweeper
}
override fun onSweeperFutianBackCameraVideo(data: ByteArray) {
override fun onBackCameraVideo(data: ByteArray) {
if (bitmapWidth.get() == 0 || bitmapHeight.get() == 0) {
val options = BitmapFactory.Options()
options.inJustDecodeBounds = true