aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ClientStack/Linden
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/ClientStack/Linden')
-rw-r--r--OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCaps.cs25
-rw-r--r--OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs25
2 files changed, 27 insertions, 23 deletions
diff --git a/OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCaps.cs b/OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCaps.cs
index 58b7b00..46932b1 100644
--- a/OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCaps.cs
+++ b/OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCaps.cs
@@ -1006,28 +1006,41 @@ namespace OpenSim.Region.ClientStack.Linden
1006 } 1006 }
1007 } 1007 }
1008 1008
1009 // faces number to pbs shape 1009 // faces number to pbs shape for viewers LOD
1010 switch(face_list.Count) 1010 // now extended to full faces equivalent
1011 int nfaces = face_list.Count;
1012 switch(nfaces)
1011 { 1013 {
1012 case 1: 1014 case 1:
1013 case 2: 1015 case 2:
1014 pbs.ProfileCurve = (byte)ProfileCurve.Circle; 1016 pbs.ProfileCurve = (byte)ProfileCurve.Circle | (byte)HollowShape.Triangle;
1015 pbs.PathCurve = (byte)PathCurve.Circle; 1017 pbs.PathCurve = (byte)PathCurve.Circle;
1018 if(nfaces == 2)
1019 pbs.ProfileHollow = 1;
1016 break; 1020 break;
1017 1021
1018 case 3: 1022 case 3:
1019 case 4: 1023 case 4:
1020 pbs.ProfileCurve = (byte)ProfileCurve.Circle; 1024 pbs.ProfileCurve = (byte)ProfileCurve.Circle | (byte)HollowShape.Triangle;
1021 pbs.PathCurve = (byte)PathCurve.Line; 1025 pbs.PathCurve = (byte)PathCurve.Line;
1026 if(nfaces == 4)
1027 pbs.ProfileHollow = 1;
1022 break; 1028 break;
1029
1023 case 5: 1030 case 5:
1024 pbs.ProfileCurve = (byte)ProfileCurve.EqualTriangle; 1031 pbs.ProfileCurve = (byte)ProfileCurve.EqualTriangle | (byte)HollowShape.Triangle;
1025 pbs.PathCurve = (byte)PathCurve.Line; 1032 pbs.PathCurve = (byte)PathCurve.Line;
1026 break; 1033 break;
1027 1034
1028 default: 1035 default:
1029 pbs.ProfileCurve = (byte)ProfileCurve.Square; 1036 // hack to flag that pbs does represent number of faces
1037 //meshs where never uploaded with this
1038 pbs.ProfileCurve = (byte)ProfileCurve.Square | (byte)HollowShape.Triangle;
1030 pbs.PathCurve = (byte)PathCurve.Line; 1039 pbs.PathCurve = (byte)PathCurve.Line;
1040 if(nfaces == 7)
1041 pbs.ProfileHollow = 1;
1042 else if(nfaces == 8)
1043 pbs.ProfileBegin = 1;
1031 break; 1044 break;
1032 } 1045 }
1033 1046
diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs
index dc8d267..cf96a8b 100644
--- a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs
+++ b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs
@@ -4212,12 +4212,13 @@ namespace OpenSim.Region.ClientStack.LindenUDP
4212 SceneObjectGroup grp = part.ParentGroup; 4212 SceneObjectGroup grp = part.ParentGroup;
4213 if (grp.inTransit && !update.Flags.HasFlag(PrimUpdateFlags.SendInTransit)) 4213 if (grp.inTransit && !update.Flags.HasFlag(PrimUpdateFlags.SendInTransit))
4214 continue; 4214 continue;
4215/* debug
4215 if (update.Flags.HasFlag(PrimUpdateFlags.SendInTransit)) 4216 if (update.Flags.HasFlag(PrimUpdateFlags.SendInTransit))
4216 { 4217 {
4217 4218
4218 4219
4219 } 4220 }
4220 4221*/
4221 if (grp.IsDeleted) 4222 if (grp.IsDeleted)
4222 { 4223 {
4223 // Don't send updates for objects that have been marked deleted. 4224 // Don't send updates for objects that have been marked deleted.
@@ -4274,14 +4275,6 @@ namespace OpenSim.Region.ClientStack.LindenUDP
4274 { 4275 {
4275 part.Shape.LightEntry = false; 4276 part.Shape.LightEntry = false;
4276 } 4277 }
4277
4278 if (part.Shape != null && (part.Shape.SculptType == (byte)SculptType.Mesh))
4279 {
4280 // Ensure that mesh has at least 8 valid faces
4281 part.Shape.ProfileBegin = 12500;
4282 part.Shape.ProfileEnd = 0;
4283 part.Shape.ProfileHollow = 27500;
4284 }
4285 } 4278 }
4286 4279
4287 if(doCulling && !grp.IsAttachment) 4280 if(doCulling && !grp.IsAttachment)
@@ -4309,14 +4302,6 @@ namespace OpenSim.Region.ClientStack.LindenUDP
4309 continue; 4302 continue;
4310 } 4303 }
4311 } 4304 }
4312
4313 if (part.Shape != null && (part.Shape.SculptType == (byte)SculptType.Mesh))
4314 {
4315 // Ensure that mesh has at least 8 valid faces
4316 part.Shape.ProfileBegin = 12500;
4317 part.Shape.ProfileEnd = 0;
4318 part.Shape.ProfileHollow = 27500;
4319 }
4320 } 4305 }
4321 else if (update.Entity is ScenePresence) 4306 else if (update.Entity is ScenePresence)
4322 { 4307 {
@@ -5877,6 +5862,12 @@ namespace OpenSim.Region.ClientStack.LindenUDP
5877 update.PCode = part.Shape.PCode; 5862 update.PCode = part.Shape.PCode;
5878 update.ProfileBegin = part.Shape.ProfileBegin; 5863 update.ProfileBegin = part.Shape.ProfileBegin;
5879 update.ProfileCurve = part.Shape.ProfileCurve; 5864 update.ProfileCurve = part.Shape.ProfileCurve;
5865
5866 if(part.Shape.SculptType == (byte)SculptType.Mesh) // filter out hack
5867 update.ProfileCurve = (byte)(part.Shape.ProfileCurve & 0x0f);
5868 else
5869 update.ProfileCurve = part.Shape.ProfileCurve;
5870
5880 update.ProfileEnd = part.Shape.ProfileEnd; 5871 update.ProfileEnd = part.Shape.ProfileEnd;
5881 update.ProfileHollow = part.Shape.ProfileHollow; 5872 update.ProfileHollow = part.Shape.ProfileHollow;
5882 update.PSBlock = part.ParticleSystem ?? Utils.EmptyBytes; 5873 update.PSBlock = part.ParticleSystem ?? Utils.EmptyBytes;