[Git][debian-gis-team/saga][upstream] New upstream version 9.7.2+dfsg
Bas Couwenberg (@sebastic)
gitlab at salsa.debian.org
Mon Jan 20 15:03:05 GMT 2025
Bas Couwenberg pushed to branch upstream at Debian GIS Project / saga
Commits:
a6a91b29 by Bas Couwenberg at 2025-01-20T15:31:16+01:00
New upstream version 9.7.2+dfsg
- - - - -
17 changed files:
- saga-gis/src/accessories/helper/doxygen_saga_api_chm
- saga-gis/src/accessories/helper/doxygen_saga_api_html
- saga-gis/src/accessories/helper/make_saga_release.bat
- saga-gis/src/accessories/helper/saga_setup_x64.iss
- saga-gis/src/accessories/python/tools/climate_tools.py
- saga-gis/src/accessories/python/tools/pj_proj4.py
- saga-gis/src/accessories/python/tools/ta_lighting.py
- saga-gis/src/saga_core/saga_api/geo_tools.h
- saga-gis/src/saga_core/saga_api/projections.cpp
- saga-gis/src/saga_core/saga_api/saga_api.h
- saga-gis/src/saga_core/saga_cmd/config.cpp
- saga-gis/src/saga_core/saga_cmd/man/saga_cmd.1
- saga-gis/src/saga_core/saga_gui/man/saga_gui.1
- saga-gis/src/saga_core/saga_gui/wksp_tool_manager.cpp
- saga-gis/src/tools/projection/pj_proj4/crs_definition.cpp
- saga-gis/src/tools/projection/pj_proj4/crs_definition.h
- saga-gis/version.cmake
Changes:
=====================================
saga-gis/src/accessories/helper/doxygen_saga_api_chm
=====================================
@@ -38,7 +38,7 @@ PROJECT_NAME = "SAGA API"
# could be handy for archiving the generated documentation or if some version
# control system is used.
-#PROJECT_NUMBER = v9.7.1 # omit patch number
+#PROJECT_NUMBER = v9.7.2 # omit patch number
PROJECT_NUMBER = v9.7
# Using the PROJECT_BRIEF tag one can provide an optional one line description
@@ -59,7 +59,7 @@ PROJECT_LOGO = ../../../saga_core/saga_gui/res/saga_icon_64.png
# entered, it will be relative to the location where doxygen was started. If
# left blank the current directory will be used.
-OUTPUT_DIRECTORY = saga-9.7.1_api_doc
+OUTPUT_DIRECTORY = saga-9.7.2_api_doc
# If the CREATE_SUBDIRS tag is set to YES then doxygen will create 4096 sub-
# directories (in 2 levels) under the output directory of each output format and
@@ -1372,7 +1372,7 @@ GENERATE_HTMLHELP = YES
# written to the html output directory.
# This tag requires that the tag GENERATE_HTMLHELP is set to YES.
-CHM_FILE = ../../saga-9.7.1_api.chm
+CHM_FILE = ../../saga-9.7.2_api.chm
# The HHC_LOCATION tag can be used to specify the location (absolute path
# including file name) of the HTML help compiler (hhc.exe). If non-empty,
=====================================
saga-gis/src/accessories/helper/doxygen_saga_api_html
=====================================
@@ -38,7 +38,7 @@ PROJECT_NAME = "SAGA API"
# could be handy for archiving the generated documentation or if some version
# control system is used.
-#PROJECT_NUMBER = v9.7.1 # omit patch number
+#PROJECT_NUMBER = v9.7.2 # omit patch number
PROJECT_NUMBER = v9.7
# Using the PROJECT_BRIEF tag one can provide an optional one line description
@@ -59,7 +59,7 @@ PROJECT_LOGO = ../../../saga_core/saga_gui/res/saga_icon_64.png
# entered, it will be relative to the location where doxygen was started. If
# left blank the current directory will be used.
-OUTPUT_DIRECTORY = saga-9.7.1_api_doc
+OUTPUT_DIRECTORY = saga-9.7.2_api_doc
# If the CREATE_SUBDIRS tag is set to YES then doxygen will create 4096 sub-
# directories (in 2 levels) under the output directory of each output format and
@@ -1372,7 +1372,7 @@ GENERATE_HTMLHELP = NO
# written to the html output directory.
# This tag requires that the tag GENERATE_HTMLHELP is set to YES.
-CHM_FILE = ../../saga-9.7.1_api.chm
+CHM_FILE = ../../saga-9.7.2_api.chm
# The HHC_LOCATION tag can be used to specify the location (absolute path
# including file name) of the HTML help compiler (hhc.exe). If non-empty,
=====================================
saga-gis/src/accessories/helper/make_saga_release.bat
=====================================
@@ -30,9 +30,9 @@ REM ___________________________________
REM Version
SET SAGA_VERSION=9.7
-SET SAGA_RELEASE=9.7.1
+SET SAGA_RELEASE=9.7.2
SET SAGA_VERSION_NEXT=9.7
-SET SAGA_RELEASE_NEXT=9.7.2
+SET SAGA_RELEASE_NEXT=9.7.3
SET SAGA_RELEASE_NAME=saga-%SAGA_RELEASE%
REM !!! For all bug-fix-releases !!!
=====================================
saga-gis/src/accessories/helper/saga_setup_x64.iss
=====================================
@@ -1,5 +1,5 @@
-; To build installer (for example, saga-9.7.1_setup.exe).
-; - Unzip the SAGA binary files in their own folder (for example, saga-9.7.1.zip).
+; To build installer (for example, saga-9.7.2_setup.exe).
+; - Unzip the SAGA binary files in their own folder (for example, saga-9.7.2.zip).
; - Place saga.iss and saga_readme.rtf in the SAGA folder (contains saga_gui.exe, etc.).
; - Open saga.iss in Inno Setup.
; - Choose Build | Compile.
@@ -7,7 +7,7 @@
[Setup]
AppName=SAGA - System for Automated Geoscientific Analyses
-AppVerName=SAGA 9.7.1
+AppVerName=SAGA 9.7.2
ArchitecturesAllowed=x64
ArchitecturesInstallIn64BitMode=x64
@@ -22,9 +22,9 @@ Compression=lzma
SolidCompression=yes
OutputDir=.
-OutputBaseFilename=saga-9.7.1_x64_setup
+OutputBaseFilename=saga-9.7.2_x64_setup
-VersionInfoVersion=9.7.1.0
+VersionInfoVersion=9.7.2.0
VersionInfoCompany=SAGA User Group Association
VersionInfoCopyright=(c) 2005-2023 by O. Conrad
VersionInfoDescription=SAGA single-file installer
@@ -51,5 +51,5 @@ Name: "{commondesktop}\SAGA"; Filename: "{app}\saga_gui.exe"; WorkingDir: "{app}
Root: HKLM; Subkey: "SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\saga_gui.exe"; ValueType: string; ValueName: ""; ValueData: "{app}\saga_gui.exe"; Flags: uninsdeletekey
Root: HKLM; Subkey: "SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\saga_gui.exe"; ValueType: string; ValueName: "Path"; ValueData: "{app}"
-Root: HKLM; Subkey: "SOFTWARE\SAGA User Group Association\SAGA\9.7.1"; ValueType: string; ValueName: "InstallDir"; ValueData: "{app}"; Flags: uninsdeletekey
-Root: HKLM; Subkey: "SOFTWARE\SAGA User Group Association\SAGA\9.7.1"; ValueType: string; ValueName: "Version"; ValueData: "9.7.1.0"
+Root: HKLM; Subkey: "SOFTWARE\SAGA User Group Association\SAGA\9.7.2"; ValueType: string; ValueName: "InstallDir"; ValueData: "{app}"; Flags: uninsdeletekey
+Root: HKLM; Subkey: "SOFTWARE\SAGA User Group Association\SAGA\9.7.2"; ValueType: string; ValueName: "Version"; ValueData: "9.7.2.0"
=====================================
saga-gis/src/accessories/python/tools/climate_tools.py
=====================================
@@ -618,7 +618,7 @@ def Evapotranspiration_Grid(T=None, T_MIN=None, T_MAX=None, RH=None, SR=None, WS
- SUNSHINE [`floating point number`] : Sunshine Duration. Minimum: 0.000000 Maximum: 100.000000 Default: 50.000000 Daily sunshine duration as percentage of its potential maximum.
- TIME [`choice`] : Time. Available Choices: [0] day [1] month Default: 0
- MONTH [`choice`] : Month. Available Choices: [0] January [1] February [2] March [3] April [4] May [5] June [6] July [7] August [8] September [9] October [10] November [11] December Default: 0
- - DAY [`integer number`] : Day of Month. Minimum: 1 Maximum: 31 Default: 8
+ - DAY [`integer number`] : Day of Month. Minimum: 1 Maximum: 31 Default: 20
- LAT [`floating point number`] : Latitude. Minimum: -90.000000 Maximum: 90.000000 Default: 53.000000 [Degree]
- Verbose [`integer number`] : Verbosity level, 0=silent, 1=tool name and success notification, 2=complete tool output.\n
@@ -681,7 +681,7 @@ def run_tool_climate_tools_8(T=None, T_MIN=None, T_MAX=None, RH=None, SR=None, W
- SUNSHINE [`floating point number`] : Sunshine Duration. Minimum: 0.000000 Maximum: 100.000000 Default: 50.000000 Daily sunshine duration as percentage of its potential maximum.
- TIME [`choice`] : Time. Available Choices: [0] day [1] month Default: 0
- MONTH [`choice`] : Month. Available Choices: [0] January [1] February [2] March [3] April [4] May [5] June [6] July [7] August [8] September [9] October [10] November [11] December Default: 0
- - DAY [`integer number`] : Day of Month. Minimum: 1 Maximum: 31 Default: 8
+ - DAY [`integer number`] : Day of Month. Minimum: 1 Maximum: 31 Default: 20
- LAT [`floating point number`] : Latitude. Minimum: -90.000000 Maximum: 90.000000 Default: 53.000000 [Degree]
- Verbose [`integer number`] : Verbosity level, 0=silent, 1=tool name and success notification, 2=complete tool output.\n
@@ -728,7 +728,7 @@ def Sunrise_and_Sunset(TARGET=None, SUNRISE=None, SUNSET=None, LENGTH=None, DAY=
- SUNRISE [`output grid`] : Sunrise
- SUNSET [`output grid`] : Sunset
- LENGTH [`output grid`] : Day Length
- - DAY [`date`] : Day of Month. Default: 2025-01-09
+ - DAY [`date`] : Day of Month. Default: 2025-01-20
- TIME [`choice`] : Time. Available Choices: [0] local [1] world Default: 0
- Verbose [`integer number`] : Verbosity level, 0=silent, 1=tool name and success notification, 2=complete tool output.\n
@@ -759,7 +759,7 @@ def run_tool_climate_tools_9(TARGET=None, SUNRISE=None, SUNSET=None, LENGTH=None
- SUNRISE [`output grid`] : Sunrise
- SUNSET [`output grid`] : Sunset
- LENGTH [`output grid`] : Day Length
- - DAY [`date`] : Day of Month. Default: 2025-01-09
+ - DAY [`date`] : Day of Month. Default: 2025-01-20
- TIME [`choice`] : Time. Available Choices: [0] local [1] world Default: 0
- Verbose [`integer number`] : Verbosity level, 0=silent, 1=tool name and success notification, 2=complete tool output.\n
@@ -1911,7 +1911,7 @@ def PhenIps_Grids_Days(ATMEAN=None, ATMAX=None, SIREL=None, LAT_GRID=None, GENER
- YD_END_ONSET [`date`] : End of Breeding. Default: 2025-08-31
- YD_END [`date`] : End of Development. Default: 2025-10-31
- RESET [`boolean`] : Reset. Default: 1
- - DAY [`date`] : Start Day. Default: 2025-01-09
+ - DAY [`date`] : Start Day. Default: 2025-01-20
- Verbose [`integer number`] : Verbosity level, 0=silent, 1=tool name and success notification, 2=complete tool output.\n
Returns
@@ -1998,7 +1998,7 @@ def run_tool_climate_tools_23(ATMEAN=None, ATMAX=None, SIREL=None, LAT_GRID=None
- YD_END_ONSET [`date`] : End of Breeding. Default: 2025-08-31
- YD_END [`date`] : End of Development. Default: 2025-10-31
- RESET [`boolean`] : Reset. Default: 1
- - DAY [`date`] : Start Day. Default: 2025-01-09
+ - DAY [`date`] : Start Day. Default: 2025-01-20
- Verbose [`integer number`] : Verbosity level, 0=silent, 1=tool name and success notification, 2=complete tool output.\n
Returns
@@ -2066,7 +2066,7 @@ def Soil_Water_Balance_Days(TAVG=None, TMIN=None, TMAX=None, PSUM=None, LAT_GRID
- SWC_SURFACE [`floating point number`] : Top Soil Water Capacity. Minimum: 0.000000 Default: 30.000000
- SWT_RESIST [`floating point number`] : Transpiration Resistance. Minimum: 0.010000 Default: 0.500000
- RESET [`boolean`] : Reset. Default: 1
- - DAY [`date`] : Start Day. Default: 2025-01-09
+ - DAY [`date`] : Start Day. Default: 2025-01-20
- Verbose [`integer number`] : Verbosity level, 0=silent, 1=tool name and success notification, 2=complete tool output.\n
Returns
@@ -2115,7 +2115,7 @@ def run_tool_climate_tools_24(TAVG=None, TMIN=None, TMAX=None, PSUM=None, LAT_GR
- SWC_SURFACE [`floating point number`] : Top Soil Water Capacity. Minimum: 0.000000 Default: 30.000000
- SWT_RESIST [`floating point number`] : Transpiration Resistance. Minimum: 0.010000 Default: 0.500000
- RESET [`boolean`] : Reset. Default: 1
- - DAY [`date`] : Start Day. Default: 2025-01-09
+ - DAY [`date`] : Start Day. Default: 2025-01-20
- Verbose [`integer number`] : Verbosity level, 0=silent, 1=tool name and success notification, 2=complete tool output.\n
Returns
@@ -2702,7 +2702,7 @@ def Daily_Solar_Radiation(LATITUDE=None, SOLARRAD=None, MONTH=None, DAY=None, SU
- LATITUDE [`input grid`] : Latitude. [Degree]
- SOLARRAD [`output grid`] : Solar Radiation. [J/cm²]
- MONTH [`choice`] : Month. Available Choices: [0] January [1] February [2] March [3] April [4] May [5] June [6] July [7] August [8] September [9] October [10] November [11] December Default: 0
- - DAY [`integer number`] : Day of Month. Minimum: 1 Maximum: 31 Default: 8
+ - DAY [`integer number`] : Day of Month. Minimum: 1 Maximum: 31 Default: 20
- SUNSHINE [`floating point number`] : Sunshine Duration. Minimum: 0.000000 Maximum: 100.000000 Default: 50.000000 Daily sunshine duration as percentage of its potential maximum.
- Verbose [`integer number`] : Verbosity level, 0=silent, 1=tool name and success notification, 2=complete tool output.\n
@@ -2732,7 +2732,7 @@ def run_tool_climate_tools_31(LATITUDE=None, SOLARRAD=None, MONTH=None, DAY=None
- LATITUDE [`input grid`] : Latitude. [Degree]
- SOLARRAD [`output grid`] : Solar Radiation. [J/cm²]
- MONTH [`choice`] : Month. Available Choices: [0] January [1] February [2] March [3] April [4] May [5] June [6] July [7] August [8] September [9] October [10] November [11] December Default: 0
- - DAY [`integer number`] : Day of Month. Minimum: 1 Maximum: 31 Default: 8
+ - DAY [`integer number`] : Day of Month. Minimum: 1 Maximum: 31 Default: 20
- SUNSHINE [`floating point number`] : Sunshine Duration. Minimum: 0.000000 Maximum: 100.000000 Default: 50.000000 Daily sunshine duration as percentage of its potential maximum.
- Verbose [`integer number`] : Verbosity level, 0=silent, 1=tool name and success notification, 2=complete tool output.\n
=====================================
saga-gis/src/accessories/python/tools/pj_proj4.py
=====================================
@@ -979,7 +979,7 @@ def Coordinate_Reference_System_Format_Conversion(FORMATS=None, DEFINITION=None,
Arguments
----------
- FORMATS [`output table`] : Formats
- - DEFINITION [`text`] : Definition. Default: epsg:4326
+ - DEFINITION [`text`] : Definition
- FORMAT [`choice`] : Format. Available Choices: [0] PROJ [1] WKT-1 [2] WKT-2 [3] JSON [4] ESRI [5] all [6] PROJ + WKT-2 Default: 6
- MULTILINE [`boolean`] : Multiline. Default: 1 applies to JSON and WKT
- SIMPLIFIED [`boolean`] : Simplified. Default: 1 applies to WKT-2
@@ -1016,7 +1016,7 @@ def run_tool_pj_proj4_19(FORMATS=None, DEFINITION=None, FORMAT=None, MULTILINE=N
Arguments
----------
- FORMATS [`output table`] : Formats
- - DEFINITION [`text`] : Definition. Default: epsg:4326
+ - DEFINITION [`text`] : Definition
- FORMAT [`choice`] : Format. Available Choices: [0] PROJ [1] WKT-1 [2] WKT-2 [3] JSON [4] ESRI [5] all [6] PROJ + WKT-2 Default: 6
- MULTILINE [`boolean`] : Multiline. Default: 1 applies to JSON and WKT
- SIMPLIFIED [`boolean`] : Simplified. Default: 1 applies to WKT-2
=====================================
saga-gis/src/accessories/python/tools/ta_lighting.py
=====================================
@@ -28,7 +28,7 @@ def Analytical_Hillshading(ELEVATION=None, SHADE=None, METHOD=None, POSITION=Non
- POSITION [`choice`] : Sun's Position. Available Choices: [0] azimuth and height [1] date and time Default: 0
- AZIMUTH [`floating point number`] : Azimuth. Minimum: 0.000000 Maximum: 360.000000 Default: 315.000000 Direction of the light source, measured in degree clockwise from the North direction.
- DECLINATION [`floating point number`] : Height. Minimum: 0.000000 Maximum: 90.000000 Default: 45.000000 Height of the light source, measured in degree above the horizon.
- - DATE [`date`] : Day. Default: 2025-01-09
+ - DATE [`date`] : Day. Default: 2025-01-20
- TIME [`floating point number`] : Hour. Minimum: 0.000000 Maximum: 24.000000 Default: 12.000000
- EXAGGERATION [`floating point number`] : Exaggeration. Default: 1.000000 The terrain exaggeration factor allows one to increase the shading contrasts in flat areas.
- UNIT [`choice`] : Unit. Available Choices: [0] radians [1] degree Default: 0
@@ -73,7 +73,7 @@ def run_tool_ta_lighting_0(ELEVATION=None, SHADE=None, METHOD=None, POSITION=Non
- POSITION [`choice`] : Sun's Position. Available Choices: [0] azimuth and height [1] date and time Default: 0
- AZIMUTH [`floating point number`] : Azimuth. Minimum: 0.000000 Maximum: 360.000000 Default: 315.000000 Direction of the light source, measured in degree clockwise from the North direction.
- DECLINATION [`floating point number`] : Height. Minimum: 0.000000 Maximum: 90.000000 Default: 45.000000 Height of the light source, measured in degree above the horizon.
- - DATE [`date`] : Day. Default: 2025-01-09
+ - DATE [`date`] : Day. Default: 2025-01-20
- TIME [`floating point number`] : Hour. Minimum: 0.000000 Maximum: 24.000000 Default: 12.000000
- EXAGGERATION [`floating point number`] : Exaggeration. Default: 1.000000 The terrain exaggeration factor allows one to increase the shading contrasts in flat areas.
- UNIT [`choice`] : Unit. Available Choices: [0] radians [1] degree Default: 0
@@ -134,8 +134,8 @@ def Potential_Incoming_Solar_Radiation(GRD_DEM=None, GRD_SVF=None, GRD_VAPOUR=No
- LOCATION [`choice`] : Location. Available Choices: [0] constant latitude [1] calculate from grid system Default: 0
- LATITUDE [`degree`] : Latitude. Minimum: -90.000000 Maximum: 90.000000 Default: 53.000000
- PERIOD [`choice`] : Time Period. Available Choices: [0] moment [1] day [2] range of days Default: 1 Momentum output will be in units of power [W/m²], time span will be in units of energy, either [kWh/m²], [kJ/m²], or [J/cm²].
- - DAY [`date`] : Day. Default: 2025-01-09
- - DAY_STOP [`date`] : Last Day. Default: 2025-01-09
+ - DAY [`date`] : Day. Default: 2025-01-20
+ - DAY_STOP [`date`] : Last Day. Default: 2025-01-20
- DAYS_STEP [`integer number`] : Resolution [d]. Minimum: 1 Default: 5 Time step size for a range of days calculation given in days.
- MOMENT [`floating point number`] : Moment [h]. Minimum: 0.000000 Maximum: 24.000000 Default: 12.000000
- HOUR_RANGE [`value range`] : Time Span [h]. Time span used for the calculation of daily radiation sums.
@@ -220,8 +220,8 @@ def run_tool_ta_lighting_2(GRD_DEM=None, GRD_SVF=None, GRD_VAPOUR=None, GRD_LINK
- LOCATION [`choice`] : Location. Available Choices: [0] constant latitude [1] calculate from grid system Default: 0
- LATITUDE [`degree`] : Latitude. Minimum: -90.000000 Maximum: 90.000000 Default: 53.000000
- PERIOD [`choice`] : Time Period. Available Choices: [0] moment [1] day [2] range of days Default: 1 Momentum output will be in units of power [W/m²], time span will be in units of energy, either [kWh/m²], [kJ/m²], or [J/cm²].
- - DAY [`date`] : Day. Default: 2025-01-09
- - DAY_STOP [`date`] : Last Day. Default: 2025-01-09
+ - DAY [`date`] : Day. Default: 2025-01-20
+ - DAY_STOP [`date`] : Last Day. Default: 2025-01-20
- DAYS_STEP [`integer number`] : Resolution [d]. Minimum: 1 Default: 5 Time step size for a range of days calculation given in days.
- MOMENT [`floating point number`] : Moment [h]. Minimum: 0.000000 Maximum: 24.000000 Default: 12.000000
- HOUR_RANGE [`value range`] : Time Span [h]. Time span used for the calculation of daily radiation sums.
=====================================
saga-gis/src/saga_core/saga_api/geo_tools.h
=====================================
@@ -980,9 +980,14 @@ public:
static CSG_String Convert_WKT2_to_XML (const CSG_String &WKT);
+ void Set_UseInternalDB (bool bUse = true) { m_bUseInternalDB = bUse; }
+ bool Get_UseInternalDB (void) const { return( m_bUseInternalDB ); }
+
private:
+ bool m_bUseInternalDB = true;
+
class CSG_Table *m_pProjections, *m_pPreferences;
=====================================
saga-gis/src/saga_core/saga_api/projections.cpp
=====================================
@@ -1037,6 +1037,21 @@ bool CSG_Projections::Get_Preference(CSG_Projection &Projection, int Code, const
}
}
+ if( m_bUseInternalDB )
+ {
+ for(sLong i=0; i<m_pProjections->Get_Count(); i++)
+ {
+ CSG_Table_Record *pProjection = m_pProjections->Get_Record(i);
+
+ if( Code == pProjection->asInt(PRJ_FIELD_AUTH_SRID) && !Authority.CmpNoCase(pProjection->asString(PRJ_FIELD_AUTH_NAME)) )
+ {
+ Projection = _Get_Projection(pProjection);
+
+ return( Projection.is_Okay() );
+ }
+ }
+ }
+
return( false );
}
@@ -1119,6 +1134,26 @@ bool CSG_Projections::Save(const CSG_String &File)
//---------------------------------------------------------
CSG_String CSG_Projections::Parse(const CSG_String &Definition, ESG_CRS_Format Format)
{
+ if( Definition.is_Empty() )
+ {
+ return( "" );
+ }
+
+ //-----------------------------------------------------
+ CSG_Projection Projection; // check white list first !
+
+ if( SG_Get_Projections().Get_Preference(Projection, Definition) )
+ {
+ switch( Format )
+ {
+ case ESG_CRS_Format::PROJ: return( Projection.Get_PROJ() );
+ case ESG_CRS_Format::WKT2: return( Projection.Get_WKT2() );
+ default:
+ return( Parse(Projection.Get_WKT2(), Format) );
+ }
+ }
+
+ //-----------------------------------------------------
CSG_String s; CSG_Tool *pTool = SG_Get_Tool_Library_Manager().Create_Tool("pj_proj4", 19); // Coordinate Reference System Format Conversion
if( pTool ) // check proj.lib, ...will check white list first !
@@ -1156,6 +1191,17 @@ bool CSG_Projections::Parse(const CSG_String &Definition, CSG_String *PROJ, CSG_
return( false );
}
+ //-----------------------------------------------------
+ CSG_Projection Projection; // check white list first !
+
+ if( SG_Get_Projections().Get_Preference(Projection, Definition) )
+ {
+ if( PROJ ) { *PROJ = Projection.Get_PROJ(); }
+ if( WKT2 ) { *WKT2 = Projection.Get_WKT2(); }
+
+ return( (!WKT1 && !JSON && !ESRI) || Parse(Projection.Get_WKT2(), NULL, NULL, WKT1, JSON, ESRI) );
+ }
+
//-----------------------------------------------------
CSG_Tool *pTool = SG_Get_Tool_Library_Manager().Create_Tool("pj_proj4", 19); // Coordinate Reference System Format Conversion
=====================================
saga-gis/src/saga_core/saga_api/saga_api.h
=====================================
@@ -86,8 +86,8 @@
//---------------------------------------------------------
#define SAGA_MAJOR_VERSION 9
#define SAGA_MINOR_VERSION 7
-#define SAGA_RELEASE_NUMBER 1
-#define SAGA_VERSION SG_T("9.7.1")
+#define SAGA_RELEASE_NUMBER 2
+#define SAGA_VERSION SG_T("9.7.2")
///////////////////////////////////////////////////////////
=====================================
saga-gis/src/saga_core/saga_cmd/config.cpp
=====================================
@@ -125,6 +125,7 @@ bool Config_Create (wxConfigBase *pConfig)
Config_Write(pConfig, "CMD", "XML_MESSAGE" , false ); // x: message output as xml
Config_Write(pConfig, "TOOLS", "LNG_FILE_DIC" , SG_T("")); // translation dictionary
+ Config_Write(pConfig, "TOOLS", "CRS_CODE_DB" , SG_Get_Projections().Get_UseInternalDB() ? 0 : 1);
Config_Write(pConfig, "TOOLS", "OMP_THREADS_MAX" , SG_OMP_Get_Max_Num_Procs());
Config_Write(pConfig, "TOOLS", "ADD_LIB_PATHS" , SG_T("")); // additional tool library paths (aka SAGA_TLB)
@@ -166,6 +167,8 @@ bool Config_Load (wxConfigBase *pConfig)
));
}
+ if( Config_Read(pConfig, "TOOLS", "CRS_CODE_DB" , iValue) ) { SG_Get_Projections().Set_UseInternalDB(iValue == 0); }
+
if( Config_Read(pConfig, "TOOLS", "OMP_THREADS_MAX" , iValue) ) { SG_OMP_Set_Max_Num_Threads(iValue); }
if( Config_Read(pConfig, "TOOLS", "ADD_LIB_PATHS" , sValue) && !sValue.IsEmpty() )
=====================================
saga-gis/src/saga_core/saga_cmd/man/saga_cmd.1
=====================================
@@ -133,7 +133,7 @@
.\" ========================================================================
.\"
.IX Title "SAGA_CMD 1"
-.TH SAGA_CMD 1 "2021-07-07" "9.7.1" " "
+.TH SAGA_CMD 1 "2021-07-07" "9.7.2" " "
.\" For nroff, turn off justification. Always turn off hyphenation; it makes
.\" way too many mistakes in technical documents.
.if n .ad l
=====================================
saga-gis/src/saga_core/saga_gui/man/saga_gui.1
=====================================
@@ -124,7 +124,7 @@
.\" ========================================================================
.\"
.IX Title "SAGA_GUI 1"
-.TH SAGA_GUI 1 "2021-07-07" "9.7.1" " "
+.TH SAGA_GUI 1 "2021-07-07" "9.7.2" " "
.\" For nroff, turn off justification. Always turn off hyphenation; it makes
.\" way too many mistakes in technical documents.
.if n .ad l
=====================================
saga-gis/src/saga_core/saga_gui/wksp_tool_manager.cpp
=====================================
@@ -154,6 +154,15 @@ CWKSP_Tool_Manager::CWKSP_Tool_Manager(void)
), 0
);
+ m_Parameters.Add_Choice("NODE_TOOLS",
+ "CRS_CODE_DB" , _TL("CRS Code Database"),
+ _TL("Preferred authority code database used to look-up coordinate reference system definitions."),
+ CSG_String::Format("%s|%s",
+ _TL("built-in"),
+ SG_T("proj")
+ ), SG_Get_Projections().Get_UseInternalDB() ? 0 : 1
+ );
+
//-----------------------------------------------------
m_Parameters.Add_Node("", "NODE_FILES", _TL("Files"), _TL(""));
@@ -223,6 +232,8 @@ bool CWKSP_Tool_Manager::Initialise(void)
g_pSAGA->Process_Set_Frequency(m_Parameters("PROCESS_UPDATE")->asInt());
+ SG_Get_Projections().Set_UseInternalDB(m_Parameters("CRS_CODE_DB")->asInt() == 0);
+
#ifdef _OPENMP
SG_OMP_Set_Max_Num_Threads(m_Parameters("OMP_THREADS_MAX")->asInt());
#endif
@@ -406,6 +417,8 @@ void CWKSP_Tool_Manager::Parameters_Changed(void)
g_pSAGA->Process_Set_Frequency(m_Parameters("PROCESS_UPDATE")->asInt());
+ SG_Get_Projections().Set_UseInternalDB(m_Parameters("CRS_CODE_DB")->asInt() == 0);
+
#ifdef _OPENMP
SG_OMP_Set_Max_Num_Threads(m_Parameters("OMP_THREADS_MAX")->asInt());
#endif
=====================================
saga-gis/src/tools/projection/pj_proj4/crs_definition.cpp
=====================================
@@ -83,7 +83,7 @@ CCRS_Definition::CCRS_Definition(void)
Add_Reference("https://proj.org", SG_T("PROJ Homepage"));
//-----------------------------------------------------
- Parameters.Add_String("", "DEFINITION", _TL("Definition"), _TL(""), "epsg:4326");
+ Parameters.Add_String("", "DEFINITION", _TL("Definition"), _TL(""), "");
if( has_GUI() || has_CMD() )
{
@@ -107,11 +107,6 @@ CCRS_Definition::CCRS_Definition(void)
Parameters.Add_Bool("WKT2", "SIMPLIFIED", _TL("Simplified"), _TL("applies to WKT-2" ), true);
Parameters.Add_Table("", "FORMATS", _TL("Formats"), _TL(""), PARAMETER_OUTPUT_OPTIONAL)->Set_UseInGUI(false);
-
- if( has_GUI() )
- {
- On_Parameter_Changed(&Parameters, Parameters("DEFINITION"));
- }
}
@@ -169,6 +164,22 @@ int CCRS_Definition::On_Parameters_Enable(CSG_Parameters *pParameters, CSG_Param
}
+///////////////////////////////////////////////////////////
+// //
+///////////////////////////////////////////////////////////
+
+//---------------------------------------------------------
+bool CCRS_Definition::On_Before_Execution(void)
+{
+ if( has_GUI() && !*Parameters("DEFINITION")->asString() )
+ {
+ Parameters.Set_Parameter("DEFINITION", "epsg:4326");
+ }
+
+ return( true );
+}
+
+
///////////////////////////////////////////////////////////
// //
///////////////////////////////////////////////////////////
=====================================
saga-gis/src/tools/projection/pj_proj4/crs_definition.h
=====================================
@@ -83,6 +83,8 @@ protected:
virtual int On_Parameter_Changed (CSG_Parameters *pParameters, CSG_Parameter *pParameter);
virtual int On_Parameters_Enable (CSG_Parameters *pParameters, CSG_Parameter *pParameter);
+ virtual bool On_Before_Execution (void);
+
virtual bool On_Execute (void);
};
=====================================
saga-gis/version.cmake
=====================================
@@ -1,7 +1,7 @@
# The version number.
set (SAGA_VERSION_MAJOR 9)
set (SAGA_VERSION_MINOR 7)
-set (SAGA_VERSION_PATCH 1)
+set (SAGA_VERSION_PATCH 2)
# get git commit hash (or dirty if git is not installed)
View it on GitLab: https://salsa.debian.org/debian-gis-team/saga/-/commit/a6a91b29c09f3f0eca1f9557a43f1d721ee85891
--
View it on GitLab: https://salsa.debian.org/debian-gis-team/saga/-/commit/a6a91b29c09f3f0eca1f9557a43f1d721ee85891
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-grass-devel/attachments/20250120/5aeaf5f6/attachment-0001.htm>
More information about the Pkg-grass-devel
mailing list