Merge branch 'master' into bulletsim
commit
4cbc912375
|
@ -196,6 +196,9 @@ namespace OpenSim.Framework
|
|||
if (appearance.VisualParams != null)
|
||||
m_visualparams = (byte[])appearance.VisualParams.Clone();
|
||||
|
||||
m_avatarHeight = appearance.m_avatarHeight;
|
||||
m_hipOffset = appearance.m_hipOffset;
|
||||
|
||||
// Copy the attachment, force append mode since that ensures consistency
|
||||
m_attachments = new Dictionary<int, List<AvatarAttachment>>();
|
||||
foreach (AvatarAttachment attachment in appearance.GetAttachments())
|
||||
|
@ -237,7 +240,6 @@ namespace OpenSim.Framework
|
|||
{
|
||||
m_serial = 0;
|
||||
|
||||
SetDefaultParams();
|
||||
SetDefaultTexture();
|
||||
|
||||
//for (int i = 0; i < BAKE_INDICES.Length; i++)
|
||||
|
|
|
@ -760,7 +760,10 @@ namespace OpenSim.Framework
|
|||
"Clamp prims to max size", "false", true);
|
||||
|
||||
configMember.addConfigurationOption("object_capacity", ConfigurationOption.ConfigurationTypes.TYPE_INT32,
|
||||
"Max objects this sim will hold", "0", true);
|
||||
"Max objects this sim will hold", "15000", true);
|
||||
|
||||
configMember.addConfigurationOption("agent_capacity", ConfigurationOption.ConfigurationTypes.TYPE_INT32,
|
||||
"Max avatars this sim will hold", "100", true);
|
||||
|
||||
configMember.addConfigurationOption("scope_id", ConfigurationOption.ConfigurationTypes.TYPE_UUID,
|
||||
"Scope ID for this region", UUID.Zero.ToString(), true);
|
||||
|
|
|
@ -224,13 +224,13 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory
|
|||
// update transaction. In theory, we should be able to do an immediate
|
||||
// appearance send and save here.
|
||||
|
||||
}
|
||||
// save only if there were changes, send no matter what (doesn't hurt to send twice)
|
||||
if (changed)
|
||||
QueueAppearanceSave(client.AgentId);
|
||||
|
||||
QueueAppearanceSend(client.AgentId);
|
||||
}
|
||||
}
|
||||
|
||||
// m_log.WarnFormat("[AVFACTORY]: complete SetAppearance for {0}:\n{1}",client.AgentId,sp.Appearance.ToString());
|
||||
}
|
||||
|
@ -389,7 +389,7 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory
|
|||
// we need to clean out the existing textures
|
||||
sp.Appearance.ResetAppearance();
|
||||
|
||||
// operate on a copy of the appearance so we don't have to lock anything
|
||||
// operate on a copy of the appearance so we don't have to lock anything yet
|
||||
AvatarAppearance avatAppearance = new AvatarAppearance(sp.Appearance, false);
|
||||
|
||||
foreach (AvatarWearingArgs.Wearable wear in e.NowWearing)
|
||||
|
@ -403,13 +403,20 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory
|
|||
// This could take awhile since it needs to pull inventory
|
||||
SetAppearanceAssets(sp.UUID, ref avatAppearance);
|
||||
|
||||
// could get fancier with the locks here, but in the spirit of "last write wins"
|
||||
// this should work correctly, also, we don't need to send the appearance here
|
||||
// since the "iswearing" will trigger a new set of visual param and baked texture changes
|
||||
// when those complete, the new appearance will be sent
|
||||
sp.Appearance = avatAppearance;
|
||||
lock (m_setAppearanceLock)
|
||||
{
|
||||
// Update only those fields that we have changed. This is important because the viewer
|
||||
// often sends AvatarIsWearing and SetAppearance packets at once, and AvatarIsWearing
|
||||
// shouldn't overwrite the changes made in SetAppearance.
|
||||
sp.Appearance.Wearables = avatAppearance.Wearables;
|
||||
sp.Appearance.Texture = avatAppearance.Texture;
|
||||
|
||||
// We don't need to send the appearance here since the "iswearing" will trigger a new set
|
||||
// of visual param and baked texture changes. When those complete, the new appearance will be sent
|
||||
|
||||
QueueAppearanceSave(client.AgentId);
|
||||
}
|
||||
}
|
||||
|
||||
private void SetAppearanceAssets(UUID userID, ref AvatarAppearance appearance)
|
||||
{
|
||||
|
|
|
@ -1110,14 +1110,12 @@ namespace OpenSim.Region.CoreModules.World.WorldMap
|
|||
if (data == null)
|
||||
return;
|
||||
|
||||
UUID lastMapRegionUUID = m_scene.RegionInfo.RegionSettings.TerrainImageID;
|
||||
|
||||
m_log.Debug("[WORLDMAP]: STORING MAPTILE IMAGE");
|
||||
|
||||
m_scene.RegionInfo.RegionSettings.TerrainImageID = UUID.Random();
|
||||
UUID terrainImageID = UUID.Random();
|
||||
|
||||
AssetBase asset = new AssetBase(
|
||||
m_scene.RegionInfo.RegionSettings.TerrainImageID,
|
||||
terrainImageID,
|
||||
"terrainImage_" + m_scene.RegionInfo.RegionID.ToString(),
|
||||
(sbyte)AssetType.Texture,
|
||||
m_scene.RegionInfo.RegionID.ToString());
|
||||
|
@ -1129,6 +1127,10 @@ namespace OpenSim.Region.CoreModules.World.WorldMap
|
|||
// Store the new one
|
||||
m_log.DebugFormat("[WORLDMAP]: Storing map tile {0}", asset.ID);
|
||||
m_scene.AssetService.Store(asset);
|
||||
|
||||
// Switch to the new one
|
||||
UUID lastMapRegionUUID = m_scene.RegionInfo.RegionSettings.TerrainImageID;
|
||||
m_scene.RegionInfo.RegionSettings.TerrainImageID = terrainImageID;
|
||||
m_scene.RegionInfo.RegionSettings.Save();
|
||||
|
||||
// Delete the old one
|
||||
|
|
|
@ -1672,20 +1672,20 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
|
||||
m_sceneGridService.SetScene(this);
|
||||
|
||||
// If we generate maptiles internally at all, the maptile generator
|
||||
// will register the region. If not, do it here
|
||||
if (m_generateMaptiles)
|
||||
{
|
||||
RegenerateMaptile(null, null);
|
||||
}
|
||||
else
|
||||
{
|
||||
GridRegion region = new GridRegion(RegionInfo);
|
||||
string error = GridService.RegisterRegion(RegionInfo.ScopeID, region);
|
||||
if (error != String.Empty)
|
||||
{
|
||||
throw new Exception(error);
|
||||
}
|
||||
|
||||
// Generate the maptile asynchronously, because sometimes it can be very slow and we
|
||||
// don't want this to delay starting the region.
|
||||
if (m_generateMaptiles)
|
||||
{
|
||||
Util.FireAndForget(delegate {
|
||||
RegenerateMaptile(null, null);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -48,6 +48,13 @@ namespace OpenSim.Services.Connectors
|
|||
private string m_ServerURI = String.Empty;
|
||||
private IImprovedAssetCache m_Cache = null;
|
||||
|
||||
private delegate void AssetRetrievedEx(AssetBase asset);
|
||||
|
||||
// Keeps track of concurrent requests for the same asset, so that it's only loaded once.
|
||||
// Maps: Asset ID -> Handlers which will be called when the asset has been loaded
|
||||
private Dictionary<string, AssetRetrievedEx> m_AssetHandlers = new Dictionary<string, AssetRetrievedEx>();
|
||||
|
||||
|
||||
public AssetServicesConnector()
|
||||
{
|
||||
}
|
||||
|
@ -178,23 +185,56 @@ namespace OpenSim.Services.Connectors
|
|||
|
||||
if (asset == null)
|
||||
{
|
||||
bool result = false;
|
||||
lock (m_AssetHandlers)
|
||||
{
|
||||
AssetRetrievedEx handlerEx = new AssetRetrievedEx(delegate(AssetBase _asset) { handler(id, sender, _asset); });
|
||||
|
||||
AsynchronousRestObjectRequester.
|
||||
MakeRequest<int, AssetBase>("GET", uri, 0,
|
||||
AssetRetrievedEx handlers;
|
||||
if (m_AssetHandlers.TryGetValue(id, out handlers))
|
||||
{
|
||||
// Someone else is already loading this asset. It will notify our handler when done.
|
||||
handlers += handlerEx;
|
||||
return true;
|
||||
}
|
||||
|
||||
// Load the asset ourselves
|
||||
handlers += handlerEx;
|
||||
m_AssetHandlers.Add(id, handlers);
|
||||
}
|
||||
|
||||
bool success = false;
|
||||
try
|
||||
{
|
||||
AsynchronousRestObjectRequester.MakeRequest<int, AssetBase>("GET", uri, 0,
|
||||
delegate(AssetBase a)
|
||||
{
|
||||
if (m_Cache != null)
|
||||
m_Cache.Cache(a);
|
||||
handler(id, sender, a);
|
||||
result = true;
|
||||
|
||||
AssetRetrievedEx handlers;
|
||||
lock (m_AssetHandlers)
|
||||
{
|
||||
handlers = m_AssetHandlers[id];
|
||||
m_AssetHandlers.Remove(id);
|
||||
}
|
||||
handlers.Invoke(a);
|
||||
});
|
||||
|
||||
return result;
|
||||
success = true;
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (!success)
|
||||
{
|
||||
lock (m_AssetHandlers)
|
||||
{
|
||||
m_AssetHandlers.Remove(id);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
//Util.FireAndForget(delegate { handler(id, sender, asset); });
|
||||
handler(id, sender, asset);
|
||||
}
|
||||
|
||||
|
|
BIN
bin/MXP.pdb
BIN
bin/MXP.pdb
Binary file not shown.
|
@ -68,15 +68,6 @@
|
|||
;; in a <Regions> tag.
|
||||
; regionload_webserver_url = "http://example.com/regions.xml";
|
||||
|
||||
;# {TextureOnMapTile} {} {Use terrain textures for map tiles?} {true false} false
|
||||
;; Use terrain texture for maptiles if true, use shaded green if false
|
||||
; TextureOnMapTile = false
|
||||
|
||||
;# {DrawPrimOnMapTile} {} {Draw prim shapes on map tiles?} {true false} false
|
||||
;; Draw objects on maptile. This step might take a long time if you've
|
||||
;; got a large number of objects, so you can turn it off here if you'd like.
|
||||
; DrawPrimOnMapTile = true
|
||||
|
||||
;# {NonPhysicalPrimMax} {} {Maximum size of nonphysical prims?} {} 256
|
||||
;; Maximum size for non-physical prims. Affects resizing of existing prims. This can be overriden in the region config file (as NonphysicalPrimMax!).
|
||||
; NonPhysicalPrimMax = 256
|
||||
|
@ -190,7 +181,7 @@
|
|||
;; Map tile options. You can choose to generate no map tiles at all,
|
||||
;; generate normal maptiles, or nominate an uploaded texture to
|
||||
;; be the map tile
|
||||
; GenerateMaptiles = "true"
|
||||
; GenerateMaptiles = true
|
||||
|
||||
;; If desired, a running region can update the map tiles periodically
|
||||
;; to reflect building activity. This names no sense of you don't have
|
||||
|
@ -200,6 +191,15 @@
|
|||
;; If not generating maptiles, use this static texture asset ID
|
||||
; MaptileStaticUUID = "00000000-0000-0000-0000-000000000000"
|
||||
|
||||
;# {TextureOnMapTile} {} {Use terrain textures for map tiles?} {true false} true
|
||||
;; Use terrain texture for maptiles if true, use shaded green if false
|
||||
; TextureOnMapTile = true
|
||||
|
||||
;# {DrawPrimOnMapTile} {} {Draw prim shapes on map tiles?} {true false} false
|
||||
;; Draw objects on maptile. This step might take a long time if you've
|
||||
;; got a large number of objects, so you can turn it off here if you'd like.
|
||||
; DrawPrimOnMapTile = true
|
||||
|
||||
;; Http proxy setting for llHTTPRequest and dynamic texture loading, if required
|
||||
; HttpProxy = "http://proxy.com:8080"
|
||||
|
||||
|
@ -218,7 +218,7 @@
|
|||
;; The SMTP server enabled the email module to send email to external
|
||||
;; destinations.
|
||||
|
||||
;# {enabled} {[Startup]emailmodule:DefaultEmailModule} {Enable SMTP service?} {true false} true
|
||||
;# {enabled} {[Startup]emailmodule:DefaultEmailModule} {Enable SMTP service?} {true false} false
|
||||
;; Enable sending email via SMTP
|
||||
; enabled = false
|
||||
|
||||
|
|
|
@ -67,12 +67,6 @@
|
|||
; except that everything is also enclosed in a <Regions> tag.
|
||||
; regionload_webserver_url = "http://example.com/regions.xml";
|
||||
|
||||
; Draw objects on maptile. This step might take a long time if you've got a large number of
|
||||
; objects, so you can turn it off here if you'd like.
|
||||
DrawPrimOnMapTile = true
|
||||
; Use terrain texture for maptiles if true, use shaded green if false
|
||||
TextureOnMapTile = false
|
||||
|
||||
; Maximum size of non physical prims. Affects resizing of existing prims. This can be overriden in the region config file (as NonphysicalPrimMax!).
|
||||
NonPhysicalPrimMax = 256
|
||||
|
||||
|
@ -216,13 +210,23 @@
|
|||
|
||||
;WorldMapModule = "WorldMap"
|
||||
;MapImageModule = "MapImageModule"
|
||||
|
||||
; Set to false to not generate any maptiles
|
||||
;GenerateMaptiles = "true"
|
||||
;GenerateMaptiles = true
|
||||
|
||||
; Refresh (in seconds) the map tile periodically
|
||||
;MaptileRefresh = 0
|
||||
|
||||
; If not generating maptiles, use this static texture asset ID
|
||||
;MaptileStaticUUID = "00000000-0000-0000-0000-000000000000"
|
||||
|
||||
; Draw objects on maptile. This step might take a long time if you've got a large number of
|
||||
; objects, so you can turn it off here if you'd like.
|
||||
DrawPrimOnMapTile = true
|
||||
|
||||
; Use terrain texture for maptiles if true, use shaded green if false
|
||||
TextureOnMapTile = true
|
||||
|
||||
; ##
|
||||
; ## EMAIL MODULE
|
||||
; ##
|
||||
|
@ -273,15 +277,15 @@
|
|||
|
||||
|
||||
[SMTP]
|
||||
enabled=false
|
||||
enabled = false
|
||||
|
||||
;enabled=true
|
||||
;internal_object_host=lsl.opensim.local
|
||||
;host_domain_header_from=127.0.0.1
|
||||
;SMTP_SERVER_HOSTNAME=127.0.0.1
|
||||
;SMTP_SERVER_PORT=25
|
||||
;SMTP_SERVER_LOGIN=foo
|
||||
;SMTP_SERVER_PASSWORD=bar
|
||||
;enabled = true
|
||||
;internal_object_host = lsl.opensim.local
|
||||
;host_domain_header_from = 127.0.0.1
|
||||
;SMTP_SERVER_HOSTNAME = 127.0.0.1
|
||||
;SMTP_SERVER_PORT = 25
|
||||
;SMTP_SERVER_LOGIN = foo
|
||||
;SMTP_SERVER_PASSWORD = bar
|
||||
|
||||
|
||||
[Network]
|
||||
|
|
Binary file not shown.
Loading…
Reference in New Issue