mirror of
https://github.com/Alex38Lyon/Synthese-PSM_LARRA.git
synced 2026-06-01 13:59:13 +00:00
pyCreateTh
This commit is contained in:
Binary file not shown.
Binary file not shown.
@@ -199,12 +199,16 @@ def read_config(config_file):
|
||||
|
||||
if global_data.linesInTh2 == -1 :
|
||||
if 'Application_Data' in config and 'shot_lines_in_th2_files' in config['Application_Data']:
|
||||
linesInTh2 = 0 if config['Application_Data']['shot_lines_in_th2_files'] == "False" else 1
|
||||
global_data.linesInTh2 = 0 if config['Application_Data']['shot_lines_in_th2_files'] == "False" else 1
|
||||
|
||||
if global_data.stationNamesInTh2 == -1 :
|
||||
if 'Application_Data' in config and 'station_name_in_th2_files' in config['Application_Data']:
|
||||
global_data.stationNamesInTh2 = 0 if config['Application_Data']['station_name_in_th2_files'] == "False" else 1
|
||||
|
||||
|
||||
if global_data.wallLineInTh2 == -1 :
|
||||
if 'Application_Data' in config and 'wall_lines_in_th2_files' in config['Application_Data']:
|
||||
global_data.wallLineInTh2 = 0 if config['Application_Data']['wall_lines_in_th2_files'] == "False" else 1
|
||||
|
||||
|
||||
#################################################################################################
|
||||
# Supprime les codes ANSI (pour l'écriture dans les fichiers)
|
||||
|
||||
@@ -28,6 +28,7 @@ therionPath = "C:/Therion/therion.exe"
|
||||
SurveyPrefixName = f"Survey_"
|
||||
linesInTh2 = -1
|
||||
stationNamesInTh2 = -1
|
||||
wallLineInTh2 = -1
|
||||
|
||||
|
||||
#################################################################################################
|
||||
@@ -73,6 +74,7 @@ endsurvey
|
||||
{SOURCE}
|
||||
"""
|
||||
|
||||
|
||||
#################################################################################################
|
||||
thconfigTemplate = """
|
||||
source "{th_file}"
|
||||
@@ -87,12 +89,13 @@ export map -projection plan -o "{th_name}-Plan.xvi" -layout minimal -layout-debu
|
||||
export map -projection extended -o "{th_name}-Extended.xvi" -layout minimal -layout-debug station-names
|
||||
"""
|
||||
|
||||
|
||||
#################################################################################################
|
||||
th2FileHeader = """encoding utf-8"""
|
||||
|
||||
th2File = """
|
||||
##XTHERION## xth_me_area_adjust {X_Min} {Y_Min} {X_Max} {Y_Max}
|
||||
##XTHERION## xth_me_area_zoom_to 100
|
||||
##XTHERION## xth_me_area_zoom_to 25
|
||||
##XTHERION## xth_me_image_insert {insert_XVI}
|
||||
|
||||
{Copyright}
|
||||
@@ -103,25 +106,27 @@ th2File = """
|
||||
|
||||
scrap S{projection_short}-{name}_01 -station-names "" "@{name}" -projection {projection} -author {year} "{author}" -copyright {year} "{Copyright_Short}"
|
||||
|
||||
{points}
|
||||
|
||||
{names}
|
||||
|
||||
{names}
|
||||
{lines}
|
||||
{walls}
|
||||
|
||||
{points}
|
||||
|
||||
endscrap
|
||||
"""
|
||||
|
||||
th2Point = """ point {x} {y} station -name {station}"""
|
||||
th2Name = """ point {x} {y} station-name -align tr -scale xs -text {station}"""
|
||||
th2Point = """\tpoint {x} {y} station -name {station}"""
|
||||
th2Name = """\tpoint {x} {y} station-name -align tr -scale xs -text {station}"""
|
||||
|
||||
th2Line = """
|
||||
line u:Shot_Survey
|
||||
{x1} {y1}
|
||||
{x2} {y2}
|
||||
\t{x1} {y1}
|
||||
\t{x2} {y2}
|
||||
endline
|
||||
"""
|
||||
|
||||
th2wall = """{list}"""
|
||||
|
||||
th2Scrap = """
|
||||
|
||||
scrap S{projection_short}-{name}_{num:02} -station-names "" "@{name}" -projection {projection} -author {year} "{author}" -copyright {year} "{Copyright_Short}"
|
||||
@@ -129,6 +134,7 @@ scrap S{projection_short}-{name}_{num:02} -station-names "" "@{name}" -projectio
|
||||
endscrap
|
||||
"""
|
||||
|
||||
|
||||
#################################################################################################
|
||||
datumToEPSG = {
|
||||
# Datums globaux
|
||||
|
||||
Reference in New Issue
Block a user