|
|
@@ -180,10 +180,10 @@ public class SoundCompareHandler implements WebSocketEventHandler {
|
|
|
createHeader(phone, false);
|
|
|
break;
|
|
|
case SoundSocketService.PROXY_MESSAGE:
|
|
|
- if(DeviceTypeEnum.IOS.equals(userSoundInfoMap.get(phone).getDeviceType())&&bodyObject.containsKey(SoundSocketService.OFFSET_TIME)){
|
|
|
- int offsetTime = bodyObject.getIntValue(SoundSocketService.OFFSET_TIME);
|
|
|
- calOffsetTime(phone, offsetTime);
|
|
|
- }
|
|
|
+// if(DeviceTypeEnum.IOS.equals(userSoundInfoMap.get(phone).getDeviceType())&&bodyObject.containsKey(SoundSocketService.OFFSET_TIME)){
|
|
|
+// int offsetTime = bodyObject.getIntValue(SoundSocketService.OFFSET_TIME);
|
|
|
+// calOffsetTime(phone, offsetTime);
|
|
|
+// }
|
|
|
break;
|
|
|
case VIDEO_UPDATE:
|
|
|
if(bodyObject.containsKey("filePath")){
|
|
|
@@ -354,7 +354,7 @@ public class SoundCompareHandler implements WebSocketEventHandler {
|
|
|
int startTimeStamp = musicXmlInfo.getTimeStamp();
|
|
|
int endTimeStamp = musicXmlInfo.getTimeStamp() + musicXmlInfo.getDuration();
|
|
|
|
|
|
- int ot5 = (int) (musicXmlInfo.getDuration()*0.3);
|
|
|
+ int ot5 = (int) (musicXmlInfo.getDuration()*0.23);
|
|
|
|
|
|
List<MusicPitchDetailDto> recordPitchs = userSoundInfoMap.get(phone).getRecordMeasurePitchInfos().stream().filter(m -> m.getTimeStamp()>=startTimeStamp-ot5 && m.getTimeStamp() < endTimeStamp-ot5).collect(Collectors.toList());
|
|
|
|
|
|
@@ -368,7 +368,7 @@ public class SoundCompareHandler implements WebSocketEventHandler {
|
|
|
}
|
|
|
integrityDuty = scoreMapping(integrityDuty, userSoundInfoMap.get(phone).getHeardLevel().getIntegrityRange(), 1);
|
|
|
//节奏
|
|
|
- if(recordPitchs.size()>0&&(Math.abs(recordPitchs.get(0).getTimeStamp()-startTimeStamp)<ot5)&&(recordPitchs.size()<2)){
|
|
|
+ if(recordPitchs.size()==1){
|
|
|
cadenceNum++;
|
|
|
cadenceRight = true;
|
|
|
}
|