|
@@ -211,6 +211,7 @@ public class HouseController extends BaseController {
|
|
HashMap<String, String> ossVerticalImageLowMap = new HashMap<>();
|
|
HashMap<String, String> ossVerticalImageLowMap = new HashMap<>();
|
|
String imageHighPath = null;
|
|
String imageHighPath = null;
|
|
String imageLowPath = null;
|
|
String imageLowPath = null;
|
|
|
|
+ ImageResolutionRate maxTotalResolutionRate = null;
|
|
for (String filename : fileNames) {
|
|
for (String filename : fileNames) {
|
|
JSONObject jsonObject = JSON.parseObject(filename);
|
|
JSONObject jsonObject = JSON.parseObject(filename);
|
|
if(null == jsonObject){
|
|
if(null == jsonObject){
|
|
@@ -276,7 +277,13 @@ public class HouseController extends BaseController {
|
|
}
|
|
}
|
|
ImageResolutionRate maxResolutionRate = ImageResolutionRate.getResolutionRateByRate(totalResolutinRate);
|
|
ImageResolutionRate maxResolutionRate = ImageResolutionRate.getResolutionRateByRate(totalResolutinRate);
|
|
log.info("照片{}的像素为:{}" , newFilePath , totalResolutinRate);
|
|
log.info("照片{}的像素为:{}" , newFilePath , totalResolutinRate);
|
|
-
|
|
|
|
|
|
+ if(null == maxTotalResolutionRate){
|
|
|
|
+ maxTotalResolutionRate = maxResolutionRate;
|
|
|
|
+ }else{
|
|
|
|
+ if(null != maxResolutionRate && maxResolutionRate.getRate() > maxTotalResolutionRate.getRate()){
|
|
|
|
+ maxTotalResolutionRate = maxResolutionRate;
|
|
|
|
+ }
|
|
|
|
+ }
|
|
addNewImage(param.getId() , newFileName , newFilePath , ossVerticalLowPath, maxResolutionRate);
|
|
addNewImage(param.getId() , newFileName , newFilePath , ossVerticalLowPath, maxResolutionRate);
|
|
// 封装垂直校验后的图片到信息到oss,key为照片在本地的路径,value为照片在oss中的目录路径
|
|
// 封装垂直校验后的图片到信息到oss,key为照片在本地的路径,value为照片在oss中的目录路径
|
|
//给四维看看的前端加载使用
|
|
//给四维看看的前端加载使用
|
|
@@ -285,7 +292,9 @@ public class HouseController extends BaseController {
|
|
ossVerticalImageLowMap.put(imageLowPath, ossVerticalLowPath); //sketch用的,文件适中
|
|
ossVerticalImageLowMap.put(imageLowPath, ossVerticalLowPath); //sketch用的,文件适中
|
|
needSendMqMsg = true;
|
|
needSendMqMsg = true;
|
|
}
|
|
}
|
|
- insertScene(param.getImageMaxRate() , house);
|
|
|
|
|
|
+ String imageRateStr = null != maxTotalResolutionRate ? maxTotalResolutionRate.name() : "";
|
|
|
|
+ log.info("计算得到的照片最大分辨率为:{}" , imageRateStr);
|
|
|
|
+ insertScene(imageRateStr , house);
|
|
if (needSendMqMsg) {
|
|
if (needSendMqMsg) {
|
|
HashMap<Object, Object> mqMap = new HashMap<>();
|
|
HashMap<Object, Object> mqMap = new HashMap<>();
|
|
mqMap.put("ossImageHigh", ossVerticalImageHighMap);
|
|
mqMap.put("ossImageHigh", ossVerticalImageHighMap);
|