Implement skip for ig elevation

This commit is contained in:
kaetemi 2014-02-08 22:54:25 +01:00
parent bd335d80c4
commit f085e226c6

View file

@ -54,7 +54,23 @@ mkPath(log, configDir)
def igElevation(inputIgDir, outputIgDir):
printLog(log, ">>> IG Elevation <<<")
needUpdateIg = needUpdateDirByTagLog(log, inputIgDir, ".ig", outputIgDir, ".ig")
if needUpdateIg:
printLog(log, "DETECT UPDATE IG->Elevated")
else:
printLog(log, "DETECT SKIP IG->Elevated")
needUpdateHeightMap = needUpdateFileDirNoSubdir(log, DatabaseDirectory + "/" + LigoBaseSourceDirectory + "/" + LigoExportHeightmap1, outputIgDir) or needUpdateFileDirNoSubdir(log, DatabaseDirectory + "/" + LigoBaseSourceDirectory + "/" + LigoExportHeightmap2, outputIgDir)
if needUpdateHeightMap:
printLog(log, "DETECT UPDATE HeightMap->Elevated")
else:
printLog(log, "DETECT SKIP HeightMap->Elevated")
needUpdateLand = needUpdateFileDirNoSubdir(log, DatabaseDirectory + "/" + LigoBaseSourceDirectory + "/" + LigoExportLand, outputIgDir)
if needUpdateLand:
printLog(log, "DETECT UPDATE Land->Elevated")
else:
printLog(log, "DETECT SKIP Land->Elevated")
if needUpdateIg or needUpdateHeightMap or needUpdateLand:
printLog(log, "DETECT DECIDE UPDATE")
mkPath(log, inputIgDir)
mkPath(log, outputIgDir)
mkPath(log, DatabaseDirectory + "/" + LigoBaseSourceDirectory)
@ -83,6 +99,12 @@ def igElevation(inputIgDir, outputIgDir):
subprocess.call([ IgElevation, configFile ])
os.remove(configFile)
# Copy remaining IG files
copyFilesLogless(log, inputIgDir, outputIgDir)
else:
printLog(log, "DETECT DECIDE SKIP")
printLog(log, "SKIP *")
# Build process
if (ContinentLeveldesignWorldDirectory != "") or (len(IgOtherSourceDirectories) > 0):
printLog(log, ">>> Prim IG: ON <<<")
@ -135,7 +157,6 @@ if (ContinentLeveldesignWorldDirectory != "") or (len(IgOtherSourceDirectories)
igElevation(ExportBuildDirectory + "/" + IgStaticLandExportDirectory, ExportBuildDirectory + "/" + IgElevLandStaticBuildDirectory)
printLog(log, ">>> Merge land IGs <<<")
mkPath(log, ExportBuildDirectory + "/" + IgTempLandMergeBuildDirectory)
removeFilesRecursive(log, ExportBuildDirectory + "/" + IgTempLandMergeBuildDirectory)