Merge branch 'dev_opt_2.15.0' into dev_robotaxi-d_230412_2.15.0

This commit is contained in:
donghongyu
2023-04-14 15:03:10 +08:00
8 changed files with 71 additions and 82 deletions

View File

@@ -41,7 +41,7 @@ public abstract class BusPassengerBaseFragment<V extends IView, P extends Presen
private ContentLoadingProgressBar mProgressBar;
private View mLiveBtn;
private OCHBorderShadowLayout mLiveShadow;
private View mLiveShadow;
/**
* 改变自动驾驶状态
*

View File

@@ -85,7 +85,7 @@ public class OCHBorderShadowLayout extends LinearLayout {
public OCHBorderShadowLayout(Context context, AttributeSet attrs, int defStyleAttr) {
super(context, attrs, defStyleAttr);
this.setLayerType(LAYER_TYPE_SOFTWARE, null);//取消硬件加速
// this.setLayerType(LAYER_TYPE_SOFTWARE, null);//取消硬件加速
TypedArray typedArray = context.obtainStyledAttributes(attrs, R.styleable.ShadowLayout);
shadowColor = typedArray.getColor(R.styleable.ShadowLayout_shadowColor, Color.BLUE);
blurRadius = typedArray.getDimension(R.styleable.ShadowLayout_blurRadius, SHADOW_DEFAULT_BLUR_RADIUS);

View File

@@ -5,6 +5,7 @@ buildscript {
apply from: rootProject.file('gradle/ext.gradle')
repositories {
mavenLocal()
maven { url 'https://storage.zego.im/maven' }
maven { url 'https://maven.aliyun.com/nexus/content/groups/public/' }
maven { url 'https://maven.aliyun.com/repository/public' }
maven { url 'https://maven.aliyun.com/repository/google' }
@@ -49,6 +50,7 @@ buildscript {
allprojects {
repositories {
mavenLocal()
maven { url 'https://storage.zego.im/maven' }
maven { url 'https://maven.aliyun.com/repository/public' }
maven { url 'http://maven.aliyun.com/nexus/content/groups/public/' }
maven { url 'https://maven.aliyun.com/repository/google' }

View File

@@ -214,12 +214,7 @@ class CameraListView : FrameLayout {
}
}
}
liveStreamManager.setLiveStatusChangeCallback {
textureView
.post {
handleSnLiveStatus(it)
}
}
}
private fun isCarLive(): Boolean {
@@ -237,17 +232,6 @@ class CameraListView : FrameLayout {
}
}
private fun handleSnLiveStatus(status: Int) {
when (status) {
0 -> {// 正在直播
}
1 -> {// 直播已停止
}
2 -> {// 直播强制结束
}
}
}
private val trafficCarLiveCallBack = object : ITrafficCarLiveCallBack {
override fun onLive(liveSn: String?) {
CallerLogger.d("$M_HMI$TAG", "onLive")
@@ -291,6 +275,14 @@ class CameraListView : FrameLayout {
}
}
}
override fun onPlaying() {
}
override fun onPlaRequesting() {
}
}
fun updateCameraData(cameraInfoList: List<CameraEntity>?) {
@@ -337,7 +329,6 @@ class CameraListView : FrameLayout {
if (valueAnimator.isStarted || valueAnimator.isRunning) {
valueAnimator.cancel()
}
liveStreamManager.setLiveStatusChangeCallback(null)
}
private fun stopLive() {

View File

@@ -15,7 +15,6 @@ import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
import com.mogo.eagle.core.utilcode.mogo.logger.Logger
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant
import com.mogo.eagle.core.widget.RoundConstraintLayout
import kotlinx.android.synthetic.main.view_camera_list.view.*
import kotlinx.android.synthetic.main.view_driver_monitor.view.*
/**
@@ -79,12 +78,7 @@ class DriverMonitorView :
textureViewDriverMonitor.isOpaque = false
liveStreamManager.setLiveStatusChangeCallback {
textureView
.post {
handleSnLiveStatus(it)
}
}
liveStreamManager.setLivePushStatusChangeCallback { }
// TODO SOP演示需求只有乘客屏幕才会触发这个逻辑 begin
// 测试数据
@@ -116,26 +110,26 @@ class DriverMonitorView :
fun showLive() {
if (!isLived) {
sopShowDriverMap[CallerTelematicManager.getServerToken()]?.let {
Logger.d(
"${SceneConstant.M_HMI}$TAG",
"检查司机直播……isLived=$isLived 当前车上的司机端SN=${sopShowDriverMap[CallerTelematicManager.getServerToken()]}"
)
CallerLogger.d(
"${SceneConstant.M_HMI}$TAG",
"检查司机直播……isLived=$isLived 当前车上的司机端SN=${sopShowDriverMap[CallerTelematicManager.getServerToken()]}"
)
MoGoAiCloudTrafficLive.viewDesignativeVehicleLive(
it,
textureViewDriverMonitor,
carLiveCallBack
)
}
// MoGoAiCloudTrafficLive.viewDesignativeVehicleLive(
// "F803EB2046PZD00190",
// textureViewDriverMonitor,
// carLiveCallBack
// )
// sopShowDriverMap[CallerTelematicManager.getServerToken()]?.let {
// Logger.d(
// "${SceneConstant.M_HMI}$TAG",
// "检查司机直播……isLived=$isLived 当前车上的司机端SN=${sopShowDriverMap[CallerTelematicManager.getServerToken()]}"
// )
// CallerLogger.d(
// "${SceneConstant.M_HMI}$TAG",
// "检查司机直播……isLived=$isLived 当前车上的司机端SN=${sopShowDriverMap[CallerTelematicManager.getServerToken()]}"
// )
// MoGoAiCloudTrafficLive.viewDesignativeVehicleLive(
// it,
// textureViewDriverMonitor,
// carLiveCallBack
// )
// }
MoGoAiCloudTrafficLive.viewDesignativeVehicleLive(
"F803EB2046PZD00164",
textureViewDriverMonitor,
carLiveCallBack
)
}
}
@@ -151,32 +145,10 @@ class DriverMonitorView :
}
}
private fun handleSnLiveStatus(status: Int) {
when (status) {
0 -> {// 正在直播
isLived = true
}
1 -> {// 直播已停止
isLived = false
}
2 -> {// 直播强制结束
isLived = false
}
}
refreshView(isLived)
Logger.d("${SceneConstant.M_HMI}$TAG", "isLived:$isLived")
CallerLogger.d("${SceneConstant.M_HMI}$TAG", "isLived:$isLived")
}
private val carLiveCallBack = object : ITrafficCarLiveCallBack {
override fun onLive(liveSn: String?) {
Logger.d("${SceneConstant.M_HMI}$TAG", "onLive:$liveSn")
CallerLogger.d("${SceneConstant.M_HMI}$TAG", "onLive:$liveSn")
isLived = true
refreshView(isLived)
}
override fun onFirstFrame() {
@@ -199,6 +171,18 @@ class DriverMonitorView :
isLived = false
refreshView(isLived)
}
override fun onPlaying() {
Logger.e("${SceneConstant.M_HMI}$TAG", "onPlaying……")
isLived = true
refreshView(isLived)
}
override fun onPlaRequesting() {
Logger.e("${SceneConstant.M_HMI}$TAG", "onPlaRequesting……")
isLived = false
refreshView(isLived)
}
}
}

View File

@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<rotate xmlns:android="http://schemas.android.com/apk/res/android"
android:fromDegrees="0"
android:pivotX="50%"
android:pivotY="50%"
android:toDegrees="360"
android:drawable="@drawable/icon_loading_live">
</rotate>

View File

@@ -3,7 +3,6 @@
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/rclContainer"
android:layout_width="match_parent"
android:background="#FFF"
android:layout_height="match_parent"
app:roundLayoutRadius="24dp">
@@ -11,17 +10,18 @@
android:id="@+id/ivNormal"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@drawable/bus_picture_nor"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<!--摄像头数据需要两种播放方式-->
<TextureView
android:id="@+id/textureViewDriverMonitor"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
@@ -31,7 +31,11 @@
android:id="@+id/liveProgressBar"
android:layout_width="90dp"
android:layout_height="90dp"
android:indeterminateDrawable="@drawable/icon_loading_live"
android:indeterminate="true"
android:indeterminateBehavior="repeat"
android:indeterminateDuration="2000"
android:indeterminateDrawable="@anim/progressbar_drawable"
android:indeterminateOnly="true"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
@@ -41,7 +45,7 @@
android:id="@+id/tvLoadingHit"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="44dp"
android:layout_marginTop="24dp"
android:text="加载中……"
android:textColor="#2D3E5F"
android:textSize="28dp"

View File

@@ -66,23 +66,23 @@ bytex.ASM_API=ASM7
LOGLIB_VERSION=1.5.26
######## MogoAiCloudSDK Version ########
# 网络请求LOGLIB_VERSION
MOGO_NETWORK_VERSION=1.4.6.4
MOGO_NETWORK_VERSION=1.4.6.7
# 鉴权
MOGO_PASSPORT_VERSION=1.4.6.4
MOGO_PASSPORT_VERSION=1.4.6.7
# 常链接
MOGO_SOCKET_VERSION=1.4.6.4
MOGO_SOCKET_VERSION=1.4.6.7
# 数据采集
MOGO_REALTIME_VERSION=1.4.6.4
MOGO_REALTIME_VERSION=1.4.6.7
# 探路,道路事件发布,获取
MOGO_TANLU_VERSION=1.4.6.4
MOGO_TANLU_VERSION=1.4.6.7
# 直播推流
MOGO_LIVE_VERSION=1.4.6.4
MOGO_LIVE_VERSION=1.4.6.7
# 直播拉流
MOGO_TRAFFICLIVE_VERSION=1.4.6.4
MOGO_TRAFFICLIVE_VERSION=1.4.6.7
# 定位服务
MOGO_LOCATION_VERSION=1.4.6.4
MOGO_LOCATION_VERSION=1.4.6.7
# 远程通讯模块
MOGO_TELEMATIC_VERSION=1.4.6.4
MOGO_TELEMATIC_VERSION=1.4.6.7
######## MogoAiCloudSDK Version ########
# 自研地图
MAP_SDK_VERSION=2.12.0.11