aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorSean Dague2007-08-09 19:02:32 +0000
committerSean Dague2007-08-09 19:02:32 +0000
commit2b25717c8c41d890c5f17a0dc0a3db7444a16513 (patch)
treec6fc24167a4dd6f53be88b0e8e3872f13d8f2176
parent* Now "OpenSim.DataStore.MonoSqlite" is not referenced from solution either. (diff)
downloadopensim-SC-2b25717c8c41d890c5f17a0dc0a3db7444a16513.zip
opensim-SC-2b25717c8c41d890c5f17a0dc0a3db7444a16513.tar.gz
opensim-SC-2b25717c8c41d890c5f17a0dc0a3db7444a16513.tar.bz2
opensim-SC-2b25717c8c41d890c5f17a0dc0a3db7444a16513.tar.xz
prim.Shape -> primshapes table
-rw-r--r--OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs38
1 files changed, 35 insertions, 3 deletions
diff --git a/OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs b/OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs
index 7de9232..f7a579f 100644
--- a/OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs
+++ b/OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs
@@ -271,9 +271,41 @@ namespace OpenSim.DataStore.MonoSqliteStorage
271 row["RotationW"] = prim.RotationOffset.W; 271 row["RotationW"] = prim.RotationOffset.W;
272 } 272 }
273 273
274 private void fillShapeRow(DataRow row, PrimitiveBaseShape shape) 274 private void fillShapeRow(DataRow row, SceneObjectPart prim)
275 { 275 {
276 276 PrimitiveBaseShape s = prim.Shape;
277 row["UUID"] = prim.UUID;
278 // shape is an enum
279 row["Shape"] = 0;
280 // vectors
281 row["ScaleX"] = s.Scale.X;
282 row["ScaleY"] = s.Scale.Y;
283 row["ScaleZ"] = s.Scale.Z;
284 // paths
285 row["PCode"] = s.PCode;
286 row["PathBegin"] = s.PathBegin;
287 row["PathEnd"] = s.PathEnd;
288 row["PathScaleX"] = s.PathScaleX;
289 row["PathScaleY"] = s.PathScaleY;
290 row["PathShearX"] = s.PathShearX;
291 row["PathShearY"] = s.PathShearY;
292 row["PathSkew"] = s.PathSkew;
293 row["PathCurve"] = s.PathCurve;
294 row["PathRadiusOffset"] = s.PathRadiusOffset;
295 row["PathRevolutions"] = s.PathRevolutions;
296 row["PathTaperX"] = s.PathTaperX;
297 row["PathTaperY"] = s.PathTaperY;
298 row["PathTwist"] = s.PathTwist;
299 row["PathTwistBegin"] = s.PathTwistBegin;
300 // profile
301 row["ProfileBegin"] = s.ProfileBegin;
302 row["ProfileEnd"] = s.ProfileEnd;
303 row["ProfileCurve"] = s.ProfileCurve;
304 row["ProfileHollow"] = s.ProfileHollow;
305 // text TODO: this isn't right] = but I'm not sure the right
306 // way to specify this as a blob atm
307 row["Texture"] = s.TextureEntry;
308
277 } 309 }
278 310
279 private void addPrim(SceneObjectPart prim) 311 private void addPrim(SceneObjectPart prim)
@@ -293,7 +325,7 @@ namespace OpenSim.DataStore.MonoSqliteStorage
293 DataRow shapeRow = shapes.Rows.Find(prim.UUID); 325 DataRow shapeRow = shapes.Rows.Find(prim.UUID);
294 if (shapeRow == null) { 326 if (shapeRow == null) {
295 shapeRow = prims.NewRow(); 327 shapeRow = prims.NewRow();
296 fillShapeRow(shapeRow, prim.Shape); 328 fillShapeRow(shapeRow, prim);
297 prims.Rows.Add(shapeRow); 329 prims.Rows.Add(shapeRow);
298 } else { 330 } else {
299 fillPrimRow(shapeRow, prim); 331 fillPrimRow(shapeRow, prim);