diff options
-rw-r--r-- | indra/llui/llcombobox.cpp | 2 | ||||
-rwxr-xr-x | indra/newview/app_settings/settings.xml | 12 | ||||
-rw-r--r-- | indra/newview/app_settings/shaders/class1/deferred/postDeferredF.glsl | 14 | ||||
-rw-r--r-- | indra/newview/llappviewer.cpp | 3 | ||||
-rw-r--r-- | indra/newview/lllogininstance.cpp | 2 | ||||
-rw-r--r-- | indra/newview/llremoteparcelrequest.cpp | 9 | ||||
-rw-r--r-- | indra/newview/llversioninfo.cpp | 6 | ||||
-rw-r--r-- | indra/newview/llversioninfo.h | 4 | ||||
-rw-r--r-- | indra/newview/llviewerstats.cpp | 2 | ||||
-rw-r--r-- | indra/newview/pipeline.cpp | 8 | ||||
-rw-r--r-- | indra/newview/skins/default/xui/en/panel_preferences_graphics1.xml | 16 | ||||
-rw-r--r-- | indra/newview/tests/lllogininstance_test.cpp | 2 | ||||
-rw-r--r-- | indra/newview/tests/llversioninfo_test.cpp | 12 |
13 files changed, 55 insertions, 37 deletions
diff --git a/indra/llui/llcombobox.cpp b/indra/llui/llcombobox.cpp index a268ee5d75..70014fe4f5 100644 --- a/indra/llui/llcombobox.cpp +++ b/indra/llui/llcombobox.cpp @@ -769,7 +769,7 @@ BOOL LLComboBox::handleKeyHere(KEY key, MASK mask) return FALSE; } // if selection has changed, pop open list - else + else if ((mList->getLastSelectedItem() != last_selected_item) || (key == KEY_DOWN) || (key == KEY_UP)) { showList(); } diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index ef3803aed6..4e5ad60513 100755 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -1353,7 +1353,7 @@ <key>Type</key> <string>F32</string> <key>Value</key> - <real>8.0</real> + <real>11.0</real> </map> <key>CameraFocalLength</key> @@ -1365,22 +1365,22 @@ <key>Type</key> <string>F32</string> <key>Value</key> - <real>50</real> + <real>35</real> </map> - <key>CameraCoC</key> + <key>CameraCoCRatio</key> <map> <key>Comment</key> - <string>Camera circle of confusion for DoF effect (in millimeters)</string> + <string>Ratio of circle of confusion to vertical resolution for DoF effect.</string> <key>Persist</key> <integer>1</integer> <key>Type</key> <string>F32</string> <key>Value</key> - <real>0.05</real> + <real>54</real> </map> - + <key>CertStore</key> <map> <key>Comment</key> diff --git a/indra/newview/app_settings/shaders/class1/deferred/postDeferredF.glsl b/indra/newview/app_settings/shaders/class1/deferred/postDeferredF.glsl index 77e3e41ea4..02712e0a5b 100644 --- a/indra/newview/app_settings/shaders/class1/deferred/postDeferredF.glsl +++ b/indra/newview/app_settings/shaders/class1/deferred/postDeferredF.glsl @@ -73,12 +73,14 @@ void main() { //pixel is behind far focal plane float w = 1.0; - float fd = far_focal_distance; + float fd = (depth[0]-far_focal_distance)*0.5+far_focal_distance; float sc = far_focal_distance - depth[0]; - sc /= -far_focal_distance; + sc /= near_focal_distance-far_focal_distance; + + sc = sqrt(sc); sc = min(sc, 8.0); - + while (sc > 1.0) { dofSample(diff,w, fd, sc,sc); @@ -104,8 +106,10 @@ void main() { //pixel is in front of near focal plane //diff.r = 1.0; float w = 1.0; - float sc = depth[0] - fd; - sc = min(-sc/fd*16.0, 8.0); + float sc = near_focal_distance-depth[0]; + sc /= near_focal_distance; + sc *= 8.0; + sc = min(sc, 8.0); fd = depth[0]; while (sc > 1.0) diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 57e0bf8625..29ffcdfbd1 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -909,7 +909,8 @@ bool LLAppViewer::init() gDebugInfo["GraphicsCard"] = LLFeatureManager::getInstance()->getGPUString(); // Save the current version to the prefs file - gSavedSettings.setString("LastRunVersion", LLVersionInfo::getVersionAndChannel()); + gSavedSettings.setString("LastRunVersion", + LLVersionInfo::getChannelAndVersion()); gSimLastTime = gRenderStartTime.getElapsedTimeF32(); gSimFrames = (F32)gFrameCount; diff --git a/indra/newview/lllogininstance.cpp b/indra/newview/lllogininstance.cpp index 83a8134580..52ce932241 100644 --- a/indra/newview/lllogininstance.cpp +++ b/indra/newview/lllogininstance.cpp @@ -183,7 +183,7 @@ void LLLoginInstance::constructAuthParams(LLPointer<LLCredential> user_credentia request_params["read_critical"] = false; // handleTOSResponse request_params["last_exec_event"] = mLastExecEvent; request_params["mac"] = hashed_unique_id_string; - request_params["version"] = LLVersionInfo::getVersionAndChannel(); // Includes channel name + request_params["version"] = LLVersionInfo::getChannelAndVersion(); // Includes channel name request_params["channel"] = LLVersionInfo::getChannel(); request_params["id0"] = mSerialNumber; diff --git a/indra/newview/llremoteparcelrequest.cpp b/indra/newview/llremoteparcelrequest.cpp index 10d4452ed2..0dff087553 100644 --- a/indra/newview/llremoteparcelrequest.cpp +++ b/indra/newview/llremoteparcelrequest.cpp @@ -78,10 +78,11 @@ void LLRemoteParcelRequestResponder::error(U32 status, const std::string& reason void LLRemoteParcelInfoProcessor::addObserver(const LLUUID& parcel_id, LLRemoteParcelInfoObserver* observer) { observer_multimap_t::iterator it; + observer_multimap_t::iterator start = mObservers.lower_bound(parcel_id); observer_multimap_t::iterator end = mObservers.upper_bound(parcel_id); // Check if the observer is already in observers list for this UUID - for(it = mObservers.find(parcel_id); it != end; ++it) + for(it = start; it != end; ++it) { if (it->second.get() == observer) { @@ -100,9 +101,10 @@ void LLRemoteParcelInfoProcessor::removeObserver(const LLUUID& parcel_id, LLRemo } observer_multimap_t::iterator it; + observer_multimap_t::iterator start = mObservers.lower_bound(parcel_id); observer_multimap_t::iterator end = mObservers.upper_bound(parcel_id); - for(it = mObservers.find(parcel_id); it != end; ++it) + for(it = start; it != end; ++it) { if (it->second.get() == observer) { @@ -139,9 +141,10 @@ void LLRemoteParcelInfoProcessor::processParcelInfoReply(LLMessageSystem* msg, v deadlist_t dead_iters; observer_multimap_t::iterator oi; + observer_multimap_t::iterator start = observers.lower_bound(parcel_data.parcel_id); observer_multimap_t::iterator end = observers.upper_bound(parcel_data.parcel_id); - for (oi = observers.find(parcel_data.parcel_id); oi != end; ++oi) + for (oi = start; oi != end; ++oi) { LLRemoteParcelInfoObserver * observer = oi->second.get(); if(observer) diff --git a/indra/newview/llversioninfo.cpp b/indra/newview/llversioninfo.cpp index 53994c68f2..673d0c24cf 100644 --- a/indra/newview/llversioninfo.cpp +++ b/indra/newview/llversioninfo.cpp @@ -108,15 +108,15 @@ namespace } //static -const std::string &LLVersionInfo::getVersionAndChannel() +const std::string &LLVersionInfo::getChannelAndVersion() { if (sVersionChannel.empty()) { // cache the version string std::ostringstream stream; - stream << LLVersionInfo::getVersion() + stream << LLVersionInfo::getChannel() << " " - << LLVersionInfo::getChannel(); + << LLVersionInfo::getVersion(); sVersionChannel = stream.str(); } diff --git a/indra/newview/llversioninfo.h b/indra/newview/llversioninfo.h index 36defbcd68..6f64544f3b 100644 --- a/indra/newview/llversioninfo.h +++ b/indra/newview/llversioninfo.h @@ -59,8 +59,8 @@ public: static const std::string &getShortVersion(); /// return the viewer version and channel as a string - /// like "2.0.0.200030 Second Life Release" - static const std::string &getVersionAndChannel(); + /// like "Second Life Release 2.0.0.200030" + static const std::string &getChannelAndVersion(); /// return the channel name, e.g. "Second Life" static const std::string &getChannel(); diff --git a/indra/newview/llviewerstats.cpp b/indra/newview/llviewerstats.cpp index 221be0062d..09d25af349 100644 --- a/indra/newview/llviewerstats.cpp +++ b/indra/newview/llviewerstats.cpp @@ -751,7 +751,7 @@ void send_stats() // send fps only for time app spends in foreground agent["fps"] = (F32)gForegroundFrameCount / gForegroundTime.getElapsedTimeF32(); - agent["version"] = LLVersionInfo::getVersionAndChannel(); + agent["version"] = LLVersionInfo::getChannelAndVersion(); std::string language = LLUI::getLanguage(); agent["language"] = language; diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index 1c91c528f7..f0446b024c 100644 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -6161,8 +6161,9 @@ void LLPipeline::renderBloom(BOOL for_snapshot, F32 zoom_factor, int subfield) subject_distance *= 1000.f; F32 fnumber = gSavedSettings.getF32("CameraFNumber"); F32 focal_length = gSavedSettings.getF32("CameraFocalLength"); - F32 coc = gSavedSettings.getF32("CameraCoC"); + F32 coc_ratio = gSavedSettings.getF32("CameraCoCRatio"); + F32 coc = coc_ratio/mScreen.getHeight(); F32 hyperfocal_distance = (focal_length*focal_length)/(fnumber*coc); @@ -6173,8 +6174,7 @@ void LLPipeline::renderBloom(BOOL for_snapshot, F32 zoom_factor, int subfield) //adjust focal length for zoom F32 fov = LLViewerCamera::getInstance()->getView(); - F32 default_fov = LLViewerCamera::getInstance()->getDefaultFOV(); - focal_length *= default_fov/fov; + focal_length *= 1.f/fov; F32 near_focal_distance = hyperfocal_distance*subject_distance/(hyperfocal_distance+subject_distance); @@ -6196,7 +6196,7 @@ void LLPipeline::renderBloom(BOOL for_snapshot, F32 zoom_factor, int subfield) if (channel > -1) { mScreen.bindTexture(0, channel); - gGL.getTexUnit(0)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR); + gGL.getTexUnit(0)->setTextureFilteringOption(LLTexUnit::TFO_POINT); } gGL.begin(LLRender::TRIANGLE_STRIP); diff --git a/indra/newview/skins/default/xui/en/panel_preferences_graphics1.xml b/indra/newview/skins/default/xui/en/panel_preferences_graphics1.xml index 6573822d1a..70db3c6592 100644 --- a/indra/newview/skins/default/xui/en/panel_preferences_graphics1.xml +++ b/indra/newview/skins/default/xui/en/panel_preferences_graphics1.xml @@ -193,8 +193,19 @@ left_delta="0" name="BumpShiny" top_pad="1" + width="256" /> + <check_box + control_name="RenderLocalLights" + height="16" + initial_value="true" + label="Local Lights" + layout="topleft" + left_delta="0" + name="LocalLights" + top_pad="1" width="256" /> - <check_box + width="256" /> + <check_box control_name="VertexShaderEnable" height="16" initial_value="true" @@ -221,7 +232,6 @@ <check_box.commit_callback function="Pref.VertexShaderEnable" /> </check_box> -<!-- DISABLED UNTIL WE REALLY WANT TO SUPPORT THIS <check_box control_name="RenderDeferred" height="16" @@ -283,7 +293,7 @@ name="2" value="2"/> </combo_box> ---> + <text type="string" length="1" diff --git a/indra/newview/tests/lllogininstance_test.cpp b/indra/newview/tests/lllogininstance_test.cpp index b902c7ab09..309e9e9ee3 100644 --- a/indra/newview/tests/lllogininstance_test.cpp +++ b/indra/newview/tests/lllogininstance_test.cpp @@ -181,7 +181,7 @@ void LLUIColorTable::saveUserSettings(void)const {} //----------------------------------------------------------------------------- #include "../llversioninfo.h" -const std::string &LLVersionInfo::getVersionAndChannel() { return VIEWERLOGIN_VERSION_CHANNEL; } +const std::string &LLVersionInfo::getChannelAndVersion() { return VIEWERLOGIN_VERSION_CHANNEL; } const std::string &LLVersionInfo::getChannel() { return VIEWERLOGIN_CHANNEL; } //----------------------------------------------------------------------------- diff --git a/indra/newview/tests/llversioninfo_test.cpp b/indra/newview/tests/llversioninfo_test.cpp index 8855a24ead..398d8f16ed 100644 --- a/indra/newview/tests/llversioninfo_test.cpp +++ b/indra/newview/tests/llversioninfo_test.cpp @@ -51,15 +51,15 @@ namespace tut mShortVersion = stream.str(); stream.str(""); - stream << mVersion + stream << LL_CHANNEL << " " - << LL_CHANNEL; + << mVersion; mVersionAndChannel = stream.str(); stream.str(""); - stream << mVersion + stream << mResetChannel << " " - << mResetChannel; + << mVersion; mResetVersionAndChannel = stream.str(); } std::string mResetChannel; @@ -99,7 +99,7 @@ namespace tut LLVersionInfo::getShortVersion(), mShortVersion); ensure_equals("Version and channel String", - LLVersionInfo::getVersionAndChannel(), + LLVersionInfo::getChannelAndVersion(), mVersionAndChannel); LLVersionInfo::resetChannel(mResetChannel); @@ -108,7 +108,7 @@ namespace tut mResetChannel); ensure_equals("Reset Version and channel String", - LLVersionInfo::getVersionAndChannel(), + LLVersionInfo::getChannelAndVersion(), mResetVersionAndChannel); } } |