diff options
author | Robert Adams | 2013-09-25 17:21:20 -0700 |
---|---|---|
committer | Robert Adams | 2013-09-25 17:30:53 -0700 |
commit | fbc9072a5ca4ae3c8474964fbd4ef663eeed1377 (patch) | |
tree | f422d4a107c5318c02255e8cc4432a83608bcdf8 /OpenSim/Framework/RegionInfo.cs | |
parent | Remove time based terrain storage in SQLite so revision number can be used (diff) | |
download | opensim-SC_OLD-fbc9072a5ca4ae3c8474964fbd4ef663eeed1377.zip opensim-SC_OLD-fbc9072a5ca4ae3c8474964fbd4ef663eeed1377.tar.gz opensim-SC_OLD-fbc9072a5ca4ae3c8474964fbd4ef663eeed1377.tar.bz2 opensim-SC_OLD-fbc9072a5ca4ae3c8474964fbd4ef663eeed1377.tar.xz |
varregion: serious rework of TerrainChannel:
-- addition of varaible region size in X and Y
-- internal storage of heightmap changed from double[] to short[]
-- helper routines for handling internal structure while keeping existing API
-- to and from XML that adds region size information (for downward compatibility,
output in the legacy XML format if X and Y are 256)
Updated and commented Constants.RegionSize but didn't change the name for compatibility.
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Framework/RegionInfo.cs | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/OpenSim/Framework/RegionInfo.cs b/OpenSim/Framework/RegionInfo.cs index 2d3c9ea..882fe33 100644 --- a/OpenSim/Framework/RegionInfo.cs +++ b/OpenSim/Framework/RegionInfo.cs | |||
@@ -472,7 +472,7 @@ namespace OpenSim.Framework | |||
472 | /// The x co-ordinate of this region in map tiles (e.g. 1000). | 472 | /// The x co-ordinate of this region in map tiles (e.g. 1000). |
473 | /// Coordinate is scaled as world coordinates divided by the legacy region size | 473 | /// Coordinate is scaled as world coordinates divided by the legacy region size |
474 | /// and is thus is the number of legacy regions. | 474 | /// and is thus is the number of legacy regions. |
475 | /// This entrypoint exists for downward compatability for external modules. | 475 | /// DO NOT USE FOR NEW CODE! This entrypoint exists for downward compatability with external modules. |
476 | /// </summary> | 476 | /// </summary> |
477 | public uint RegionLocX | 477 | public uint RegionLocX |
478 | { | 478 | { |
@@ -480,22 +480,11 @@ namespace OpenSim.Framework | |||
480 | set { LegacyRegionLocX = value; } | 480 | set { LegacyRegionLocX = value; } |
481 | } | 481 | } |
482 | 482 | ||
483 | public void SetDefaultRegionSize() | ||
484 | { | ||
485 | RegionWorldLocX = 0; | ||
486 | RegionWorldLocY = 0; | ||
487 | RegionWorldLocZ = 0; | ||
488 | RegionSizeX = Constants.RegionSize; | ||
489 | RegionSizeY = Constants.RegionSize; | ||
490 | RegionSizeZ = Constants.RegionHeight; | ||
491 | } | ||
492 | |||
493 | |||
494 | /// <summary> | 483 | /// <summary> |
495 | /// The y co-ordinate of this region in map tiles (e.g. 1000). | 484 | /// The y co-ordinate of this region in map tiles (e.g. 1000). |
496 | /// Coordinate is scaled as world coordinates divided by the legacy region size | 485 | /// Coordinate is scaled as world coordinates divided by the legacy region size |
497 | /// and is thus is the number of legacy regions. | 486 | /// and is thus is the number of legacy regions. |
498 | /// This entrypoint exists for downward compatability for external modules. | 487 | /// DO NOT USE FOR NEW CODE! This entrypoint exists for downward compatability with external modules. |
499 | /// </summary> | 488 | /// </summary> |
500 | public uint RegionLocY | 489 | public uint RegionLocY |
501 | { | 490 | { |
@@ -503,6 +492,16 @@ namespace OpenSim.Framework | |||
503 | set { LegacyRegionLocY = value; } | 492 | set { LegacyRegionLocY = value; } |
504 | } | 493 | } |
505 | 494 | ||
495 | public void SetDefaultRegionSize() | ||
496 | { | ||
497 | RegionWorldLocX = 0; | ||
498 | RegionWorldLocY = 0; | ||
499 | RegionWorldLocZ = 0; | ||
500 | RegionSizeX = Constants.RegionSize; | ||
501 | RegionSizeY = Constants.RegionSize; | ||
502 | RegionSizeZ = Constants.RegionHeight; | ||
503 | } | ||
504 | |||
506 | // A unique region handle is created from the region's world coordinates. | 505 | // A unique region handle is created from the region's world coordinates. |
507 | // This cannot be changed because some code expects to receive the region handle and then | 506 | // This cannot be changed because some code expects to receive the region handle and then |
508 | // compute the region coordinates from it. | 507 | // compute the region coordinates from it. |