aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Physics/Meshing
diff options
context:
space:
mode:
authorDr Scofield2008-06-27 17:25:03 +0000
committerDr Scofield2008-06-27 17:25:03 +0000
commit7d55dfba8addd5c580e6c7bcf4449315428b84ed (patch)
tree8426d62dc435e54e5c7c58d2fa742a3841848727 /OpenSim/Region/Physics/Meshing
parentdr scofield's warning safari: (diff)
downloadopensim-SC_OLD-7d55dfba8addd5c580e6c7bcf4449315428b84ed.zip
opensim-SC_OLD-7d55dfba8addd5c580e6c7bcf4449315428b84ed.tar.gz
opensim-SC_OLD-7d55dfba8addd5c580e6c7bcf4449315428b84ed.tar.bz2
opensim-SC_OLD-7d55dfba8addd5c580e6c7bcf4449315428b84ed.tar.xz
dr scofield's warnings safari:
* commenting out unused variables
Diffstat (limited to 'OpenSim/Region/Physics/Meshing')
-rw-r--r--OpenSim/Region/Physics/Meshing/Extruder.cs12
-rw-r--r--OpenSim/Region/Physics/Meshing/HelperTypes.cs3
-rw-r--r--OpenSim/Region/Physics/Meshing/Meshmerizer.cs98
-rw-r--r--OpenSim/Region/Physics/Meshing/SculptMesh.cs2
4 files changed, 59 insertions, 56 deletions
diff --git a/OpenSim/Region/Physics/Meshing/Extruder.cs b/OpenSim/Region/Physics/Meshing/Extruder.cs
index baa2d9b..ac8d81c 100644
--- a/OpenSim/Region/Physics/Meshing/Extruder.cs
+++ b/OpenSim/Region/Physics/Meshing/Extruder.cs
@@ -259,8 +259,8 @@ namespace OpenSim.Region.Physics.Meshing
259 { 259 {
260 Mesh result = new Mesh(); 260 Mesh result = new Mesh();
261 261
262 Quaternion tt = new Quaternion(); 262 // Quaternion tt = new Quaternion();
263 Vertex v2 = new Vertex(0, 0, 0); 263 // Vertex v2 = new Vertex(0, 0, 0);
264 264
265 Mesh newLayer; 265 Mesh newLayer;
266 Mesh lastLayer = null; 266 Mesh lastLayer = null;
@@ -441,8 +441,8 @@ namespace OpenSim.Region.Physics.Meshing
441 { 441 {
442 Mesh result = new Mesh(); 442 Mesh result = new Mesh();
443 443
444 Quaternion tt = new Quaternion(); 444 // Quaternion tt = new Quaternion();
445 Vertex v2 = new Vertex(0, 0, 0); 445 // Vertex v2 = new Vertex(0, 0, 0);
446 446
447 Mesh newLayer; 447 Mesh newLayer;
448 Mesh lastLayer = null; 448 Mesh lastLayer = null;
@@ -457,8 +457,8 @@ namespace OpenSim.Region.Physics.Meshing
457 if (System.Math.Abs(twistTotal) > (float)System.Math.PI * 1.5f) steps *= 2; 457 if (System.Math.Abs(twistTotal) > (float)System.Math.PI * 1.5f) steps *= 2;
458 if (System.Math.Abs(twistTotal) > (float)System.Math.PI * 3.0f) steps *= 2; 458 if (System.Math.Abs(twistTotal) > (float)System.Math.PI * 3.0f) steps *= 2;
459 459
460 double percentOfPathMultiplier = 1.0 / steps; 460 // double percentOfPathMultiplier = 1.0 / steps;
461 double angleStepMultiplier = System.Math.PI * 2.0 / steps; 461 // double angleStepMultiplier = System.Math.PI * 2.0 / steps;
462 462
463 float yPathScale = pathScaleY * 0.5f; 463 float yPathScale = pathScaleY * 0.5f;
464 float pathLength = pathCutEnd - pathCutBegin; 464 float pathLength = pathCutEnd - pathCutBegin;
diff --git a/OpenSim/Region/Physics/Meshing/HelperTypes.cs b/OpenSim/Region/Physics/Meshing/HelperTypes.cs
index f031fb6..aed6c45 100644
--- a/OpenSim/Region/Physics/Meshing/HelperTypes.cs
+++ b/OpenSim/Region/Physics/Meshing/HelperTypes.cs
@@ -221,6 +221,7 @@ public class Vertex : PhysicsVector, IComparable<Vertex>
221 v1.Z += am; 221 v1.Z += am;
222 return v1; 222 return v1;
223 } 223 }
224
224 public static Vertex operator -(Vertex v1, float am) 225 public static Vertex operator -(Vertex v1, float am)
225 { 226 {
226 v1.X -= am; 227 v1.X -= am;
@@ -228,6 +229,7 @@ public class Vertex : PhysicsVector, IComparable<Vertex>
228 v1.Z -= am; 229 v1.Z -= am;
229 return v1; 230 return v1;
230 } 231 }
232
231 public static Vertex operator *(Vertex v1, float am) 233 public static Vertex operator *(Vertex v1, float am)
232 { 234 {
233 v1.X *= am; 235 v1.X *= am;
@@ -235,6 +237,7 @@ public class Vertex : PhysicsVector, IComparable<Vertex>
235 v1.Z *= am; 237 v1.Z *= am;
236 return v1; 238 return v1;
237 } 239 }
240
238 public static Vertex operator /(Vertex v1, float am) 241 public static Vertex operator /(Vertex v1, float am)
239 { 242 {
240 if (am == 0f) 243 if (am == 0f)
diff --git a/OpenSim/Region/Physics/Meshing/Meshmerizer.cs b/OpenSim/Region/Physics/Meshing/Meshmerizer.cs
index 5a04a8e..879129a 100644
--- a/OpenSim/Region/Physics/Meshing/Meshmerizer.cs
+++ b/OpenSim/Region/Physics/Meshing/Meshmerizer.cs
@@ -432,8 +432,8 @@ namespace OpenSim.Region.Physics.Meshing
432 UInt16 taperY = primShape.PathScaleY; 432 UInt16 taperY = primShape.PathScaleY;
433 UInt16 pathShearX = primShape.PathShearX; 433 UInt16 pathShearX = primShape.PathShearX;
434 UInt16 pathShearY = primShape.PathShearY; 434 UInt16 pathShearY = primShape.PathShearY;
435 Int16 twistTop = primShape.PathTwistBegin; 435 // Int16 twistTop = primShape.PathTwistBegin;
436 Int16 twistBot = primShape.PathTwist; 436 // Int16 twistBot = primShape.PathTwist;
437 437
438#if SPAM 438#if SPAM
439 reportPrimParams("[BOX] " + primName, primShape); 439 reportPrimParams("[BOX] " + primName, primShape);
@@ -690,8 +690,8 @@ namespace OpenSim.Region.Physics.Meshing
690 UInt16 taperY = primShape.PathScaleY; 690 UInt16 taperY = primShape.PathScaleY;
691 UInt16 pathShearX = primShape.PathShearX; 691 UInt16 pathShearX = primShape.PathShearX;
692 UInt16 pathShearY = primShape.PathShearY; 692 UInt16 pathShearY = primShape.PathShearY;
693 Int16 twistBot = primShape.PathTwist; 693 // Int16 twistBot = primShape.PathTwist;
694 Int16 twistTop = primShape.PathTwistBegin; 694 // Int16 twistTop = primShape.PathTwistBegin;
695 695
696#if SPAM 696#if SPAM
697 reportPrimParams("[CYLINDER] " + primName, primShape); 697 reportPrimParams("[CYLINDER] " + primName, primShape);
@@ -1043,8 +1043,8 @@ namespace OpenSim.Region.Physics.Meshing
1043 UInt16 pathShearX = primShape.PathShearX; 1043 UInt16 pathShearX = primShape.PathShearX;
1044 UInt16 pathShearY = primShape.PathShearY; 1044 UInt16 pathShearY = primShape.PathShearY;
1045 1045
1046 Int16 twistTop = primShape.PathTwistBegin; 1046 // Int16 twistTop = primShape.PathTwistBegin;
1047 Int16 twistBot = primShape.PathTwist; 1047 // Int16 twistBot = primShape.PathTwist;
1048 1048
1049#if SPAM 1049#if SPAM
1050 reportPrimParams("[PRISM] " + primName, primShape); 1050 reportPrimParams("[PRISM] " + primName, primShape);
@@ -1295,13 +1295,13 @@ namespace OpenSim.Region.Physics.Meshing
1295 1295
1296 // Still have more to do here. 1296 // Still have more to do here.
1297 1297
1298 UInt16 hollowFactor = primShape.ProfileHollow; 1298 // UInt16 hollowFactor = primShape.ProfileHollow;
1299 UInt16 profileBegin = primShape.ProfileBegin; 1299 // UInt16 profileBegin = primShape.ProfileBegin;
1300 UInt16 profileEnd = primShape.ProfileEnd; 1300 // UInt16 profileEnd = primShape.ProfileEnd;
1301 UInt16 taperX = primShape.PathScaleX; 1301 // UInt16 taperX = primShape.PathScaleX;
1302 UInt16 taperY = primShape.PathScaleY; 1302 // UInt16 taperY = primShape.PathScaleY;
1303 UInt16 pathShearX = primShape.PathShearX; 1303 // UInt16 pathShearX = primShape.PathShearX;
1304 UInt16 pathShearY = primShape.PathShearY; 1304 // UInt16 pathShearY = primShape.PathShearY;
1305 Mesh m = new Mesh(); 1305 Mesh m = new Mesh();
1306 1306
1307#if SPAM 1307#if SPAM
@@ -1424,12 +1424,12 @@ namespace OpenSim.Region.Physics.Meshing
1424 UInt16 hollowFactor = primShape.ProfileHollow; 1424 UInt16 hollowFactor = primShape.ProfileHollow;
1425 UInt16 profileBegin = primShape.ProfileBegin; 1425 UInt16 profileBegin = primShape.ProfileBegin;
1426 UInt16 profileEnd = primShape.ProfileEnd; 1426 UInt16 profileEnd = primShape.ProfileEnd;
1427 UInt16 taperX = primShape.PathScaleX; 1427 // UInt16 taperX = primShape.PathScaleX;
1428 UInt16 taperY = primShape.PathScaleY; 1428 // UInt16 taperY = primShape.PathScaleY;
1429 UInt16 pathShearX = primShape.PathShearX; 1429 UInt16 pathShearX = primShape.PathShearX;
1430 UInt16 pathShearY = primShape.PathShearY; 1430 UInt16 pathShearY = primShape.PathShearY;
1431 Int16 twistBot = primShape.PathTwist; 1431 // Int16 twistBot = primShape.PathTwist;
1432 Int16 twistTop = primShape.PathTwistBegin; 1432 // Int16 twistTop = primShape.PathTwistBegin;
1433 HollowShape hollowShape = primShape.HollowShape; 1433 HollowShape hollowShape = primShape.HollowShape;
1434 1434
1435#if SPAM 1435#if SPAM
@@ -1706,7 +1706,7 @@ namespace OpenSim.Region.Physics.Meshing
1706 foreach (Triangle t in m.triangles) 1706 foreach (Triangle t in m.triangles)
1707 t.invertNormal(); 1707 t.invertNormal();
1708 1708
1709 Vertex vTemp = new Vertex(0.0f, 0.0f, 0.0f); 1709 // Vertex vTemp = new Vertex(0.0f, 0.0f, 0.0f);
1710 1710
1711 1711
1712 float skew = primShape.PathSkew * 0.01f; 1712 float skew = primShape.PathSkew * 0.01f;
@@ -2038,36 +2038,36 @@ namespace OpenSim.Region.Physics.Meshing
2038 return mesh; 2038 return mesh;
2039 } 2039 }
2040 2040
2041 private static void reportPrimParams(string name, PrimitiveBaseShape primShape) 2041// private static void reportPrimParams(string name, PrimitiveBaseShape primShape)
2042 { 2042// {
2043#if SPAM 2043// #if SPAM
2044 float pathShearX = primShape.PathShearX < 128 ? (float)primShape.PathShearX * 0.01f : (float)(primShape.PathShearX - 256) * 0.01f; 2044// float pathShearX = primShape.PathShearX < 128 ? (float)primShape.PathShearX * 0.01f : (float)(primShape.PathShearX - 256) * 0.01f;
2045 float pathShearY = primShape.PathShearY < 128 ? (float)primShape.PathShearY * 0.01f : (float)(primShape.PathShearY - 256) * 0.01f; 2045// float pathShearY = primShape.PathShearY < 128 ? (float)primShape.PathShearY * 0.01f : (float)(primShape.PathShearY - 256) * 0.01f;
2046 2046
2047 Console.WriteLine("********************* PrimitiveBaseShape Parameters *******************\n" 2047// Console.WriteLine("********************* PrimitiveBaseShape Parameters *******************\n"
2048 + "Name.............: " + name.ToString() + "\n" 2048// + "Name.............: " + name.ToString() + "\n"
2049 + "HollowShape......: " + primShape.HollowShape.ToString() + "\n" 2049// + "HollowShape......: " + primShape.HollowShape.ToString() + "\n"
2050 + "PathBegin........: " + primShape.PathBegin.ToString() + "\n" 2050// + "PathBegin........: " + primShape.PathBegin.ToString() + "\n"
2051 + "PathCurve........: " + primShape.PathCurve.ToString() + "\n" 2051// + "PathCurve........: " + primShape.PathCurve.ToString() + "\n"
2052 + "PathEnd..........: " + primShape.PathEnd.ToString() + "\n" 2052// + "PathEnd..........: " + primShape.PathEnd.ToString() + "\n"
2053 + "PathRadiusOffset.: " + primShape.PathRadiusOffset.ToString() + "\n" 2053// + "PathRadiusOffset.: " + primShape.PathRadiusOffset.ToString() + "\n"
2054 + "PathRevolutions..: " + primShape.PathRevolutions.ToString() + "\n" 2054// + "PathRevolutions..: " + primShape.PathRevolutions.ToString() + "\n"
2055 + "PathScaleX.......: " + primShape.PathScaleX.ToString() + "\n" 2055// + "PathScaleX.......: " + primShape.PathScaleX.ToString() + "\n"
2056 + "PathScaleY.......: " + primShape.PathScaleY.ToString() + "\n" 2056// + "PathScaleY.......: " + primShape.PathScaleY.ToString() + "\n"
2057 + "PathShearX.......: " + primShape.PathShearX.ToString() + " (" + pathShearX.ToString() + ")\n" 2057// + "PathShearX.......: " + primShape.PathShearX.ToString() + " (" + pathShearX.ToString() + ")\n"
2058 + "PathShearY.......: " + primShape.PathShearY.ToString() + " (" + pathShearY.ToString() + ")\n" 2058// + "PathShearY.......: " + primShape.PathShearY.ToString() + " (" + pathShearY.ToString() + ")\n"
2059 + "PathSkew.........: " + primShape.PathSkew.ToString() + "\n" 2059// + "PathSkew.........: " + primShape.PathSkew.ToString() + "\n"
2060 + "PathTaperX.......: " + primShape.PathTaperX.ToString() + "\n" 2060// + "PathTaperX.......: " + primShape.PathTaperX.ToString() + "\n"
2061 + "PathTaperY.......: " + primShape.PathTaperY.ToString() + "\n" 2061// + "PathTaperY.......: " + primShape.PathTaperY.ToString() + "\n"
2062 + "PathTwist........: " + primShape.PathTwist.ToString() + "\n" 2062// + "PathTwist........: " + primShape.PathTwist.ToString() + "\n"
2063 + "PathTwistBegin...: " + primShape.PathTwistBegin.ToString() + "\n" 2063// + "PathTwistBegin...: " + primShape.PathTwistBegin.ToString() + "\n"
2064 + "ProfileBegin.....: " + primShape.ProfileBegin.ToString() + "\n" 2064// + "ProfileBegin.....: " + primShape.ProfileBegin.ToString() + "\n"
2065 + "ProfileCurve.....: " + primShape.ProfileCurve.ToString() + "\n" 2065// + "ProfileCurve.....: " + primShape.ProfileCurve.ToString() + "\n"
2066 + "ProfileEnd.......: " + primShape.ProfileEnd.ToString() + "\n" 2066// + "ProfileEnd.......: " + primShape.ProfileEnd.ToString() + "\n"
2067 + "ProfileHollow....: " + primShape.ProfileHollow.ToString() + "\n" 2067// + "ProfileHollow....: " + primShape.ProfileHollow.ToString() + "\n"
2068 + "ProfileShape.....: " + primShape.ProfileShape.ToString() + "\n" 2068// + "ProfileShape.....: " + primShape.ProfileShape.ToString() + "\n"
2069 ); 2069// );
2070#endif 2070// #endif
2071 } 2071// }
2072 } 2072 }
2073} 2073}
diff --git a/OpenSim/Region/Physics/Meshing/SculptMesh.cs b/OpenSim/Region/Physics/Meshing/SculptMesh.cs
index c9933fe..95a244d 100644
--- a/OpenSim/Region/Physics/Meshing/SculptMesh.cs
+++ b/OpenSim/Region/Physics/Meshing/SculptMesh.cs
@@ -223,7 +223,7 @@ namespace OpenSim.Region.Physics.Meshing
223 Vertex v1 = new Vertex(0,0,0); 223 Vertex v1 = new Vertex(0,0,0);
224 224
225 // Create a vertex position from the RGB channels in the current pixel 225 // Create a vertex position from the RGB channels in the current pixel
226 int ypos = y * bLOD.Width; 226 // int ypos = y * bLOD.Width;
227 227
228 228
229 if (y == 0) 229 if (y == 0)