dmitrysenkovich

Untitled

Aug 27th, 2014
243
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Index: ExportSurface.cs
  2. ===================================================================
  3. --- ExportSurface.cs    (revision 6363)
  4. +++ ExportSurface.cs    (working copy)
  5. @@ -24,7 +24,7 @@
  6.  
  7.          public override bool RunImp(Task task, AppEnv appEnv, bool withChildren)
  8.          {
  9. -            string tempDir = appEnv.TempDir + @"export-surface\";
  10. +            string tempDir = appEnv.SurfaceTempDir;
  11.              string cutinDir = tempDir + @"rrr_and_airfields_cutin\";
  12.              string filterByPropertiesDir = tempDir + @"filter-by-properties-luas\";
  13.              string airfieldSurfaceDir = tempDir + @"airfield-surface\";
  14. @@ -48,10 +48,10 @@
  15.  
  16.              if (appEnv.terrainConfig.Lsa5)
  17.              {
  18. -                tempDir = appEnv.TempDir + @"export-lsa5\";
  19. +                string Lsa5TempDir = appEnv.TempDir + @"export-lsa5\";
  20.  
  21.                  // apply-surface-types & merge
  22. -                string mergedsurface = tempDir + @"merged_surface.ofsh";
  23. +                string mergedsurface = Lsa5TempDir + @"merged_surface.ofsh";
  24.                  {
  25.                      List<string> surfaceMeshes = new List<string>();
  26.  
  27. @@ -59,7 +59,7 @@
  28.                      foreach (var surface in surfaceL0_)
  29.                      {
  30.                          string surfaceFile = surface.FilenameNoExtension();
  31. -                        string surfaceFileRenamed = tempDir + surfaceFile + ".ofsh";
  32. +                        string surfaceFileRenamed = Lsa5TempDir + surfaceFile + ".ofsh";
  33.  
  34.                          command = new Command();
  35.                          command.EdtuCommand = "apply-surface-types";
  36. @@ -74,7 +74,7 @@
  37.                      foreach (var airfield in airfields)
  38.                      {
  39.                          string airfieldFile = airfield.FilenameNoExtension();
  40. -                        string airfieldFileRenamed = tempDir + airfieldFile + ".ofsh";
  41. +                        string airfieldFileRenamed = Lsa5TempDir + airfieldFile + ".ofsh";
  42.  
  43.                          command = new Command();
  44.                          command.EdtuCommand = "apply-surface-types";
  45. @@ -91,8 +91,8 @@
  46.  
  47.  
  48.                  // link-vector-data
  49. -                string mergedvectordata = tempDir + @"merged_vectordata.ofsh";
  50. -                string linkedvectordata = tempDir + @"merged_vectordata.lnkd";
  51. +                string mergedvectordata = Lsa5TempDir + @"merged_vectordata.ofsh";
  52. +                string linkedvectordata = Lsa5TempDir + @"merged_vectordata.lnkd";
  53.                  {
  54.                      string[] vectordata = PathsFromCategory(appEnv, Project.VECTOR_DATA_5_CATEGORY);
  55.                      command = MergeOffshoresCommand(vectordata, mergedvectordata);
  56. @@ -104,12 +104,12 @@
  57.                                   + linkedvectordata.Enclose() + " "
  58.                                   + "-staticmesh " + mergedsurface.Enclose() + " "
  59.                                   + "-terrain " + AppEnv.Instance.terrainConfig.TerrainCfg.Enclose();
  60. -                    command.ErrorsFile = tempDir + @"link-vector-data_errors.ofsh"; ;
  61. +                    command.ErrorsFile = Lsa5TempDir + @"link-vector-data_errors.ofsh"; ;
  62.                      task.AddCommand(command);
  63.                  }
  64.  
  65.                  // build-lsa5
  66. -                string lsa5filename = tempDir + @"surface.lsa5";
  67. +                string lsa5filename = Lsa5TempDir + @"surface.lsa5";
  68.                  {
  69.                      command = new Command();
  70.                      command.EdtuCommand = "build-lsa5";
  71. @@ -117,7 +117,7 @@
  72.                                   + linkedvectordata.Enclose() + " "
  73.                                   + lsa5filename.Enclose() + " "
  74.                                   + "-terrain " + AppEnv.Instance.terrainConfig.TerrainCfg.Enclose();
  75. -                    command.ErrorsFile = tempDir + @"build-lsa5_errors.ofsh"; ;
  76. +                    command.ErrorsFile = Lsa5TempDir + @"build-lsa5_errors.ofsh"; ;
  77.                      task.AddCommand(command);
  78.                  }
  79.  
  80. @@ -127,9 +127,9 @@
  81.                      command.Type = Command.CommandType.EDTU4;
  82.                      command.EdtuCommand = "export-vector-data";
  83.                      command.Args = linkedvectordata.Enclose() + " "
  84. -                                   + (tempDir + @"vectordata_view.ofsh").Enclose()
  85. +                                   + (Lsa5TempDir + @"vectordata_view.ofsh").Enclose()
  86.                                     + " -terrain " + AppEnv.Instance.terrainConfig.TerrainCfg.Enclose();
  87. -                    command.ErrorsFile = tempDir + @"export-vector-data_errors.ofsh";
  88. +                    command.ErrorsFile = Lsa5TempDir + @"export-vector-data_errors.ofsh";
  89.                      task.AddCommand(command);
  90.                  }
  91.  
  92. @@ -142,7 +142,7 @@
  93.                  command.Args = lsa5filename.Enclose() + " "
  94.                               + lsa4filename.Enclose() + " "
  95.                               + "-terrain " + AppEnv.Instance.terrainConfig.TerrainCfg.Enclose();
  96. -                command.ErrorsFile = tempDir + @"lsa5-lsa4_errors.ofsh"; ;
  97. +                command.ErrorsFile = Lsa5TempDir + @"lsa5-lsa4_errors.ofsh"; ;
  98.                  task.AddCommand(command);
  99.  
  100.                  return true;
  101. @@ -152,7 +152,6 @@
  102.              {
  103.                  string seaMaterial = "Sea4.1";
  104.  
  105. -                tempDir = appEnv.TempDir + @"export-lsa4-with-vector-data-5\";
  106.                  System.IO.Directory.CreateDirectory(tempDir);
  107.                  Tools.Path.CleanupDir(tempDir);
  108.                  // apply-surface-types & merge
  109. @@ -252,7 +251,7 @@
  110.                  }
  111.  
  112.                  // build-surface-by-vector-data-5
  113. -                string surfaceL0_1 = tempDir + @"surface-L0.ofsh";
  114. +                string surfaceL0_1 = appEnv.SurfaceL0Output;
  115.                  string outputReflectReceiver = appEnv.ReflectReceiverScene;
  116.                  {
  117.                      command = new Command();
  118. @@ -562,7 +561,7 @@
  119.                  command = MergeOffshoresCommand(cutbysquares.ToArray(), mergedfilename);
  120.                  task.AddCommand(command);
  121.  
  122. -                var surfaceL0filename = tempDir + "surfaceL0.ofsh";
  123. +                var surfaceL0filename = appEnv.SurfaceL0Output;
  124.                  var mergedL0filename = tempDir + "mergedL0.ofsh";
  125.                  var finalL0filename = tempDir + "finalL0.ofsh";
  126.                  var cutL0filename = tempDir + "cutL0.ofsh";
Advertisement
Add Comment
Please, Sign In to add comment