diff options
author | Robert Adams | 2013-11-04 22:06:20 -0800 |
---|---|---|
committer | Robert Adams | 2013-11-04 22:06:20 -0800 |
commit | ac94dc8a14e9087c3ba43bd7a2f2a74f957a975c (patch) | |
tree | fa34d38351799de362c257c4a535eac61e2953a7 /OpenSim/Data | |
parent | varregion: send the proper terrain patch layer code for large terrain. (diff) | |
download | opensim-SC_OLD-ac94dc8a14e9087c3ba43bd7a2f2a74f957a975c.zip opensim-SC_OLD-ac94dc8a14e9087c3ba43bd7a2f2a74f957a975c.tar.gz opensim-SC_OLD-ac94dc8a14e9087c3ba43bd7a2f2a74f957a975c.tar.bz2 opensim-SC_OLD-ac94dc8a14e9087c3ba43bd7a2f2a74f957a975c.tar.xz |
varregion: remove unused terrain serialization code in SQLite and PGSQL modules
Diffstat (limited to 'OpenSim/Data')
-rw-r--r-- | OpenSim/Data/PGSQL/PGSQLSimulationData.cs | 24 | ||||
-rw-r--r-- | OpenSim/Data/SQLite/SQLiteSimulationData.cs | 16 |
2 files changed, 0 insertions, 40 deletions
diff --git a/OpenSim/Data/PGSQL/PGSQLSimulationData.cs b/OpenSim/Data/PGSQL/PGSQLSimulationData.cs index 34eb038..b063607 100644 --- a/OpenSim/Data/PGSQL/PGSQLSimulationData.cs +++ b/OpenSim/Data/PGSQL/PGSQLSimulationData.cs | |||
@@ -1364,30 +1364,6 @@ namespace OpenSim.Data.PGSQL | |||
1364 | #region Private Methods | 1364 | #region Private Methods |
1365 | 1365 | ||
1366 | /// <summary> | 1366 | /// <summary> |
1367 | /// Serializes the terrain data for storage in DB. | ||
1368 | /// </summary> | ||
1369 | /// <param name="val">terrain data</param> | ||
1370 | /// <returns></returns> | ||
1371 | private static Array serializeTerrain(double[,] val) | ||
1372 | { | ||
1373 | MemoryStream str = new MemoryStream(((int)Constants.RegionSize * (int)Constants.RegionSize) * sizeof(double)); | ||
1374 | BinaryWriter bw = new BinaryWriter(str); | ||
1375 | |||
1376 | // TODO: COMPATIBILITY - Add byte-order conversions | ||
1377 | for (int x = 0; x < (int)Constants.RegionSize; x++) | ||
1378 | for (int y = 0; y < (int)Constants.RegionSize; y++) | ||
1379 | { | ||
1380 | double height = val[x, y]; | ||
1381 | if (height == 0.0) | ||
1382 | height = double.Epsilon; | ||
1383 | |||
1384 | bw.Write(height); | ||
1385 | } | ||
1386 | |||
1387 | return str.ToArray(); | ||
1388 | } | ||
1389 | |||
1390 | /// <summary> | ||
1391 | /// Stores new regionsettings. | 1367 | /// Stores new regionsettings. |
1392 | /// </summary> | 1368 | /// </summary> |
1393 | /// <param name="regionSettings">The region settings.</param> | 1369 | /// <param name="regionSettings">The region settings.</param> |
diff --git a/OpenSim/Data/SQLite/SQLiteSimulationData.cs b/OpenSim/Data/SQLite/SQLiteSimulationData.cs index dac4450..5a34f09 100644 --- a/OpenSim/Data/SQLite/SQLiteSimulationData.cs +++ b/OpenSim/Data/SQLite/SQLiteSimulationData.cs | |||
@@ -2009,22 +2009,6 @@ namespace OpenSim.Data.SQLite | |||
2009 | return entry; | 2009 | return entry; |
2010 | } | 2010 | } |
2011 | 2011 | ||
2012 | // private void fillTerrainRow(DataRow row, UUID regionUUID, int rev, double[,] val) | ||
2013 | // { | ||
2014 | // row["RegionUUID"] = regionUUID; | ||
2015 | // row["Revision"] = rev; | ||
2016 | |||
2017 | // MemoryStream str = new MemoryStream(((int)Constants.RegionSize * (int)Constants.RegionSize)*sizeof (double)); | ||
2018 | // BinaryWriter bw = new BinaryWriter(str); | ||
2019 | |||
2020 | // // TODO: COMPATIBILITY - Add byte-order conversions | ||
2021 | // for (int x = 0; x < (int)Constants.RegionSize; x++) | ||
2022 | // for (int y = 0; y < (int)Constants.RegionSize; y++) | ||
2023 | // bw.Write(val[x, y]); | ||
2024 | |||
2025 | // row["Heightfield"] = str.ToArray(); | ||
2026 | // } | ||
2027 | |||
2028 | /// <summary> | 2012 | /// <summary> |
2029 | /// | 2013 | /// |
2030 | /// </summary> | 2014 | /// </summary> |