tcp发送增加ar视频播放帧数&首页布局还原到初版

This commit is contained in:
lishuo committed 2022-04-20 17:32:27 +08:00
1 parent 3532978762
commit 4a3542010f
18 files changed
+1937 -1788

No files matched your search

@@ -105,7 +105,7 @@ namespace Assets.Scenes.Ride.Scripts.Model.CyclingModels
MapUDPService.Send(route.RouteInstance.Id, recorderData.BelongUserId,
new double[] { lastData._Lat, lastData._Lon },
recorderData.IsCompleted, false, recorderData.EndDistance,
true, 1, lastData._Speed, false, preDistance, weightKg, competitionId: recorderData.Competitionid, recorderData.Saved, 0, lastData._Power, lastData._Cadence, lastData.Ticks);
true, 1, lastData._Speed, false, preDistance, weightKg, competitionId: recorderData.Competitionid, recorderData.Saved, 0, lastData._Power, lastData._Cadence, lastData.Ticks, (lastData._FrameRate??0));
}
else if (recorderData.EndDistance > 0)//没有骑,但是有初始位置的情况
{
@@ -80,6 +80,7 @@ namespace Assets.Scenes.Ride.Scripts.Model.CyclingModels
EndDistance = item.EndDistance,
PreDistance = item.PreDistance,
WeightKg = item.WeightKg,
FrameRate = item.FrameRate,
});
}
+7 -1
View File
@@ -376,6 +376,8 @@ namespace Assets.Scenes.Ride.Scripts.Model
public bool Saved { get; set; }
//public int V { get; set; }
public int FrameRate { get; set; }
}
public class GzipMsgModel
@@ -436,11 +438,12 @@ namespace Assets.Scenes.Ride.Scripts.Model
public string WatchIdList { get; set; }
public int? FrameRate { get; set; }
public static ReceiveMsgModel Parse(string str)
{
var list = str.Split(',');
if (list.Length != 14)
if (list.Length != 15)
{
return null;
}
@@ -464,6 +467,7 @@ namespace Assets.Scenes.Ride.Scripts.Model
HeartRate = Convert.ToDouble(list[11], CultureInfo.InvariantCulture),
Cadence = Convert.ToDouble(list[12], CultureInfo.InvariantCulture),
TotoalTicks = Convert.ToInt32(list[13], CultureInfo.InvariantCulture),
FrameRate = Convert.ToInt32(list[14], CultureInfo.InvariantCulture),
};
}
catch
@@ -595,6 +599,8 @@ namespace Assets.Scenes.Ride.Scripts.Model
public string Country { get; set; }
public DateTime CreateTime { get; set; }
public int? FrameRate { get; set; }
}
public class KeyPaire
@@ -19,6 +19,8 @@ namespace Assets.Scenes.Ride.Scripts.Model.RiderModels
/// </summary>
public GeographicPosition Point { get; set; }
public int? FrameRate { get; set; } = 0;
public OutUser GetOutUser(double preDistance, double currentDistance, TurfHelper turfHelper, CyclingStateEnum cyclingState)
{
if (this.IsSelf)
@@ -34,6 +34,9 @@ namespace Assets.Scenes.Ride.Scripts.Model
//public double _Bearing = 0d;
//视频帧数
public int? _FrameRate = 0;
public TargetData Clone()
{
return (TargetData)MemberwiseClone();
@@ -207,7 +207,7 @@ namespace Assets.Scenes.Ride.Scripts
/// <param name="exit">是否退出</param>
public static void Send(int RouteId, int MemberId, double[] Point, bool IsCompleted = false, bool exit = false,
double endDistance = 0, bool showVirtual = false, byte commandType = 1, double speed = 0, bool isVirtual = false, double preDistance = 0,
double weightKg = 0, int competitionId = 0, bool saved = false,double? heartRate = 0, double power = 0, double? cadence = 0,int totalTicks = 0)
double weightKg = 0, int competitionId = 0, bool saved = false,double? heartRate = 0, double power = 0, double? cadence = 0,int totalTicks = 0, int frameRate = 0)
{
try
{
@@ -235,6 +235,7 @@ namespace Assets.Scenes.Ride.Scripts
WeightKg = weightKg,
Competitionid = competitionId,
Saved = saved,
FrameRate = frameRate
//V = 1
};
var sendBytes = Encoding.UTF8.GetBytes(Newtonsoft.Json.JsonConvert.SerializeObject(model));
@@ -491,6 +492,7 @@ namespace Assets.Scenes.Ride.Scripts
}
user.IsWatcher = user.WatcherList.Contains(item.MemberId);
user.CreateTime = DateTime.MaxValue;
user.FrameRate = item.FrameRate;
}
else
{