## 3 Proposed Procedure
### Texture Mapping Process
#### 3.3.1 Geographic Coordinate Assignment Algorithm  
The geographic coordinate assignment algorithm includes the process of calculating geographical boundaries based on map sheet numbers embedded in TIF files and converting them into GeoTIFF format. This process is a crucial step for precise texture mapping to 3D models, aiming to ensure geographic information accuracy and visual consistency. The main process consists of five stages: map sheet number interpretation, coordinate system conversion, pixel resolution calculation, GeoTIFF data generation, and storage.  
Figure 5: Texture mapping process flowchart.  
* Map Sheet Number Interpretation: Map sheet numbers, structured as hierarchical strings, provide critical information for determining the geographical boundaries of texture data. By analyzing these numbers, _latitude_ and _longitude_ are calculated to define precise tile location and size. The first two digits represent the integer value of latitude, with subsequent digits defining detailed coordinates through scale units of 0.25 and 0.025 degrees for secondary and tertiary numbers, respectively. \[\mathit{longitude}=12+\mathit{map sheet}\ \mathit{number}[2]+0.25\cdot \mathit{second}-\mathit{order}\ \mathit{longitude}\ \mathit{number}+0.025\cdot \mathit{third}-\] \[\mathit{order}\ \mathit{longitude}\ \mathit{number},\] \[\mathit{latitude}=\mathit{map sheet}\ \mathit{number}[0:2]+0.25\cdot \mathit{second}-\mathit{order}\ \mathit{latitude}\ \mathit{number}+0.025\cdot \mathit{third}-\] \[\mathit{order}\ \mathit{latitude}\ \mathit{number}\]
* Coordinate System Transformation: Initial latitude/longitude calculated \(\left(x^{\mathit{Geo}},y^{\mathit{Geo}}\right)\) from map sheet numbers are defined in WGS84 or other geographic coordinate systems. These are converted into target coordinate \(\left(x^{\mathit{EPSG}},y^{\mathit{EPSG}}\right)\) systems like EPSG 5186 to adjust texture positions for 3D model compatibility.
* The conversion is performed using the ProjNet library, which supports various EPSG standards [34]. \[\left(x^{\mathit{EPSG}},y^{\mathit{EPSG}}\right)=\mathit{TransformEPSG}\left(x^{ \mathit{Geo}},y^{\mathit{Geo}}\right)\]
* Pixel-level Resolution Calculation: following coordinate system conversion, pixel size is calculated to ensure consistency with geographical coordinates.
* This information is essential for converting texture data to GeoTIFF format. Resolution is calculated based on converted minimum/maximum coordinate values, with pixel scale defined by overall texture size and image resolution. \[x_{\mathit{scale}}=\frac{x^{\mathit{EPSG}}_{\mathit{max}}-x^{\mathit{EPSG}}_{ \mathit{min}}}{\mathit{Pixel}\ \mathit{Width}^{\mathit{Image}}}\] \[y_{\mathit{scale}}=\frac{y^{\mathit{EPSG}}_{\mathit{max}}-y^{\mathit{EPSG}}_{ \mathit{min}}}{\mathit{Pixel}\ \mathit{Height}^{\mathit{Image}}}\]
* Creation of GeoTIFF Data: TIF file data are converted into GeoTIFF format based on calculated coordinate information.
* Coordinate information is assigned to each pixel, with conversion results stored in GeoTIFF files. \[x^{\mathit{EPSG}}_{\mathit{Pixel}}=x_{\mathit{EPSG}}+i\cdot x_{\mathit{scale}}\] \[y^{\mathit{EPSG}}_{\mathit{Pixel}}=y_{\mathit{EPSG}}-j\cdot y_{\mathit{scale}}\] Pixel \(x\),\(y\) coordinates are processed and stored in GeoTransform arrays for generation.
* GeoTIFF Export: finally, data are stored in GeoTIFF format using the GDAL library.
* The storage process includes GeoTransform values and coordinate system information, producing files compatible with software like QGIS 3.34.7 (see Figure 6).