diff options
author | Jacek Antonelli | 2008-08-15 23:45:45 -0500 |
---|---|---|
committer | Jacek Antonelli | 2008-08-15 23:45:45 -0500 |
commit | b1831d23bfdd0c876ac8cf687d6d3cf02345e28e (patch) | |
tree | e977d6563859940ad05af08b7bc150f57a7cb548 /linden | |
parent | Second Life viewer sources 1.20.3 (diff) | |
download | meta-impy-b1831d23bfdd0c876ac8cf687d6d3cf02345e28e.zip meta-impy-b1831d23bfdd0c876ac8cf687d6d3cf02345e28e.tar.gz meta-impy-b1831d23bfdd0c876ac8cf687d6d3cf02345e28e.tar.bz2 meta-impy-b1831d23bfdd0c876ac8cf687d6d3cf02345e28e.tar.xz |
Second Life viewer sources 1.20.4
Diffstat (limited to '')
-rw-r--r-- | linden/indra/llcommon/llversionviewer.h | 2 | ||||
-rw-r--r-- | linden/indra/llimage/llimage.cpp | 5 | ||||
-rw-r--r-- | linden/indra/llmath/llvolumemgr.cpp | 28 | ||||
-rw-r--r-- | linden/indra/llmath/llvolumemgr.h | 1 | ||||
-rw-r--r-- | linden/indra/llrender/llimagegl.cpp | 14 | ||||
-rw-r--r-- | linden/indra/llxml/llcontrol.cpp | 33 | ||||
-rw-r--r-- | linden/indra/llxml/llcontrol.h | 2 | ||||
-rw-r--r-- | linden/indra/newview/app_settings/settings.xml | 2 | ||||
-rw-r--r-- | linden/indra/newview/lldynamictexture.cpp | 6 | ||||
-rw-r--r-- | linden/indra/newview/llfloateranimpreview.cpp | 3 | ||||
-rw-r--r-- | linden/indra/newview/llfloaterimagepreview.cpp | 8 | ||||
-rw-r--r-- | linden/indra/newview/llglsandbox.cpp | 35 | ||||
-rw-r--r-- | linden/indra/newview/llimpanel.cpp | 4 | ||||
-rw-r--r-- | linden/indra/newview/lltexlayer.cpp | 4 | ||||
-rw-r--r-- | linden/indra/newview/lltoolmorph.cpp | 5 | ||||
-rw-r--r-- | linden/indra/newview/llviewermenu.cpp | 4 | ||||
-rw-r--r-- | linden/indra/newview/llviewermessage.cpp | 2 | ||||
-rw-r--r-- | linden/indra/newview/llvovolume.cpp | 20 | ||||
-rw-r--r-- | linden/indra/newview/releasenotes.txt | 8 |
19 files changed, 137 insertions, 49 deletions
diff --git a/linden/indra/llcommon/llversionviewer.h b/linden/indra/llcommon/llversionviewer.h index 747526f..b81fb8d 100644 --- a/linden/indra/llcommon/llversionviewer.h +++ b/linden/indra/llcommon/llversionviewer.h | |||
@@ -34,7 +34,7 @@ | |||
34 | 34 | ||
35 | const S32 LL_VERSION_MAJOR = 1; | 35 | const S32 LL_VERSION_MAJOR = 1; |
36 | const S32 LL_VERSION_MINOR = 20; | 36 | const S32 LL_VERSION_MINOR = 20; |
37 | const S32 LL_VERSION_PATCH = 3; | 37 | const S32 LL_VERSION_PATCH = 4; |
38 | const S32 LL_VERSION_BUILD = 0; | 38 | const S32 LL_VERSION_BUILD = 0; |
39 | 39 | ||
40 | const char * const LL_CHANNEL = "Second Life Release"; | 40 | const char * const LL_CHANNEL = "Second Life Release"; |
diff --git a/linden/indra/llimage/llimage.cpp b/linden/indra/llimage/llimage.cpp index 3600cce..65d19de 100644 --- a/linden/indra/llimage/llimage.cpp +++ b/linden/indra/llimage/llimage.cpp | |||
@@ -768,8 +768,8 @@ void LLImageRaw::copyScaled( LLImageRaw* src ) | |||
768 | LLMemType mt1((LLMemType::EMemType)mMemType); | 768 | LLMemType mt1((LLMemType::EMemType)mMemType); |
769 | LLImageRaw* dst = this; // Just for clarity. | 769 | LLImageRaw* dst = this; // Just for clarity. |
770 | 770 | ||
771 | llassert( (1 == src->getComponents()) || (3 == src->getComponents()) || (4 == src->getComponents()) ); | 771 | llassert_always( (1 == src->getComponents()) || (3 == src->getComponents()) || (4 == src->getComponents()) ); |
772 | llassert( src->getComponents() == dst->getComponents() ); | 772 | llassert_always( src->getComponents() == dst->getComponents() ); |
773 | 773 | ||
774 | if( (src->getWidth() == dst->getWidth()) && (src->getHeight() == dst->getHeight()) ) | 774 | if( (src->getWidth() == dst->getWidth()) && (src->getHeight() == dst->getHeight()) ) |
775 | { | 775 | { |
@@ -779,6 +779,7 @@ void LLImageRaw::copyScaled( LLImageRaw* src ) | |||
779 | 779 | ||
780 | // Vertical | 780 | // Vertical |
781 | S32 temp_data_size = src->getWidth() * dst->getHeight() * getComponents(); | 781 | S32 temp_data_size = src->getWidth() * dst->getHeight() * getComponents(); |
782 | llassert_always(temp_data_size > 0); | ||
782 | U8* temp_buffer = new U8[ temp_data_size ]; | 783 | U8* temp_buffer = new U8[ temp_data_size ]; |
783 | for( S32 col = 0; col < src->getWidth(); col++ ) | 784 | for( S32 col = 0; col < src->getWidth(); col++ ) |
784 | { | 785 | { |
diff --git a/linden/indra/llmath/llvolumemgr.cpp b/linden/indra/llmath/llvolumemgr.cpp index 0b49bb3..0b5464c 100644 --- a/linden/indra/llmath/llvolumemgr.cpp +++ b/linden/indra/llmath/llvolumemgr.cpp | |||
@@ -77,11 +77,8 @@ BOOL LLVolumeMgr::cleanup() | |||
77 | iter != end; iter++) | 77 | iter != end; iter++) |
78 | { | 78 | { |
79 | LLVolumeLODGroup *volgroupp = iter->second; | 79 | LLVolumeLODGroup *volgroupp = iter->second; |
80 | if (volgroupp->getNumRefs() != 0) | 80 | if (volgroupp->cleanupRefs() == false) |
81 | { | 81 | { |
82 | llwarns << "Volume group " << volgroupp << " has " | ||
83 | << volgroupp->getNumRefs() << " remaining refs" << llendl; | ||
84 | llwarns << *volgroupp->getVolumeParams() << llendl; | ||
85 | no_refs = FALSE; | 82 | no_refs = FALSE; |
86 | } | 83 | } |
87 | delete volgroupp; | 84 | delete volgroupp; |
@@ -274,6 +271,29 @@ LLVolumeLODGroup::~LLVolumeLODGroup() | |||
274 | } | 271 | } |
275 | } | 272 | } |
276 | 273 | ||
274 | // Called from LLVolumeMgr::cleanup | ||
275 | bool LLVolumeLODGroup::cleanupRefs() | ||
276 | { | ||
277 | bool res = true; | ||
278 | if (mRefs != 0) | ||
279 | { | ||
280 | llwarns << "Volume group has remaining refs:" << getNumRefs() << llendl; | ||
281 | mRefs = 0; | ||
282 | for (S32 i = 0; i < NUM_LODS; i++) | ||
283 | { | ||
284 | if (mLODRefs[i] > 0) | ||
285 | { | ||
286 | llwarns << " LOD " << i << " refs = " << mLODRefs[i] << llendl; | ||
287 | mLODRefs[i] = 0; | ||
288 | mVolumeLODs[i] = NULL; | ||
289 | } | ||
290 | } | ||
291 | llwarns << *getVolumeParams() << llendl; | ||
292 | res = false; | ||
293 | } | ||
294 | return res; | ||
295 | } | ||
296 | |||
277 | LLVolume* LLVolumeLODGroup::getLODVolume(const S32 detail) | 297 | LLVolume* LLVolumeLODGroup::getLODVolume(const S32 detail) |
278 | { | 298 | { |
279 | llassert(detail >=0 && detail < NUM_LODS); | 299 | llassert(detail >=0 && detail < NUM_LODS); |
diff --git a/linden/indra/llmath/llvolumemgr.h b/linden/indra/llmath/llvolumemgr.h index 8f107f6..dcaca01 100644 --- a/linden/indra/llmath/llvolumemgr.h +++ b/linden/indra/llmath/llvolumemgr.h | |||
@@ -53,6 +53,7 @@ public: | |||
53 | 53 | ||
54 | LLVolumeLODGroup(const LLVolumeParams ¶ms); | 54 | LLVolumeLODGroup(const LLVolumeParams ¶ms); |
55 | ~LLVolumeLODGroup(); | 55 | ~LLVolumeLODGroup(); |
56 | bool cleanupRefs(); | ||
56 | 57 | ||
57 | static S32 getDetailFromTan(const F32 tan_angle); | 58 | static S32 getDetailFromTan(const F32 tan_angle); |
58 | static void getDetailProximity(const F32 tan_angle, F32 &to_lower, F32& to_higher); | 59 | static void getDetailProximity(const F32 tan_angle, F32 &to_lower, F32& to_higher); |
diff --git a/linden/indra/llrender/llimagegl.cpp b/linden/indra/llrender/llimagegl.cpp index c4b90a7..92d8eb4 100644 --- a/linden/indra/llrender/llimagegl.cpp +++ b/linden/indra/llrender/llimagegl.cpp | |||
@@ -615,18 +615,25 @@ void LLImageGL::setImage(const U8* data_in, BOOL data_hasmips) | |||
615 | S32 w = width, h = height; | 615 | S32 w = width, h = height; |
616 | const U8* prev_mip_data = 0; | 616 | const U8* prev_mip_data = 0; |
617 | const U8* cur_mip_data = 0; | 617 | const U8* cur_mip_data = 0; |
618 | S32 prev_mip_size = 0; | ||
619 | S32 cur_mip_size = 0; | ||
618 | for (int m=0; m<nummips; m++) | 620 | for (int m=0; m<nummips; m++) |
619 | { | 621 | { |
620 | if (m==0) | 622 | if (m==0) |
621 | { | 623 | { |
622 | cur_mip_data = data_in; | 624 | cur_mip_data = data_in; |
625 | cur_mip_size = width * height * mComponents; | ||
623 | } | 626 | } |
624 | else | 627 | else |
625 | { | 628 | { |
626 | S32 bytes = w * h * mComponents; | 629 | S32 bytes = w * h * mComponents; |
630 | llassert(prev_mip_data); | ||
631 | llassert(prev_mip_size == bytes); | ||
627 | U8* new_data = new U8[bytes]; | 632 | U8* new_data = new U8[bytes]; |
633 | llassert_always(new_data); | ||
628 | LLImageBase::generateMip(prev_mip_data, new_data, w, h, mComponents); | 634 | LLImageBase::generateMip(prev_mip_data, new_data, w, h, mComponents); |
629 | cur_mip_data = new_data; | 635 | cur_mip_data = new_data; |
636 | cur_mip_size = bytes; | ||
630 | } | 637 | } |
631 | llassert(w > 0 && h > 0 && cur_mip_data); | 638 | llassert(w > 0 && h > 0 && cur_mip_data); |
632 | { | 639 | { |
@@ -651,12 +658,14 @@ void LLImageGL::setImage(const U8* data_in, BOOL data_hasmips) | |||
651 | delete[] prev_mip_data; | 658 | delete[] prev_mip_data; |
652 | } | 659 | } |
653 | prev_mip_data = cur_mip_data; | 660 | prev_mip_data = cur_mip_data; |
661 | prev_mip_size = cur_mip_size; | ||
654 | w >>= 1; | 662 | w >>= 1; |
655 | h >>= 1; | 663 | h >>= 1; |
656 | } | 664 | } |
657 | if (prev_mip_data && prev_mip_data != data_in) | 665 | if (prev_mip_data && prev_mip_data != data_in) |
658 | { | 666 | { |
659 | delete[] prev_mip_data; | 667 | delete[] prev_mip_data; |
668 | prev_mip_data = NULL; | ||
660 | } | 669 | } |
661 | } | 670 | } |
662 | } | 671 | } |
@@ -1058,6 +1067,7 @@ BOOL LLImageGL::readBackRaw(S32 discard_level, LLImageRaw* imageraw, bool compre | |||
1058 | llerrs << llformat("LLImageGL::readBackRaw: bogus params: %d x %d x %d",width,height,ncomponents) << llendl; | 1067 | llerrs << llformat("LLImageGL::readBackRaw: bogus params: %d x %d x %d",width,height,ncomponents) << llendl; |
1059 | } | 1068 | } |
1060 | 1069 | ||
1070 | BOOL return_result = TRUE ; | ||
1061 | LLGLint is_compressed = 0; | 1071 | LLGLint is_compressed = 0; |
1062 | if (compressed_ok) | 1072 | if (compressed_ok) |
1063 | { | 1073 | { |
@@ -1073,6 +1083,7 @@ BOOL LLImageGL::readBackRaw(S32 discard_level, LLImageRaw* imageraw, bool compre | |||
1073 | { | 1083 | { |
1074 | llwarns << "Error happens when reading back the compressed texture image." << llendl ; | 1084 | llwarns << "Error happens when reading back the compressed texture image." << llendl ; |
1075 | imageraw->deleteData() ; | 1085 | imageraw->deleteData() ; |
1086 | return_result = FALSE ; | ||
1076 | } | 1087 | } |
1077 | stop_glerror(); | 1088 | stop_glerror(); |
1078 | } | 1089 | } |
@@ -1084,11 +1095,12 @@ BOOL LLImageGL::readBackRaw(S32 discard_level, LLImageRaw* imageraw, bool compre | |||
1084 | { | 1095 | { |
1085 | llwarns << "Error happens when reading back the texture image." << llendl ; | 1096 | llwarns << "Error happens when reading back the texture image." << llendl ; |
1086 | imageraw->deleteData() ; | 1097 | imageraw->deleteData() ; |
1098 | return_result = FALSE ; | ||
1087 | } | 1099 | } |
1088 | stop_glerror(); | 1100 | stop_glerror(); |
1089 | } | 1101 | } |
1090 | 1102 | ||
1091 | return TRUE; | 1103 | return return_result ; |
1092 | } | 1104 | } |
1093 | 1105 | ||
1094 | void LLImageGL::destroyGLTexture() | 1106 | void LLImageGL::destroyGLTexture() |
diff --git a/linden/indra/llxml/llcontrol.cpp b/linden/indra/llxml/llcontrol.cpp index 18292d2..8c74127 100644 --- a/linden/indra/llxml/llcontrol.cpp +++ b/linden/indra/llxml/llcontrol.cpp | |||
@@ -953,7 +953,7 @@ U32 LLControlGroup::saveToFile(const LLString& filename, BOOL nondefault_only) | |||
953 | return num_saved; | 953 | return num_saved; |
954 | } | 954 | } |
955 | 955 | ||
956 | U32 LLControlGroup::loadFromFile(const LLString& filename, BOOL require_declaration, eControlType declare_as) | 956 | U32 LLControlGroup::loadFromFile(const LLString& filename) |
957 | { | 957 | { |
958 | LLString name; | 958 | LLString name; |
959 | LLSD settings; | 959 | LLSD settings; |
@@ -965,24 +965,47 @@ U32 LLControlGroup::loadFromFile(const LLString& filename, BOOL require_declarat | |||
965 | llwarns << "Cannot find file " << filename << " to load." << llendl; | 965 | llwarns << "Cannot find file " << filename << " to load." << llendl; |
966 | return 0; | 966 | return 0; |
967 | } | 967 | } |
968 | |||
968 | S32 ret = LLSDSerialize::fromXML(settings, infile); | 969 | S32 ret = LLSDSerialize::fromXML(settings, infile); |
970 | |||
969 | if (ret <= 0) | 971 | if (ret <= 0) |
970 | { | 972 | { |
971 | infile.close(); | 973 | infile.close(); |
972 | llwarns << "Unable to open LLSD control file " << filename << ". Trying Legacy Method." << llendl; | 974 | llwarns << "Unable to open LLSD control file " << filename << ". Trying Legacy Method." << llendl; |
973 | return loadFromFileLegacy(filename, require_declaration, declare_as); | 975 | return loadFromFileLegacy(filename, TRUE, TYPE_STRING); |
974 | } | 976 | } |
975 | 977 | ||
976 | U32 validitems = 0; | 978 | U32 validitems = 0; |
977 | int persist = 1; | 979 | int persist = 1; |
978 | for(LLSD::map_const_iterator itr = settings.beginMap(); itr != settings.endMap(); ++itr) | 980 | for(LLSD::map_const_iterator itr = settings.beginMap(); itr != settings.endMap(); ++itr) |
979 | { | 981 | { |
980 | name = (*itr).first; | 982 | name = (*itr).first; |
981 | control_map = (*itr).second; | 983 | control_map = (*itr).second; |
982 | 984 | ||
983 | if(control_map.has("Persist")) persist = control_map["Persist"].asInteger(); | 985 | if(control_map.has("Persist")) |
986 | { | ||
987 | persist = control_map["Persist"].asInteger(); | ||
988 | } | ||
984 | 989 | ||
985 | declareControl(name, typeStringToEnum(control_map["Type"].asString()), control_map["Value"], control_map["Comment"].asString(), persist); | 990 | // If the control exists just set the value from the input file. |
991 | LLControlVariable* existing_control = getControl(name); | ||
992 | if(existing_control) | ||
993 | { | ||
994 | // Check persistence. If not persisted, we shouldn't be loading. | ||
995 | if(existing_control->isPersisted()) | ||
996 | { | ||
997 | existing_control->setValue(control_map["Value"]); | ||
998 | } | ||
999 | } | ||
1000 | else | ||
1001 | { | ||
1002 | declareControl(name, | ||
1003 | typeStringToEnum(control_map["Type"].asString()), | ||
1004 | control_map["Value"], | ||
1005 | control_map["Comment"].asString(), | ||
1006 | persist | ||
1007 | ); | ||
1008 | } | ||
986 | 1009 | ||
987 | ++validitems; | 1010 | ++validitems; |
988 | } | 1011 | } |
diff --git a/linden/indra/llxml/llcontrol.h b/linden/indra/llxml/llcontrol.h index 9e11628..2511940 100644 --- a/linden/indra/llxml/llcontrol.h +++ b/linden/indra/llxml/llcontrol.h | |||
@@ -213,7 +213,7 @@ public: | |||
213 | // as the given type. | 213 | // as the given type. |
214 | U32 loadFromFileLegacy(const LLString& filename, BOOL require_declaration = TRUE, eControlType declare_as = TYPE_STRING); | 214 | U32 loadFromFileLegacy(const LLString& filename, BOOL require_declaration = TRUE, eControlType declare_as = TYPE_STRING); |
215 | U32 saveToFile(const LLString& filename, BOOL nondefault_only); | 215 | U32 saveToFile(const LLString& filename, BOOL nondefault_only); |
216 | U32 loadFromFile(const LLString& filename, BOOL require_declaration = TRUE, eControlType declare_as = TYPE_STRING); | 216 | U32 loadFromFile(const LLString& filename); |
217 | void resetToDefaults(); | 217 | void resetToDefaults(); |
218 | 218 | ||
219 | 219 | ||
diff --git a/linden/indra/newview/app_settings/settings.xml b/linden/indra/newview/app_settings/settings.xml index 7be1db3..2bfac48 100644 --- a/linden/indra/newview/app_settings/settings.xml +++ b/linden/indra/newview/app_settings/settings.xml | |||
@@ -5763,7 +5763,7 @@ | |||
5763 | <key>RenderUseCleverUI</key> | 5763 | <key>RenderUseCleverUI</key> |
5764 | <map> | 5764 | <map> |
5765 | <key>Comment</key> | 5765 | <key>Comment</key> |
5766 | <string>Turns on the \"clever\" UI rendering optimization. It's a known performace gain (and enabled by default) on apple.</string> | 5766 | <string>Turns on the \"clever\" UI rendering optimization. It's a known performace gain on apple.</string> |
5767 | <key>Persist</key> | 5767 | <key>Persist</key> |
5768 | <integer>1</integer> | 5768 | <integer>1</integer> |
5769 | <key>Type</key> | 5769 | <key>Type</key> |
diff --git a/linden/indra/newview/lldynamictexture.cpp b/linden/indra/newview/lldynamictexture.cpp index 14b80d6..6bcf140 100644 --- a/linden/indra/newview/lldynamictexture.cpp +++ b/linden/indra/newview/lldynamictexture.cpp | |||
@@ -223,17 +223,15 @@ BOOL LLDynamicTexture::updateAllInstances() | |||
223 | glClear(GL_DEPTH_BUFFER_BIT); | 223 | glClear(GL_DEPTH_BUFFER_BIT); |
224 | gDisplaySwapBuffers = FALSE; | 224 | gDisplaySwapBuffers = FALSE; |
225 | 225 | ||
226 | LLVertexBuffer::startRender(); | ||
227 | gGL.start(); | ||
228 | |||
229 | dynamicTexture->preRender(); // Must be called outside of startRender() | 226 | dynamicTexture->preRender(); // Must be called outside of startRender() |
230 | 227 | ||
228 | LLVertexBuffer::startRender(); | ||
229 | |||
231 | if (dynamicTexture->render()) | 230 | if (dynamicTexture->render()) |
232 | { | 231 | { |
233 | result = TRUE; | 232 | result = TRUE; |
234 | sNumRenders++; | 233 | sNumRenders++; |
235 | } | 234 | } |
236 | gGL.stop(); | ||
237 | LLVertexBuffer::stopRender(); | 235 | LLVertexBuffer::stopRender(); |
238 | 236 | ||
239 | dynamicTexture->postRender(result); | 237 | dynamicTexture->postRender(result); |
diff --git a/linden/indra/newview/llfloateranimpreview.cpp b/linden/indra/newview/llfloateranimpreview.cpp index 1ea0495..317636e 100644 --- a/linden/indra/newview/llfloateranimpreview.cpp +++ b/linden/indra/newview/llfloateranimpreview.cpp | |||
@@ -1038,6 +1038,8 @@ BOOL LLPreviewAnimation::render() | |||
1038 | { | 1038 | { |
1039 | mNeedsUpdate = FALSE; | 1039 | mNeedsUpdate = FALSE; |
1040 | LLVOAvatar* avatarp = mDummyAvatar; | 1040 | LLVOAvatar* avatarp = mDummyAvatar; |
1041 | |||
1042 | gGL.start(); | ||
1041 | 1043 | ||
1042 | glMatrixMode(GL_PROJECTION); | 1044 | glMatrixMode(GL_PROJECTION); |
1043 | gGL.pushMatrix(); | 1045 | gGL.pushMatrix(); |
@@ -1108,7 +1110,6 @@ BOOL LLPreviewAnimation::render() | |||
1108 | avatarPoolp->renderAvatars(avatarp); // renders only one avatar | 1110 | avatarPoolp->renderAvatars(avatarp); // renders only one avatar |
1109 | } | 1111 | } |
1110 | 1112 | ||
1111 | gGL.start(); | ||
1112 | return TRUE; | 1113 | return TRUE; |
1113 | } | 1114 | } |
1114 | 1115 | ||
diff --git a/linden/indra/newview/llfloaterimagepreview.cpp b/linden/indra/newview/llfloaterimagepreview.cpp index 7b1c8cc..f1f7ff6 100644 --- a/linden/indra/newview/llfloaterimagepreview.cpp +++ b/linden/indra/newview/llfloaterimagepreview.cpp | |||
@@ -667,6 +667,8 @@ void LLImagePreviewAvatar::setPreviewTarget(const char* joint_name, const char* | |||
667 | //----------------------------------------------------------------------------- | 667 | //----------------------------------------------------------------------------- |
668 | BOOL LLImagePreviewAvatar::render() | 668 | BOOL LLImagePreviewAvatar::render() |
669 | { | 669 | { |
670 | gGL.start(); | ||
671 | |||
670 | mNeedsUpdate = FALSE; | 672 | mNeedsUpdate = FALSE; |
671 | LLVOAvatar* avatarp = mDummyAvatar; | 673 | LLVOAvatar* avatarp = mDummyAvatar; |
672 | 674 | ||
@@ -723,8 +725,6 @@ BOOL LLImagePreviewAvatar::render() | |||
723 | avatarPoolp->renderAvatars(avatarp); // renders only one avatar | 725 | avatarPoolp->renderAvatars(avatarp); // renders only one avatar |
724 | } | 726 | } |
725 | 727 | ||
726 | gGL.start(); | ||
727 | |||
728 | return TRUE; | 728 | return TRUE; |
729 | } | 729 | } |
730 | 730 | ||
@@ -823,6 +823,8 @@ void LLImagePreviewSculpted::setPreviewTarget(LLImageRaw* imagep, F32 distance) | |||
823 | //----------------------------------------------------------------------------- | 823 | //----------------------------------------------------------------------------- |
824 | BOOL LLImagePreviewSculpted::render() | 824 | BOOL LLImagePreviewSculpted::render() |
825 | { | 825 | { |
826 | gGL.start(); | ||
827 | |||
826 | mNeedsUpdate = FALSE; | 828 | mNeedsUpdate = FALSE; |
827 | 829 | ||
828 | LLGLSUIDefault def; | 830 | LLGLSUIDefault def; |
@@ -917,6 +919,8 @@ BOOL LLImagePreviewSculpted::render() | |||
917 | delete [] normals; | 919 | delete [] normals; |
918 | } | 920 | } |
919 | 921 | ||
922 | gGL.stop(); | ||
923 | |||
920 | return TRUE; | 924 | return TRUE; |
921 | } | 925 | } |
922 | 926 | ||
diff --git a/linden/indra/newview/llglsandbox.cpp b/linden/indra/newview/llglsandbox.cpp index 28b92fd..f63eaf3 100644 --- a/linden/indra/newview/llglsandbox.cpp +++ b/linden/indra/newview/llglsandbox.cpp | |||
@@ -1006,17 +1006,17 @@ void LLViewerObjectList::renderObjectBeacons() | |||
1006 | return; | 1006 | return; |
1007 | } | 1007 | } |
1008 | 1008 | ||
1009 | S32 i; | ||
1010 | //const LLFontGL *font = LLResMgr::getInstance()->getRes(LLFONT_SANSSERIF); | 1009 | //const LLFontGL *font = LLResMgr::getInstance()->getRes(LLFONT_SANSSERIF); |
1011 | 1010 | ||
1012 | LLGLSUIDefault gls_ui; | 1011 | LLGLSUIDefault gls_ui; |
1013 | 1012 | ||
1014 | S32 last_line_width = -1; | ||
1015 | |||
1016 | { | 1013 | { |
1017 | LLGLSNoTexture gls_ui_no_texture; | 1014 | LLGLSNoTexture gls_ui_no_texture; |
1018 | gGL.begin(GL_LINES); | 1015 | |
1019 | for (i = 0; i < mDebugBeacons.count(); i++) | 1016 | S32 last_line_width = -1; |
1017 | // gGL.begin(GL_LINES); // Always happens in (line_width != last_line_width) | ||
1018 | |||
1019 | for (S32 i = 0; i < mDebugBeacons.count(); i++) | ||
1020 | { | 1020 | { |
1021 | const LLDebugBeacon &debug_beacon = mDebugBeacons[i]; | 1021 | const LLDebugBeacon &debug_beacon = mDebugBeacons[i]; |
1022 | LLColor4 color = debug_beacon.mColor; | 1022 | LLColor4 color = debug_beacon.mColor; |
@@ -1024,8 +1024,11 @@ void LLViewerObjectList::renderObjectBeacons() | |||
1024 | S32 line_width = debug_beacon.mLineWidth; | 1024 | S32 line_width = debug_beacon.mLineWidth; |
1025 | if (line_width != last_line_width) | 1025 | if (line_width != last_line_width) |
1026 | { | 1026 | { |
1027 | gGL.end(); | 1027 | if (i > 0) |
1028 | gGL.flush(); | 1028 | { |
1029 | gGL.end(); | ||
1030 | gGL.flush(); | ||
1031 | } | ||
1029 | glLineWidth( (F32)line_width ); | 1032 | glLineWidth( (F32)line_width ); |
1030 | last_line_width = line_width; | 1033 | last_line_width = line_width; |
1031 | gGL.begin(GL_LINES); | 1034 | gGL.begin(GL_LINES); |
@@ -1049,17 +1052,21 @@ void LLViewerObjectList::renderObjectBeacons() | |||
1049 | LLGLSNoTexture gls_ui_no_texture; | 1052 | LLGLSNoTexture gls_ui_no_texture; |
1050 | LLGLDepthTest gls_depth(GL_TRUE); | 1053 | LLGLDepthTest gls_depth(GL_TRUE); |
1051 | 1054 | ||
1052 | gGL.begin(GL_LINES); | 1055 | S32 last_line_width = -1; |
1053 | last_line_width = -1; | 1056 | // gGL.begin(GL_LINES); // Always happens in (line_width != last_line_width) |
1054 | for (i = 0; i < mDebugBeacons.count(); i++) | 1057 | |
1058 | for (S32 i = 0; i < mDebugBeacons.count(); i++) | ||
1055 | { | 1059 | { |
1056 | const LLDebugBeacon &debug_beacon = mDebugBeacons[i]; | 1060 | const LLDebugBeacon &debug_beacon = mDebugBeacons[i]; |
1057 | 1061 | ||
1058 | S32 line_width = debug_beacon.mLineWidth; | 1062 | S32 line_width = debug_beacon.mLineWidth; |
1059 | if (line_width != last_line_width) | 1063 | if (line_width != last_line_width) |
1060 | { | 1064 | { |
1061 | gGL.end(); | 1065 | if (i > 0) |
1062 | gGL.flush(); | 1066 | { |
1067 | gGL.end(); | ||
1068 | gGL.flush(); | ||
1069 | } | ||
1063 | glLineWidth( (F32)line_width ); | 1070 | glLineWidth( (F32)line_width ); |
1064 | last_line_width = line_width; | 1071 | last_line_width = line_width; |
1065 | gGL.begin(GL_LINES); | 1072 | gGL.begin(GL_LINES); |
@@ -1076,12 +1083,12 @@ void LLViewerObjectList::renderObjectBeacons() | |||
1076 | 1083 | ||
1077 | draw_line_cube(0.10f, thisline); | 1084 | draw_line_cube(0.10f, thisline); |
1078 | } | 1085 | } |
1086 | |||
1079 | gGL.end(); | 1087 | gGL.end(); |
1080 | |||
1081 | gGL.flush(); | 1088 | gGL.flush(); |
1082 | glLineWidth(1.f); | 1089 | glLineWidth(1.f); |
1083 | 1090 | ||
1084 | for (i = 0; i < mDebugBeacons.count(); i++) | 1091 | for (S32 i = 0; i < mDebugBeacons.count(); i++) |
1085 | { | 1092 | { |
1086 | LLDebugBeacon &debug_beacon = mDebugBeacons[i]; | 1093 | LLDebugBeacon &debug_beacon = mDebugBeacons[i]; |
1087 | if (debug_beacon.mString == "") | 1094 | if (debug_beacon.mString == "") |
diff --git a/linden/indra/newview/llimpanel.cpp b/linden/indra/newview/llimpanel.cpp index 6f06117..3cb9dfb 100644 --- a/linden/indra/newview/llimpanel.cpp +++ b/linden/indra/newview/llimpanel.cpp | |||
@@ -1061,7 +1061,7 @@ LLFloaterIMPanel::LLFloaterIMPanel( | |||
1061 | mSessionUUID(session_id), | 1061 | mSessionUUID(session_id), |
1062 | mVoiceChannel(NULL), | 1062 | mVoiceChannel(NULL), |
1063 | mSessionInitialized(FALSE), | 1063 | mSessionInitialized(FALSE), |
1064 | 1064 | mSessionStartMsgPos(0), | |
1065 | mOtherParticipantUUID(other_participant_id), | 1065 | mOtherParticipantUUID(other_participant_id), |
1066 | mDialog(dialog), | 1066 | mDialog(dialog), |
1067 | mTyping(FALSE), | 1067 | mTyping(FALSE), |
@@ -1090,6 +1090,7 @@ LLFloaterIMPanel::LLFloaterIMPanel( | |||
1090 | mSessionUUID(session_id), | 1090 | mSessionUUID(session_id), |
1091 | mVoiceChannel(NULL), | 1091 | mVoiceChannel(NULL), |
1092 | mSessionInitialized(FALSE), | 1092 | mSessionInitialized(FALSE), |
1093 | mSessionStartMsgPos(0), | ||
1093 | mOtherParticipantUUID(other_participant_id), | 1094 | mOtherParticipantUUID(other_participant_id), |
1094 | mDialog(dialog), | 1095 | mDialog(dialog), |
1095 | mTyping(FALSE), | 1096 | mTyping(FALSE), |
@@ -1182,6 +1183,7 @@ void LLFloaterIMPanel::init(const LLString& session_label) | |||
1182 | //we don't need to need to wait for any responses | 1183 | //we don't need to need to wait for any responses |
1183 | //so we're already initialized | 1184 | //so we're already initialized |
1184 | mSessionInitialized = TRUE; | 1185 | mSessionInitialized = TRUE; |
1186 | mSessionStartMsgPos = 0; | ||
1185 | } | 1187 | } |
1186 | else | 1188 | else |
1187 | { | 1189 | { |
diff --git a/linden/indra/newview/lltexlayer.cpp b/linden/indra/newview/lltexlayer.cpp index 66d9a33..5a0a843 100644 --- a/linden/indra/newview/lltexlayer.cpp +++ b/linden/indra/newview/lltexlayer.cpp | |||
@@ -244,6 +244,8 @@ BOOL LLTexLayerSetBuffer::render() | |||
244 | BOOL upload_now = (gAgent.mNumPendingQueries == 0 && mNeedsUpload && mTexLayerSet->isLocalTextureDataFinal()); | 244 | BOOL upload_now = (gAgent.mNumPendingQueries == 0 && mNeedsUpload && mTexLayerSet->isLocalTextureDataFinal()); |
245 | BOOL success = TRUE; | 245 | BOOL success = TRUE; |
246 | 246 | ||
247 | gGL.start(); | ||
248 | |||
247 | // Composite bump | 249 | // Composite bump |
248 | if( mBumpTexName ) | 250 | if( mBumpTexName ) |
249 | { | 251 | { |
@@ -295,6 +297,8 @@ BOOL LLTexLayerSetBuffer::render() | |||
295 | glColorMask( GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE ); | 297 | glColorMask( GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE ); |
296 | gGL.blendFunc( GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA ); | 298 | gGL.blendFunc( GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA ); |
297 | 299 | ||
300 | gGL.stop(); | ||
301 | |||
298 | // we have valid texture data now | 302 | // we have valid texture data now |
299 | mInitialized = TRUE; | 303 | mInitialized = TRUE; |
300 | mNeedsUpdate = FALSE; | 304 | mNeedsUpdate = FALSE; |
diff --git a/linden/indra/newview/lltoolmorph.cpp b/linden/indra/newview/lltoolmorph.cpp index 5b3f1eb..9acf3a0 100644 --- a/linden/indra/newview/lltoolmorph.cpp +++ b/linden/indra/newview/lltoolmorph.cpp | |||
@@ -163,6 +163,8 @@ void LLVisualParamHint::preRender(BOOL clear_depth) | |||
163 | //----------------------------------------------------------------------------- | 163 | //----------------------------------------------------------------------------- |
164 | BOOL LLVisualParamHint::render() | 164 | BOOL LLVisualParamHint::render() |
165 | { | 165 | { |
166 | gGL.start(); | ||
167 | |||
166 | LLVisualParamReset::sDirty = TRUE; | 168 | LLVisualParamReset::sDirty = TRUE; |
167 | LLVOAvatar* avatarp = gAgent.getAvatarObject(); | 169 | LLVOAvatar* avatarp = gAgent.getAvatarObject(); |
168 | 170 | ||
@@ -223,6 +225,7 @@ BOOL LLVisualParamHint::render() | |||
223 | LLVector3 camera_pos = target_joint_pos + (camera_snapshot_offset * avatar_rotation); | 225 | LLVector3 camera_pos = target_joint_pos + (camera_snapshot_offset * avatar_rotation); |
224 | 226 | ||
225 | gGL.stop(); | 227 | gGL.stop(); |
228 | |||
226 | LLViewerCamera::getInstance()->setAspect((F32)mWidth / (F32)mHeight); | 229 | LLViewerCamera::getInstance()->setAspect((F32)mWidth / (F32)mHeight); |
227 | LLViewerCamera::getInstance()->setOriginAndLookAt( | 230 | LLViewerCamera::getInstance()->setOriginAndLookAt( |
228 | camera_pos, // camera | 231 | camera_pos, // camera |
@@ -238,7 +241,7 @@ BOOL LLVisualParamHint::render() | |||
238 | avatarPoolp->renderAvatars(avatarp); // renders only one avatar | 241 | avatarPoolp->renderAvatars(avatarp); // renders only one avatar |
239 | } | 242 | } |
240 | avatarp->setVisualParamWeight(mVisualParam, mLastParamWeight); | 243 | avatarp->setVisualParamWeight(mVisualParam, mLastParamWeight); |
241 | gGL.start(); | 244 | |
242 | return TRUE; | 245 | return TRUE; |
243 | } | 246 | } |
244 | 247 | ||
diff --git a/linden/indra/newview/llviewermenu.cpp b/linden/indra/newview/llviewermenu.cpp index 6ee80a6..2459133 100644 --- a/linden/indra/newview/llviewermenu.cpp +++ b/linden/indra/newview/llviewermenu.cpp | |||
@@ -4897,12 +4897,12 @@ BOOL menu_check_build_tool( void* user_data ) | |||
4897 | void handle_reload_settings(void*) | 4897 | void handle_reload_settings(void*) |
4898 | { | 4898 | { |
4899 | gSavedSettings.resetToDefaults(); | 4899 | gSavedSettings.resetToDefaults(); |
4900 | gSavedSettings.loadFromFile(gSavedSettings.getString("ClientSettingsFile"), TRUE); | 4900 | gSavedSettings.loadFromFile(gSavedSettings.getString("ClientSettingsFile")); |
4901 | 4901 | ||
4902 | llinfos << "Loading colors from colors.xml" << llendl; | 4902 | llinfos << "Loading colors from colors.xml" << llendl; |
4903 | std::string color_file = gDirUtilp->getExpandedFilename(LL_PATH_APP_SETTINGS,"colors.xml"); | 4903 | std::string color_file = gDirUtilp->getExpandedFilename(LL_PATH_APP_SETTINGS,"colors.xml"); |
4904 | gColors.resetToDefaults(); | 4904 | gColors.resetToDefaults(); |
4905 | gColors.loadFromFile(color_file, FALSE, TYPE_COL4U); | 4905 | gColors.loadFromFileLegacy(color_file, FALSE, TYPE_COL4U); |
4906 | } | 4906 | } |
4907 | 4907 | ||
4908 | class LLWorldSetHomeLocation : public view_listener_t | 4908 | class LLWorldSetHomeLocation : public view_listener_t |
diff --git a/linden/indra/newview/llviewermessage.cpp b/linden/indra/newview/llviewermessage.cpp index 592ef39..e9f100e 100644 --- a/linden/indra/newview/llviewermessage.cpp +++ b/linden/indra/newview/llviewermessage.cpp | |||
@@ -5063,7 +5063,7 @@ void callback_load_url(S32 option, void* data) | |||
5063 | 5063 | ||
5064 | if (0 == option) | 5064 | if (0 == option) |
5065 | { | 5065 | { |
5066 | LLWeb::loadURL(infop->mUrl); | 5066 | LLWeb::loadURLExternal(infop->mUrl); |
5067 | } | 5067 | } |
5068 | 5068 | ||
5069 | delete infop; | 5069 | delete infop; |
diff --git a/linden/indra/newview/llvovolume.cpp b/linden/indra/newview/llvovolume.cpp index 188c277..6b5b9bb 100644 --- a/linden/indra/newview/llvovolume.cpp +++ b/linden/indra/newview/llvovolume.cpp | |||
@@ -766,9 +766,7 @@ void LLVOVolume::sculpt() | |||
766 | 766 | ||
767 | sculpt_height = raw_image->getHeight(); | 767 | sculpt_height = raw_image->getHeight(); |
768 | sculpt_width = raw_image->getWidth(); | 768 | sculpt_width = raw_image->getWidth(); |
769 | 769 | sculpt_components = raw_image->getComponents(); | |
770 | sculpt_components = raw_image->getComponents(); | ||
771 | sculpt_data = raw_image->getData(); | ||
772 | 770 | ||
773 | if(is_valid) | 771 | if(is_valid) |
774 | { | 772 | { |
@@ -776,12 +774,18 @@ void LLVOVolume::sculpt() | |||
776 | } | 774 | } |
777 | if(!is_valid) | 775 | if(!is_valid) |
778 | { | 776 | { |
779 | sculpt_width = 0 ; | 777 | sculpt_width = 0; |
780 | sculpt_height = 0 ; | 778 | sculpt_height = 0; |
779 | sculpt_data = NULL ; | ||
780 | } | ||
781 | else | ||
782 | { | ||
783 | if (raw_image->getDataSize() < sculpt_height * sculpt_width * sculpt_components) | ||
784 | llerrs << "Sculpt: image data size = " << raw_image->getDataSize() | ||
785 | << " < " << sculpt_height << " x " << sculpt_width << " x " <<sculpt_components << llendl; | ||
786 | |||
787 | sculpt_data = raw_image->getData(); | ||
781 | } | 788 | } |
782 | |||
783 | llassert_always(raw_image->getDataSize() >= sculpt_height * sculpt_width * sculpt_components); | ||
784 | |||
785 | getVolume()->sculpt(sculpt_width, sculpt_height, sculpt_components, sculpt_data, discard_level); | 789 | getVolume()->sculpt(sculpt_width, sculpt_height, sculpt_components, sculpt_data, discard_level); |
786 | } | 790 | } |
787 | } | 791 | } |
diff --git a/linden/indra/newview/releasenotes.txt b/linden/indra/newview/releasenotes.txt index 0243fd7..c87e237 100644 --- a/linden/indra/newview/releasenotes.txt +++ b/linden/indra/newview/releasenotes.txt | |||
@@ -1,3 +1,11 @@ | |||
1 | Release Notes for Second Life 1.20(4) April 24th, 2008 | ||
2 | ===================================== | ||
3 | Fixes: | ||
4 | * VWR-6286 - changed the method LLControlGroup::loadFromFile to only load values of settings that are persistent | ||
5 | * Instant Crash on Editing Appearance | ||
6 | * Crash in LLFloaterIMPanel when starting conference | ||
7 | * Crash on LLVOVolume::sculpt - newview/llvovolume.cpp | ||
8 | |||
1 | Release Notes for Second Life 1.20(3) April 23th, 2008 | 9 | Release Notes for Second Life 1.20(3) April 23th, 2008 |
2 | ===================================== | 10 | ===================================== |
3 | Fixes: | 11 | Fixes: |