|
@@ -291,22 +291,20 @@ public class SceneUpgradeToV4Service implements ISceneUpgradeToV4Service {
|
|
|
this.copyFileOss(num, completeCnt, count, voiceKeys, voicePath, voiceViewPath);
|
|
|
|
|
|
|
|
|
-
|
|
|
- String imagesCachePath = "/mnt/4Dkankan/scene/" + num;
|
|
|
+ //将全景图缓存到缓存目录
|
|
|
+ List<String> imagesList = cn.hutool.core.io.FileUtil.listFileNames(path + "/caches/images");
|
|
|
+ String cachedImagesPath = String.format(ConstantFilePath.SCENE_CACHE_IMAGES, num);
|
|
|
String visionPath = path + "/results/vision.txt";
|
|
|
List<String> panoramaImageList = SceneUtil.getPanoramaImageList(visionPath);
|
|
|
- //全景图上传
|
|
|
- Map<String, String> map = new HashMap<>();
|
|
|
- String sceneNumPAth = String.format("scene/%s", num);
|
|
|
- List<String> imagesList = FileUtil.getFileList(path + "/caches/images");
|
|
|
- imagesList.stream().forEach(srcPath -> {
|
|
|
- if(panoramaImageList.contains(srcPath)){
|
|
|
- cn.hutool.core.io.FileUtil.copy(srcPath, srcPath.replace(path, imagesCachePath), true);
|
|
|
+ imagesList.stream().forEach(fileName -> {
|
|
|
+ if(panoramaImageList.contains(fileName)){
|
|
|
+ String srcPath = path + "/caches/images/" + fileName;
|
|
|
+ String targetPath = cachedImagesPath + fileName;
|
|
|
+ log.info("源文件:{}, 目标文件:{}", srcPath, targetPath);
|
|
|
+ cn.hutool.core.io.FileUtil.copy(srcPath, targetPath, true);
|
|
|
}
|
|
|
});
|
|
|
|
|
|
-
|
|
|
-
|
|
|
// if(CollUtil.isNotEmpty(imagesList)){
|
|
|
// imagesList.stream().forEach(str -> {
|
|
|
// String filePath = str.substring(str.lastIndexOf(File.separator) + 1);
|