From 853e90ea8014ac9c4fb02cb2d2eeffa8ab473f85 Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Mon, 8 Nov 2010 10:37:58 -0500 Subject: removed unused variable --- indra/newview/llfasttimerview.cpp | 1 - 1 file changed, 1 deletion(-) diff --git a/indra/newview/llfasttimerview.cpp b/indra/newview/llfasttimerview.cpp index 027eb09e55..4bcbe665aa 100755 --- a/indra/newview/llfasttimerview.cpp +++ b/indra/newview/llfasttimerview.cpp @@ -1463,7 +1463,6 @@ void LLFastTimerView::doAnalysisDefault(std::string baseline, std::string target std::ofstream os(output.c_str()); LLSD::Real session_time = current["SessionTime"].asReal(); - //LLSD::Real frame_count = current["FrameCount"].asReal(); os << "Label, " "% Change, " -- cgit v1.2.3 From d9c0e0ba74d3f042ae7f3a7310f0c0bf23e6eaa9 Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Fri, 12 Nov 2010 17:31:27 -0500 Subject: SH-275 FIX: non-production grids now default to different source of map tiles --- indra/newview/app_settings/settings.xml | 0 indra/newview/llstartup.cpp | 5 +++++ 2 files changed, 5 insertions(+) mode change 100644 => 100755 indra/newview/app_settings/settings.xml mode change 100644 => 100755 indra/newview/llstartup.cpp diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml old mode 100644 new mode 100755 diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp old mode 100644 new mode 100755 index 5ee4599200..230dfaea51 --- a/indra/newview/llstartup.cpp +++ b/indra/newview/llstartup.cpp @@ -3071,6 +3071,11 @@ bool process_login_success_response() } // Request the map server url + // Non-agni grids have a different default location. + if (!LLGridManager::getInstance()->isInProductionGrid()) + { + gSavedSettings.setString("MapServerURL", "http://test.map.secondlife.com.s3.amazonaws.com/"); + } std::string map_server_url = response["map-server-url"]; if(!map_server_url.empty()) { -- cgit v1.2.3 From 6400374986a5c8413f425ef62959cc6dd274742f Mon Sep 17 00:00:00 2001 From: Nyx Linden Date: Wed, 17 Nov 2010 13:59:17 -0500 Subject: SH-432 mesh viewer will not run on OSX 10.5.8 Rebuilt the collada library on a 10.5 machine. this should fix the issue, as the problem was we were building against a version of libxml2 that was specific to 10.6. Will update to use a non-system version of the lib later. --- install.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/install.xml b/install.xml index ed8e4851cf..ad3e9a92a2 100644 --- a/install.xml +++ b/install.xml @@ -266,9 +266,9 @@ darwin md5sum - 88a61580d10994694cbec74c14cb38de + 86de85fa85aa58b5ee550a6a3c77a7d3 url - http://s3.amazonaws.com/viewer-source-downloads/install_pkgs/colladadom-2.1-darwin-20101116.tar.bz2 + http://s3.amazonaws.com/viewer-source-downloads/install_pkgs/colladadom-2.1-darwin-20101117.tar.bz2 linux -- cgit v1.2.3 From 29852bc012afbed303159b895ae8dc9448500ca5 Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Wed, 17 Nov 2010 15:01:41 -0500 Subject: SH-476 FIX. Map tiles were failing when numeric addrs were substituted in amazon S3 image queries --- indra/newview/llmeshrepository.cpp | 54 +++++++++++++++++++++----------------- 1 file changed, 30 insertions(+), 24 deletions(-) mode change 100644 => 100755 indra/newview/llmeshrepository.cpp diff --git a/indra/newview/llmeshrepository.cpp b/indra/newview/llmeshrepository.cpp old mode 100644 new mode 100755 index 94ed2697c5..b26f2dd0de --- a/indra/newview/llmeshrepository.cpp +++ b/indra/newview/llmeshrepository.cpp @@ -105,36 +105,42 @@ U32 get_volume_memory_size(const LLVolume* volume) std::string scrub_host_name(std::string http_url) { //curl loves to abuse the DNS cache, so scrub host names out of urls where trivial to prevent DNS timeouts + + if (http_url.empty()) + { + return http_url; + } + // Not safe to scrub amazon paths + if (http_url.find("s3.amazonaws.com") != std::string::npos) + { + return http_url; + } + std::string::size_type begin_host = http_url.find("://")+3; + std::string host_string = http_url.substr(begin_host); - if (!http_url.empty()) + std::string::size_type end_host = host_string.find(":"); + if (end_host == std::string::npos) { - std::string::size_type begin_host = http_url.find("://")+3; - std::string host_string = http_url.substr(begin_host); - - std::string::size_type end_host = host_string.find(":"); - if (end_host == std::string::npos) - { - end_host = host_string.find("/"); - } - - host_string = host_string.substr(0, end_host); + end_host = host_string.find("/"); + } + + host_string = host_string.substr(0, end_host); + + std::string::size_type idx = http_url.find(host_string); + + hostent* ent = gethostbyname(host_string.c_str()); + + if (ent && ent->h_length > 0) + { + U8* addr = (U8*) ent->h_addr_list[0]; - std::string::size_type idx = http_url.find(host_string); - - hostent* ent = gethostbyname(host_string.c_str()); - - if (ent && ent->h_length > 0) + std::string ip_string = llformat("%d.%d.%d.%d", addr[0], addr[1], addr[2], addr[3]); + if (!ip_string.empty() && !host_string.empty() && idx != std::string::npos) { - U8* addr = (U8*) ent->h_addr_list[0]; - - std::string ip_string = llformat("%d.%d.%d.%d", addr[0], addr[1], addr[2], addr[3]); - if (!ip_string.empty() && !host_string.empty() && idx != std::string::npos) - { - http_url.replace(idx, host_string.length(), ip_string); - } + http_url.replace(idx, host_string.length(), ip_string); } } - + return http_url; } -- cgit v1.2.3 From 48e2ec0340272efcb5caa7c5affaabfbf8d69c78 Mon Sep 17 00:00:00 2001 From: "Nyx (Neal Orman)" Date: Wed, 17 Nov 2010 20:04:30 -0500 Subject: SH-480 FIX meshes are not added to objects folder on upload curl host scrubbing was causing object creation for mesh prims to fail. Commenting out the offending lines so we can have a functional release. Will file a separate bug for Vir to investigate when/if we can re-enable host scrubbing on these URLs for a future release. Approach approved by davep. --- indra/newview/llmeshrepository.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/indra/newview/llmeshrepository.cpp b/indra/newview/llmeshrepository.cpp index f00a8565f7..1313033f4e 100644 --- a/indra/newview/llmeshrepository.cpp +++ b/indra/newview/llmeshrepository.cpp @@ -1409,8 +1409,8 @@ LLMeshUploadThread::LLMeshUploadThread(LLMeshUploadThread::instance_list& data, mUploadObjectAssetCapability = gAgent.getRegion()->getCapability("UploadObjectAsset"); mNewInventoryCapability = gAgent.getRegion()->getCapability("NewFileAgentInventoryVariablePrice"); - mUploadObjectAssetCapability = scrub_host_name(mUploadObjectAssetCapability); - mNewInventoryCapability = scrub_host_name(mNewInventoryCapability); + //mUploadObjectAssetCapability = scrub_host_name(mUploadObjectAssetCapability); + //mNewInventoryCapability = scrub_host_name(mNewInventoryCapability); mOrigin += gAgent.getAtAxis() * scale.magVec(); } -- cgit v1.2.3 From 5e57352e1295d33cf9815800393212824d53bb75 Mon Sep 17 00:00:00 2001 From: "Nyx (Neal Orman)" Date: Thu, 18 Nov 2010 16:42:57 -0500 Subject: SH-350 SH-351 SH-355 FIX Several fixes for ARC Fixed the texture resolution calculation against the rounding errors we had before. Fixed the bug where linking prims changed the combined cost Fixed the bug where twisting was not computed properly Code reviewed by davep. --- indra/cmake/APR.cmake | 2 +- indra/cmake/Copy3rdPartyLibs.cmake | 1 - indra/cmake/ViewerMiscLibs.cmake | 1 - indra/newview/llfloatertools.cpp | 35 ++-------------------- indra/newview/llfloatertools.h | 1 - indra/newview/llselectmgr.cpp | 27 +++++++++++++++++ indra/newview/llselectmgr.h | 1 + indra/newview/llvovolume.cpp | 59 +++++++++++++------------------------- install.xml | 19 ------------ 9 files changed, 51 insertions(+), 95 deletions(-) diff --git a/indra/cmake/APR.cmake b/indra/cmake/APR.cmake index 180504d286..b6f1e06edd 100644 --- a/indra/cmake/APR.cmake +++ b/indra/cmake/APR.cmake @@ -56,7 +56,7 @@ else (STANDALONE) if (LINUX) if (VIEWER) - list(APPEND APRUTIL_LIBRARIES ${DB_LIBRARIES} uuid) + list(APPEND APRUTIL_LIBRARIES ${DB_LIBRARIES}) endif (VIEWER) list(APPEND APRUTIL_LIBRARIES ${DB_LIBRARIES} rt) endif (LINUX) diff --git a/indra/cmake/Copy3rdPartyLibs.cmake b/indra/cmake/Copy3rdPartyLibs.cmake index 9081752287..798cf9af14 100644 --- a/indra/cmake/Copy3rdPartyLibs.cmake +++ b/indra/cmake/Copy3rdPartyLibs.cmake @@ -241,7 +241,6 @@ elseif(LINUX) libstacktrace.so libtcmalloc_minimal.so libtcmalloc_minimal.so.0 - libuuid.so.1 libssl.so.0.9.7 ) diff --git a/indra/cmake/ViewerMiscLibs.cmake b/indra/cmake/ViewerMiscLibs.cmake index 32c4bc81df..5710360de2 100644 --- a/indra/cmake/ViewerMiscLibs.cmake +++ b/indra/cmake/ViewerMiscLibs.cmake @@ -2,7 +2,6 @@ include(Prebuilt) if (NOT STANDALONE) - use_prebuilt_binary(libuuid) use_prebuilt_binary(vivox) use_prebuilt_binary(fontconfig) endif(NOT STANDALONE) diff --git a/indra/newview/llfloatertools.cpp b/indra/newview/llfloatertools.cpp index b9b94488cf..920bdef7f6 100644 --- a/indra/newview/llfloatertools.cpp +++ b/indra/newview/llfloatertools.cpp @@ -450,7 +450,8 @@ void LLFloaterTools::refresh() if (sShowObjectCost) { std::string prim_cost_string; - LLResMgr::getInstance()->getIntegerString(prim_cost_string, calcRenderCost()); + S32 cost = LLSelectMgr::getInstance()->getSelection()->getSelectedObjectRenderCost(); + LLResMgr::getInstance()->getIntegerString(prim_cost_string, cost); getChild("RenderingCost")->setTextArg("[COUNT]", prim_cost_string); } @@ -1000,38 +1001,6 @@ void LLFloaterTools::onClickGridOptions() //floaterp->addDependentFloater(LLFloaterBuildOptions::getInstance(), FALSE); } -S32 LLFloaterTools::calcRenderCost() -{ - S32 cost = 0; - LLVOVolume::texture_cost_t textures; - - for (LLObjectSelection::iterator selection_iter = LLSelectMgr::getInstance()->getSelection()->begin(); - selection_iter != LLSelectMgr::getInstance()->getSelection()->end(); - ++selection_iter) - { - LLSelectNode *select_node = *selection_iter; - if (select_node) - { - LLViewerObject *vobj = select_node->getObject(); - if (vobj->getVolume()) - { - LLVOVolume* volume = (LLVOVolume*) vobj; - - cost += volume->getRenderCost(textures); - for (LLVOVolume::texture_cost_t::iterator iter = textures.begin(); iter != textures.end(); ++iter) - { - // add the cost of each individual texture in the linkset - cost += iter->second; - } - textures.clear(); - } - } - } - - - return cost; -} - // static void LLFloaterTools::setEditTool(void* tool_pointer) { diff --git a/indra/newview/llfloatertools.h b/indra/newview/llfloatertools.h index 87c3d2ab47..d5595445e0 100644 --- a/indra/newview/llfloatertools.h +++ b/indra/newview/llfloatertools.h @@ -114,7 +114,6 @@ private: static bool multipleFacesSelectedConfirm(const LLSD& notification, const LLSD& response); static void setObjectType( LLPCode pcode ); void onClickGridOptions(); - S32 calcRenderCost(); public: LLButton *mBtnFocus; diff --git a/indra/newview/llselectmgr.cpp b/indra/newview/llselectmgr.cpp index 728694117c..eb1ca66334 100644 --- a/indra/newview/llselectmgr.cpp +++ b/indra/newview/llselectmgr.cpp @@ -6335,6 +6335,33 @@ U32 LLObjectSelection::getSelectedObjectTriangleCount() return count; } +S32 LLObjectSelection::getSelectedObjectRenderCost() +{ + S32 cost = 0; + LLVOVolume::texture_cost_t textures; + for (list_t::iterator iter = mList.begin(); iter != mList.end(); ++iter) + { + LLSelectNode* node = *iter; + LLVOVolume* object = (LLVOVolume*)node->getObject(); + + if (object) + { + cost += object->getRenderCost(textures); + } + + for (LLVOVolume::texture_cost_t::iterator iter = textures.begin(); iter != textures.end(); ++iter) + { + // add the cost of each individual texture in the linkset + cost += iter->second; + llinfos << "adding texture cost of: " << iter->second << llendl; + } + textures.clear(); + } + + + return cost; +} + //----------------------------------------------------------------------------- // getTECount() diff --git a/indra/newview/llselectmgr.h b/indra/newview/llselectmgr.h index e0f76bd5dd..0cf582062d 100644 --- a/indra/newview/llselectmgr.h +++ b/indra/newview/llselectmgr.h @@ -284,6 +284,7 @@ public: F32 getSelectedLinksetCost(); F32 getSelectedPhysicsCost(); F32 getSelectedLinksetPhysicsCost(); + S32 getSelectedObjectRenderCost(); F32 getSelectedObjectStreamingCost(); U32 getSelectedObjectTriangleCount(); diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp index fe11570cf6..9aebfcba4a 100644 --- a/indra/newview/llvovolume.cpp +++ b/indra/newview/llvovolume.cpp @@ -2940,15 +2940,18 @@ U32 LLVOVolume::getRenderCost(texture_cost_t &textures) const U32 flexi = 0; U32 animtex = 0; U32 particles = 0; - U32 scale = 0; U32 bump = 0; U32 planar = 0; U32 cuts = 0; U32 hollow = 0; - U32 twist = 0; U32 circular_profile = 0; U32 circular_path = 0; + // these multipliers are variable and can be floating point + F32 scale = 0.f; + F32 twist = 0.f; + + const LLDrawable* drawablep = mDrawable; if (isSculpted()) @@ -2992,7 +2995,7 @@ U32 LLVOVolume::getRenderCost(texture_cost_t &textures) const LLViewerFetchedTexture *texture = LLViewerTextureManager::getFetchedTexture(sculpt_id); if (texture) { - S32 texture_cost = ARC_TEXTURE_COST * (texture->getFullHeight() / 128 + texture->getFullWidth() / 128 + 1); + S32 texture_cost = (S32)(ARC_TEXTURE_COST * (texture->getFullHeight() / 128.f + texture->getFullWidth() / 128.f + 1)); textures.insert(texture_cost_t::value_type(sculpt_id, texture_cost)); } } @@ -3009,11 +3012,11 @@ U32 LLVOVolume::getRenderCost(texture_cost_t &textures) const } const LLVector3& sc = getScale(); - scale += (U32) sc.mV[0] + (U32) sc.mV[1] + (U32) sc.mV[2]; - if (scale > 4) + scale += sc.mV[0] + sc.mV[1] + sc.mV[2]; + if (scale > 4.f) { // scale is a multiplier, cap it at 4. - scale = 4; + scale = 4.f; } // add points for cut prims @@ -3033,19 +3036,15 @@ U32 LLVOVolume::getRenderCost(texture_cost_t &textures) const hollow = 1; } - // twist - scale by twist extent / 90 - if (volume_params.getTwistBegin() != 0.f) + F32 twist_mag = path_params.getTwistBegin() - path_params.getTwistEnd(); + if (twist_mag < 0) { - U32 scale = abs((S32)(volume_params.getTwistBegin() / 90.f) + 1); - twist += scale; + twist_mag *= -1.f; } - // twist - scale by twist extent / 90 - if (volume_params.getTwist() != 0.f) - { - U32 scale = abs((S32)(volume_params.getTwist() / 90.f) + 1); - twist += scale; - } + // note magnitude of twist is [-1.f, 1.f]. which translates to [-180, 180] degrees. + // scale to degrees / 90 by multiplying by 2. + twist = twist_mag * 2.f; // double cost for circular profiles / sculpties if (profile_params.getCurveType() == LL_PCODE_PROFILE_CIRCLE || @@ -3079,7 +3078,7 @@ U32 LLVOVolume::getRenderCost(texture_cost_t &textures) const { if (textures.find(img->getID()) == textures.end()) { - S32 texture_cost = ARC_TEXTURE_COST * (img->getFullHeight() / 128 + img->getFullWidth() / 128 + 1); + S32 texture_cost = (S32)(ARC_TEXTURE_COST * (img->getFullHeight() / 128.f + img->getFullWidth() / 128.f + 1)); textures.insert(texture_cost_t::value_type(img->getID(), texture_cost)); } } @@ -3136,9 +3135,9 @@ U32 LLVOVolume::getRenderCost(texture_cost_t &textures) const shame *= hollow * ARC_HOLLOW_MULT; } - if (twist) + if (twist > 1.f) { - shame *= twist; + shame = (U32)(shame * twist); } if (circular_profile) @@ -3171,33 +3170,15 @@ U32 LLVOVolume::getRenderCost(texture_cost_t &textures) const shame *= shiny * ARC_SHINY_MULT; } - if (scale) + if (scale > 1.f) { - shame *= scale; + shame = (U32)(shame *scale); } // add additional costs shame += particles * ARC_PARTICLE_COST; - LLViewerObject::const_child_list_t& child_list = getChildren(); - for (LLViewerObject::child_list_t::const_iterator iter = child_list.begin(); - iter != child_list.end(); - ++iter) - { - const LLViewerObject* child_objectp = *iter; - const LLDrawable* child_drawablep = child_objectp->mDrawable; - if (child_drawablep) - { - const LLVOVolume* child_volumep = child_drawablep->getVOVolume(); - if (child_volumep) - { - shame += child_volumep->getRenderCost(textures); - } - } - } - return shame; - } F32 LLVOVolume::getStreamingCost() diff --git a/install.xml b/install.xml index ad3e9a92a2..fc374f8c96 100644 --- a/install.xml +++ b/install.xml @@ -1004,25 +1004,6 @@ anguage Infrstructure (CLI) international standard - libuuid - - copyright - Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/> - description - Generates UUIDs under Linux. Originally a part of the ext2fs filesystem. Also see lluuid.cpp for all platforms. Part of the e2fsprogs package. - license - lgpl - packages - - linux - - md5sum - 91b194aed4b38bc23493b198009a8c6a - url - http://s3.amazonaws.com/viewer-source-downloads/install_pkgs/libuuid-linux-20090417.tar.bz2 - - - libxml license -- cgit v1.2.3 From 896dc4c583ac93a53d9fc054c66227279268ccab Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Thu, 18 Nov 2010 17:15:11 -0500 Subject: Added build params for mesh-development --- BuildParams | 9 +++++++++ 1 file changed, 9 insertions(+) mode change 100644 => 100755 BuildParams diff --git a/BuildParams b/BuildParams old mode 100644 new mode 100755 index 3247bcdbdb..481be00167 --- a/BuildParams +++ b/BuildParams @@ -80,6 +80,15 @@ brad-parabuild.email = brad@lindenlab.com brad-parabuild.build_server = false brad-parabuild.build_server_tests = false +# ======================================== +# mesh-development +# ======================================== +mesh-development.viewer_channel = "Project Viewer - Mesh" +mesh-development.login_channel = "Project Viewer - Mesh" +mesh-development.viewer_grid = aditi +mesh-development.build_debug_release_separately = true +mesh-development.build_viewer_update_version_manager = false + # ======================================== # viewer-mesh # ======================================== -- cgit v1.2.3 From 52f397ec7a0f0698ea24c05c1bd538ec17161714 Mon Sep 17 00:00:00 2001 From: "Nyx (Neal Orman)" Date: Thu, 18 Nov 2010 17:28:13 -0500 Subject: SH-350 SH-351 SH-355 FIX ARC fixes Had a few debugging lines in my last checkin. Cleaning up unreviewed changes. --- indra/cmake/APR.cmake | 2 +- indra/cmake/Copy3rdPartyLibs.cmake | 3 ++- indra/cmake/ViewerMiscLibs.cmake | 1 + indra/newview/llselectmgr.cpp | 1 - install.xml | 19 +++++++++++++++++++ 5 files changed, 23 insertions(+), 3 deletions(-) diff --git a/indra/cmake/APR.cmake b/indra/cmake/APR.cmake index b6f1e06edd..180504d286 100644 --- a/indra/cmake/APR.cmake +++ b/indra/cmake/APR.cmake @@ -56,7 +56,7 @@ else (STANDALONE) if (LINUX) if (VIEWER) - list(APPEND APRUTIL_LIBRARIES ${DB_LIBRARIES}) + list(APPEND APRUTIL_LIBRARIES ${DB_LIBRARIES} uuid) endif (VIEWER) list(APPEND APRUTIL_LIBRARIES ${DB_LIBRARIES} rt) endif (LINUX) diff --git a/indra/cmake/Copy3rdPartyLibs.cmake b/indra/cmake/Copy3rdPartyLibs.cmake index 798cf9af14..93cdf3422c 100644 --- a/indra/cmake/Copy3rdPartyLibs.cmake +++ b/indra/cmake/Copy3rdPartyLibs.cmake @@ -241,7 +241,8 @@ elseif(LINUX) libstacktrace.so libtcmalloc_minimal.so libtcmalloc_minimal.so.0 - libssl.so.0.9.7 + libuuid.so.1 + libssl.so.0.9.7 ) if (FMOD) diff --git a/indra/cmake/ViewerMiscLibs.cmake b/indra/cmake/ViewerMiscLibs.cmake index 5710360de2..32c4bc81df 100644 --- a/indra/cmake/ViewerMiscLibs.cmake +++ b/indra/cmake/ViewerMiscLibs.cmake @@ -2,6 +2,7 @@ include(Prebuilt) if (NOT STANDALONE) + use_prebuilt_binary(libuuid) use_prebuilt_binary(vivox) use_prebuilt_binary(fontconfig) endif(NOT STANDALONE) diff --git a/indra/newview/llselectmgr.cpp b/indra/newview/llselectmgr.cpp index eb1ca66334..305b629cf7 100644 --- a/indra/newview/llselectmgr.cpp +++ b/indra/newview/llselectmgr.cpp @@ -6353,7 +6353,6 @@ S32 LLObjectSelection::getSelectedObjectRenderCost() { // add the cost of each individual texture in the linkset cost += iter->second; - llinfos << "adding texture cost of: " << iter->second << llendl; } textures.clear(); } diff --git a/install.xml b/install.xml index fc374f8c96..ad3e9a92a2 100644 --- a/install.xml +++ b/install.xml @@ -1004,6 +1004,25 @@ anguage Infrstructure (CLI) international standard + libuuid + + copyright + Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/> + description + Generates UUIDs under Linux. Originally a part of the ext2fs filesystem. Also see lluuid.cpp for all platforms. Part of the e2fsprogs package. + license + lgpl + packages + + linux + + md5sum + 91b194aed4b38bc23493b198009a8c6a + url + http://s3.amazonaws.com/viewer-source-downloads/install_pkgs/libuuid-linux-20090417.tar.bz2 + + + libxml license -- cgit v1.2.3