|
|
@@ -186,7 +186,10 @@ public class SceneProServiceImpl extends ServiceImpl<ISceneProMapper, ScenePro>
|
|
|
// String fragmentCmd = "docker run --rm --security-opt seccomp=unconfined --pids-limit=4096 -v /mnt:/mnt vips:8.15.1 vips copy " + origFilePath + "[autorot] " +workPath;
|
|
|
// String fragmentCmd = "docker run --rm --security-opt seccomp=unconfined --pids-limit=4096 -v /mnt:/mnt vips:8.15.1 vips dzsave --tile-size " + tileSize + " " + origFilePath + "[autorot] " + workPath;
|
|
|
// String fragmentCmd = "vips dzsave " + origFilePath + "[autorot] " + workPath + " --tile-size " + tileSize + " --strip";
|
|
|
- String fragmentCmd = "docker run --rm --security-opt seccomp=unconfined --pids-limit=4096 -v /mnt:/mnt vips:8.15.1 vips dzsave --tile-size " + tileSize + " " + origFilePath + " " + workPath;
|
|
|
+ String tempFilePath = workPath + "/temp_rotated.v";
|
|
|
+ String autorotCmd = "docker run --rm --security-opt seccomp=unconfined --pids-limit=4096 -v /mnt:/mnt vips:8.15.1 vips autorot " + origFilePath + " " + tempFilePath;
|
|
|
+ CmdUtils.callLine(autorotCmd);
|
|
|
+ String fragmentCmd = "docker run --rm --security-opt seccomp=unconfined --pids-limit=4096 -v /mnt:/mnt vips:8.15.1 vips dzsave --tile-size " + tileSize + " " + tempFilePath + " " + workPath;
|
|
|
log.info("fragmentCmd:{}" + fragmentCmd);
|
|
|
CmdUtils.callLine(fragmentCmd);
|
|
|
if(!ComputerUtil.checkComputeCompleted(dziPath, 5, 200)){
|
|
|
@@ -226,9 +229,9 @@ public class SceneProServiceImpl extends ServiceImpl<ISceneProMapper, ScenePro>
|
|
|
fYunFileService.uploadFile(origFilePath, ossPath + sid + "." + extName);
|
|
|
|
|
|
}finally {
|
|
|
- FileUtil.del(workPath);
|
|
|
- FileUtil.del(dziPath);
|
|
|
- FileUtil.del(outFilesPath);
|
|
|
+// FileUtil.del(workPath);
|
|
|
+// FileUtil.del(dziPath);
|
|
|
+// FileUtil.del(outFilesPath);
|
|
|
}
|
|
|
|
|
|
Map<String, Object> hw = new HashMap<>();
|