Go to the source code of this file.
◆ ReadAndRelocateTrackHeader()
Read TRACK_HEADER_SIZE bytes, swap header fields, and relocate embedded track pointers.
- Parameters
-
| track | Writable storage for the header and the track data referenced by its offsets. |
| file | The open track file positioned at its header; checked reads handle failures. |
- Ghidra address:
- BRD3D: 0x10038510
- Ghidra address:
- BRGlide: 0x10031b80
◆ LoadTextureMapFile()
| void LoadTextureMapFile |
( |
const char * | path | ) |
|
Replace the active high-resolution texture map and select texture quality from video memory.
- Parameters
-
| path | The null-terminated map path. A missing file produces an empty map and defaults. |
- Ghidra address:
- BRD3D: 0x10037990
- Ghidra address:
- BRGlide: 0x10031030
◆ LoadTrackTextureMap()
| void LoadTrackTextureMap |
( |
int | track | ) |
|
Load a track's backend-specific high-resolution texture map.
- Parameters
-
| track | A valid index in g_apszTrackFilenames. |
- Ghidra address:
- BRD3D: 0x10037a90
- Ghidra address:
- BRGlide: 0x10031140
◆ ByteSwapTrackData()
Swap and relocate track payloads, prepare textures, and convert instance and route data.
- Parameters
-
| track | The loaded track with a relocated header and big-endian payload arrays. |
- Ghidra address:
- BRD3D: 0x10037e10
- Ghidra address:
- BRGlide: 0x100314d0
◆ ComputeTrackMaxCellIndex()
Replace the surface count with the maximum grid triangle index plus one, omitting entry zero.
- Parameters
-
| track | The track whose grid starts and triangle indices already use host byte order. |
- Ghidra address:
- BRD3D: 0x10037fa0
- Ghidra address:
- BRGlide: 0x10031660
◆ ByteSwapTerrainVertex()
Swap the coordinates and distance of one route point in place.
- Parameters
-
| point | A route point whose numeric fields are in the opposite byte order. |
- Ghidra address:
- BRD3D: 0x10038380
- Ghidra address:
- BRGlide: 0x10031a40
◆ ByteSwapTrackInstance()
Swap instance fields and relocate the model pointer in place.
- Parameters
-
| instance | A loaded track instance with unswapped fields. |
- Ghidra address:
- BRD3D: 0x10038010
- Ghidra address:
- BRGlide: 0x100316d0
◆ ByteSwapTrackInstances()
Swap and relocate every loaded instance in a track.
- Parameters
-
| track | The relocated header whose instance array remains in file byte order. |
- Ghidra address:
- BRD3D: 0x10037fe0
- Ghidra address:
- BRGlide: 0x100316a0
◆ ByteSwapTrackAnimationTable()
| void ByteSwapTrackAnimationTable |
( |
TrackHeader * | track | ) |
|
Swap special animation records, relocating and converting moving-object path coordinates.
- Parameters
-
| track | The relocated track whose special animation records remain in file byte order. |
- Ghidra address:
- BRD3D: 0x10038b20
- Ghidra address:
- BRGlide: 0x10032190
◆ ByteSwapTrackSegmentList()
Relocate section-list entries and convert each route section in place.
- Parameters
-
| track | The relocated track header with an unconverted section pointer array. |
- Ghidra address:
- BRD3D: 0x10038250
- Ghidra address:
- BRGlide: 0x10031910
◆ ByteSwapTrackSegment()
Swap route-section fields and points and relocate section links.
- Parameters
-
| section | A section loaded in file byte order. |
- Ghidra address:
- BRD3D: 0x100382a0
- Ghidra address:
- BRGlide: 0x10031960
◆ ByteSwapTrackVec3Array()
Swap every track camera point's three coordinates in place.
- Parameters
-
| track | The relocated header whose camera point array remains in file byte order. |
- Ghidra address:
- BRD3D: 0x10038410
- Ghidra address:
- BRGlide: 0x10031a80
◆ CopyTextureAndPaletteFromSegment()
| void CopyTextureAndPaletteFromSegment |
( |
ModelTexture * | textures, |
|
|
int | count ) |
Copy initial images and palettes for two-frame animated track textures into writable buffers.
- Parameters
-
| textures | The relocated texture descriptors, backed by the active track texture segment. |
| count | The number of descriptors in textures. |
- Ghidra address:
- BRD3D: 0x10038450
- Ghidra address:
- BRGlide: 0x10031ac0
◆ g_abTrackGeometryBuffer
Storage for the loaded track geometry, with TRACK_MAX_SIZE bytes of capacity.
- Ghidra address:
- BRD3D: 0x106c8e78
- Ghidra address:
- BRGlide: 0x106eff08