3234 |
if (file->GetAutoLoad()) { |
if (file->GetAutoLoad()) { |
3235 |
for (uint i = 0; i < DimensionRegions; i++) { |
for (uint i = 0; i < DimensionRegions; i++) { |
3236 |
uint32_t wavepoolindex = _3lnk->ReadUint32(); |
uint32_t wavepoolindex = _3lnk->ReadUint32(); |
3237 |
if (file->pWavePoolTable) pDimensionRegions[i]->pSample = GetSampleFromWavePool(wavepoolindex); |
if (file->pWavePoolTable && pDimensionRegions[i]) |
3238 |
|
pDimensionRegions[i]->pSample = GetSampleFromWavePool(wavepoolindex); |
3239 |
} |
} |
3240 |
GetSample(); // load global region sample reference |
GetSample(); // load global region sample reference |
3241 |
} |
} |
4742 |
RegionList::iterator end = pRegions->end(); |
RegionList::iterator end = pRegions->end(); |
4743 |
for (; iter != end; ++iter) { |
for (; iter != end; ++iter) { |
4744 |
gig::Region* pRegion = static_cast<gig::Region*>(*iter); |
gig::Region* pRegion = static_cast<gig::Region*>(*iter); |
4745 |
for (int iKey = pRegion->KeyRange.low; iKey <= pRegion->KeyRange.high; iKey++) { |
const int low = std::max(int(pRegion->KeyRange.low), 0); |
4746 |
|
const int high = std::min(int(pRegion->KeyRange.high), 127); |
4747 |
|
for (int iKey = low; iKey <= high; iKey++) { |
4748 |
RegionKeyTable[iKey] = pRegion; |
RegionKeyTable[iKey] = pRegion; |
4749 |
} |
} |
4750 |
} |
} |