mirror of
				https://github.com/ciphervance/supercell-wx.git
				synced 2025-10-31 11:40:06 +00:00 
			
		
		
		
	Updating MapLibre Native to the latest version (2023-04-28)
This commit is contained in:
		
							parent
							
								
									271756bba9
								
							
						
					
					
						commit
						8e8567a48f
					
				
					 5 changed files with 12 additions and 8 deletions
				
			
		|  | @ -15,7 +15,7 @@ Supercell Wx uses code from the following dependencies: | ||||||
| | [bzip2](https://sourceware.org/bzip2/) | [bzip2 and libbzip2 License v1.0.6](https://spdx.org/licenses/bzip2-1.0.6.html) | | | [bzip2](https://sourceware.org/bzip2/) | [bzip2 and libbzip2 License v1.0.6](https://spdx.org/licenses/bzip2-1.0.6.html) | | ||||||
| | [cmake-conan](https://github.com/conan-io/cmake-conan) | [MIT License](https://spdx.org/licenses/MIT.html) | | | [cmake-conan](https://github.com/conan-io/cmake-conan) | [MIT License](https://spdx.org/licenses/MIT.html) | | ||||||
| | [cpr](https://github.com/libcpr/cpr) | [MIT License](https://spdx.org/licenses/MIT.html) | | | [cpr](https://github.com/libcpr/cpr) | [MIT License](https://spdx.org/licenses/MIT.html) | | ||||||
| | [CSS Color Parser](https://github.com/deanm/css-color-parser-js) | [MIT License](https://spdx.org/licenses/MIT.html) | Ported to C++ for MapLibre GL Native | | | [CSS Color Parser](https://github.com/deanm/css-color-parser-js) | [MIT License](https://spdx.org/licenses/MIT.html) | Ported to C++ for MapLibre Native | | ||||||
| | [Date](https://github.com/HowardHinnant/date) | [MIT License](https://spdx.org/licenses/MIT.html) | | | [Date](https://github.com/HowardHinnant/date) | [MIT License](https://spdx.org/licenses/MIT.html) | | ||||||
| | [Dear ImGui](https://github.com/ocornut/imgui) | [MIT License](https://spdx.org/licenses/MIT.html) | | | [Dear ImGui](https://github.com/ocornut/imgui) | [MIT License](https://spdx.org/licenses/MIT.html) | | ||||||
| | [FreeType](https://freetype.org/) | [Freetype Project License](https://spdx.org/licenses/FTL.html) | | | [FreeType](https://freetype.org/) | [Freetype Project License](https://spdx.org/licenses/FTL.html) | | ||||||
|  | @ -29,8 +29,8 @@ Supercell Wx uses code from the following dependencies: | ||||||
| | [libiconv](https://www.gnu.org/software/libiconv/) | [GNU Lesser General Public License v2.1 or later](https://spdx.org/licenses/LGPL-2.1-or-later.html) | | | [libiconv](https://www.gnu.org/software/libiconv/) | [GNU Lesser General Public License v2.1 or later](https://spdx.org/licenses/LGPL-2.1-or-later.html) | | ||||||
| | [libpng](http://libpng.org/pub/png/libpng.html) | [PNG Reference Library version 2](https://spdx.org/licenses/libpng-2.0.html) | | | [libpng](http://libpng.org/pub/png/libpng.html) | [PNG Reference Library version 2](https://spdx.org/licenses/libpng-2.0.html) | | ||||||
| | [libxml2](http://xmlsoft.org/) | [MIT License](https://spdx.org/licenses/MIT.html) | | | [libxml2](http://xmlsoft.org/) | [MIT License](https://spdx.org/licenses/MIT.html) | | ||||||
| | [MapLibre GL Native](https://maplibre.org/projects/maplibre-native/) | [BSD 2-Clause "Simplified" License](https://spdx.org/licenses/BSD-2-Clause.html) | | | [MapLibre Native](https://maplibre.org/projects/maplibre-native/) | [BSD 2-Clause "Simplified" License](https://spdx.org/licenses/BSD-2-Clause.html) | | ||||||
| | [nunicode](https://bitbucket.org/alekseyt/nunicode/src/master/) | [MIT License](https://spdx.org/licenses/MIT.html) | Modified for MapLibre GL Native | | | [nunicode](https://bitbucket.org/alekseyt/nunicode/src/master/) | [MIT License](https://spdx.org/licenses/MIT.html) | Modified for MapLibre Native | | ||||||
| | [OpenSSL](https://www.openssl.org/) | [OpenSSL License](https://spdx.org/licenses/OpenSSL.html) | | | [OpenSSL](https://www.openssl.org/) | [OpenSSL License](https://spdx.org/licenses/OpenSSL.html) | | ||||||
| | [Qt](https://www.qt.io/) | [GNU Lesser General Public License v3.0 only](https://spdx.org/licenses/LGPL-3.0-only.html) | Qt Core, Qt GUI, Qt Network, Qt OpenGL, Qt SQL, Qt SVG, Qt Widgets<br/>Additional Licenses: https://doc.qt.io/qt-6/licenses-used-in-qt.html | | | [Qt](https://www.qt.io/) | [GNU Lesser General Public License v3.0 only](https://spdx.org/licenses/LGPL-3.0-only.html) | Qt Core, Qt GUI, Qt Network, Qt OpenGL, Qt SQL, Qt SVG, Qt Widgets<br/>Additional Licenses: https://doc.qt.io/qt-6/licenses-used-in-qt.html | | ||||||
| | [spdlog](https://github.com/gabime/spdlog) | [MIT License](https://spdx.org/licenses/MIT.html) | | | [spdlog](https://github.com/gabime/spdlog) | [MIT License](https://spdx.org/licenses/MIT.html) | | ||||||
|  |  | ||||||
							
								
								
									
										2
									
								
								external/mapbox-gl-native
									
										
									
									
										vendored
									
									
								
							
							
						
						
									
										2
									
								
								external/mapbox-gl-native
									
										
									
									
										vendored
									
									
								
							|  | @ -1 +1 @@ | ||||||
| Subproject commit e12c4d6be450a163b38548f72e72f4080fc71dbb | Subproject commit 4c01b7ef1f19964167070c3ea008780b8df72182 | ||||||
							
								
								
									
										4
									
								
								external/mapbox-gl-native.cmake
									
										
									
									
										vendored
									
									
								
							
							
						
						
									
										4
									
								
								external/mapbox-gl-native.cmake
									
										
									
									
										vendored
									
									
								
							|  | @ -2,8 +2,8 @@ cmake_minimum_required(VERSION 3.20) | ||||||
| set(PROJECT_NAME scwx-mbgl) | set(PROJECT_NAME scwx-mbgl) | ||||||
| 
 | 
 | ||||||
| set(gtest_disable_pthreads ON) | set(gtest_disable_pthreads ON) | ||||||
| set(MBGL_WITH_QT ON) | set(MLN_WITH_QT ON) | ||||||
| set(MBGL_QT_WITH_INTERNAL_ICU ON) | set(MLN_QT_WITH_INTERNAL_ICU ON) | ||||||
| add_subdirectory(mapbox-gl-native) | add_subdirectory(mapbox-gl-native) | ||||||
| 
 | 
 | ||||||
| find_package(ZLIB) | find_package(ZLIB) | ||||||
|  |  | ||||||
|  | @ -58,12 +58,14 @@ void DrawItem::UseDefaultProjection( | ||||||
| static glm::vec2 | static glm::vec2 | ||||||
| LatLongToScreenCoordinate(const QMapLibreGL::Coordinate& coordinate) | LatLongToScreenCoordinate(const QMapLibreGL::Coordinate& coordinate) | ||||||
| { | { | ||||||
|  |    static constexpr double RAD2DEG_D = 180.0 / M_PI; | ||||||
|  | 
 | ||||||
|    double latitude = std::clamp( |    double latitude = std::clamp( | ||||||
|       coordinate.first, -mbgl::util::LATITUDE_MAX, mbgl::util::LATITUDE_MAX); |       coordinate.first, -mbgl::util::LATITUDE_MAX, mbgl::util::LATITUDE_MAX); | ||||||
|    glm::vec2 screen { |    glm::vec2 screen { | ||||||
|       mbgl::util::LONGITUDE_MAX + coordinate.second, |       mbgl::util::LONGITUDE_MAX + coordinate.second, | ||||||
|       -(mbgl::util::LONGITUDE_MAX - |       -(mbgl::util::LONGITUDE_MAX - | ||||||
|         mbgl::util::RAD2DEG_D * |         RAD2DEG_D * | ||||||
|            std::log(std::tan(M_PI / 4.0 + |            std::log(std::tan(M_PI / 4.0 + | ||||||
|                              latitude * M_PI / mbgl::util::DEGREES_MAX)))}; |                              latitude * M_PI / mbgl::util::DEGREES_MAX)))}; | ||||||
|    return screen; |    return screen; | ||||||
|  |  | ||||||
|  | @ -359,12 +359,14 @@ void RadarProductLayer::UpdateColorTable() | ||||||
| static glm::vec2 | static glm::vec2 | ||||||
| LatLongToScreenCoordinate(const QMapLibreGL::Coordinate& coordinate) | LatLongToScreenCoordinate(const QMapLibreGL::Coordinate& coordinate) | ||||||
| { | { | ||||||
|  |    static constexpr double RAD2DEG_D = 180.0 / M_PI; | ||||||
|  | 
 | ||||||
|    double latitude = std::clamp( |    double latitude = std::clamp( | ||||||
|       coordinate.first, -mbgl::util::LATITUDE_MAX, mbgl::util::LATITUDE_MAX); |       coordinate.first, -mbgl::util::LATITUDE_MAX, mbgl::util::LATITUDE_MAX); | ||||||
|    glm::vec2 screen { |    glm::vec2 screen { | ||||||
|       mbgl::util::LONGITUDE_MAX + coordinate.second, |       mbgl::util::LONGITUDE_MAX + coordinate.second, | ||||||
|       -(mbgl::util::LONGITUDE_MAX - |       -(mbgl::util::LONGITUDE_MAX - | ||||||
|         mbgl::util::RAD2DEG_D * |         RAD2DEG_D * | ||||||
|            std::log(std::tan(M_PI / 4.0 + |            std::log(std::tan(M_PI / 4.0 + | ||||||
|                              latitude * M_PI / mbgl::util::DEGREES_MAX)))}; |                              latitude * M_PI / mbgl::util::DEGREES_MAX)))}; | ||||||
|    return screen; |    return screen; | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Dan Paulat
						Dan Paulat