diff options
author | Dave Parks <davep@lindenlab.com> | 2022-03-29 15:41:34 -0500 |
---|---|---|
committer | Dave Parks <davep@lindenlab.com> | 2022-03-29 15:41:34 -0500 |
commit | 425b071c644cddd1e14b94fb06a7307622d6b315 (patch) | |
tree | 40a28db383c8615311d2397857519a94656948fd | |
parent | e60024f0afecb6f92e383221084f1a7af02f8542 (diff) | |
parent | 977bd76316776e57abf6537ba811499d45677a58 (diff) |
Merge remote-tracking branch 'remotes/origin/DRTVWR-546' into SL-17005
-rw-r--r-- | autobuild.xml | 10 | ||||
-rw-r--r-- | indra/llwindow/llwindowwin32.cpp | 9 | ||||
-rw-r--r-- | indra/newview/lltoolmorph.cpp | 10 | ||||
-rw-r--r-- | indra/newview/pipeline.cpp | 203 | ||||
-rw-r--r-- | indra/newview/pipeline.h | 3 | ||||
-rw-r--r-- | indra/newview/skins/default/xui/en/floater_model_preview.xml | 2 | ||||
-rwxr-xr-x | indra/newview/viewer_manifest.py | 2 |
7 files changed, 54 insertions, 185 deletions
diff --git a/autobuild.xml b/autobuild.xml index b15bc5527b..1f1ee45549 100644 --- a/autobuild.xml +++ b/autobuild.xml @@ -3298,9 +3298,9 @@ Copyright (c) 2012, 2014, 2015, 2016 nghttp2 contributors</string> <key>archive</key> <map> <key>hash</key> - <string>33ed1bb3e24fbd3462da04fb3e917e94</string> + <string>1dda5fb3bb649b0ab5a93f22df7cb11e</string> <key>url</key> - <string>https://automated-builds-secondlife-com.s3.amazonaws.com/ct2/94814/850320/viewer_manager-3.0.568552-darwin64-568552.tar.bz2</string> + <string>https://automated-builds-secondlife-com.s3.amazonaws.com/ct2/96998/862110/viewer_manager-3.0.569958-darwin64-569958.tar.bz2</string> </map> <key>name</key> <string>darwin64</string> @@ -3322,9 +3322,9 @@ Copyright (c) 2012, 2014, 2015, 2016 nghttp2 contributors</string> <key>archive</key> <map> <key>hash</key> - <string>2ad8e04965ac8bddb7d351abe09bee07</string> + <string>30d1386d0a6883d898fc56757a789b8b</string> <key>url</key> - <string>https://automated-builds-secondlife-com.s3.amazonaws.com/ct2/94813/850316/viewer_manager-3.0.568552-windows-568552.tar.bz2</string> + <string>https://automated-builds-secondlife-com.s3.amazonaws.com/ct2/97002/862130/viewer_manager-3.0.569958-windows-569958.tar.bz2</string> </map> <key>name</key> <string>windows</string> @@ -3335,7 +3335,7 @@ Copyright (c) 2012, 2014, 2015, 2016 nghttp2 contributors</string> <key>source_type</key> <string>hg</string> <key>version</key> - <string>3.0.568552</string> + <string>3.0.569958</string> </map> <key>vlc-bin</key> <map> diff --git a/indra/llwindow/llwindowwin32.cpp b/indra/llwindow/llwindowwin32.cpp index 3afb78d1d2..e38c43bc63 100644 --- a/indra/llwindow/llwindowwin32.cpp +++ b/indra/llwindow/llwindowwin32.cpp @@ -2451,7 +2451,7 @@ LRESULT CALLBACK LLWindowWin32::mainWindowProc(HWND h_wnd, UINT u_msg, WPARAM w_ LL_PROFILE_ZONE_NAMED_CATEGORY_WIN32("mwp - WM_SYSKEYDOWN"); // allow system keys, such as ALT-F4 to be processed by Windows eat_keystroke = FALSE; - break; + // intentional fall-through here } case WM_KEYDOWN: { @@ -2476,10 +2476,12 @@ LRESULT CALLBACK LLWindowWin32::mainWindowProc(HWND h_wnd, UINT u_msg, WPARAM w_ gKeyboard->handleKeyDown(w_param, mask); } }); - return eat_keystroke; + if (eat_keystroke) return 0; // skip DefWindowProc() handling if we're consuming the keypress + break; } case WM_SYSKEYUP: eat_keystroke = FALSE; + // intentional fall-through here case WM_KEYUP: { LL_PROFILE_ZONE_NAMED_CATEGORY_WIN32("mwp - WM_KEYUP"); @@ -2503,7 +2505,8 @@ LRESULT CALLBACK LLWindowWin32::mainWindowProc(HWND h_wnd, UINT u_msg, WPARAM w_ gKeyboard->handleKeyUp(w_param, mask); } }); - return eat_keystroke; + if (eat_keystroke) return 0; // skip DefWindowProc() handling if we're consuming the keypress + break; } case WM_IME_SETCONTEXT: { diff --git a/indra/newview/lltoolmorph.cpp b/indra/newview/lltoolmorph.cpp index b5eb2880ae..d99c0ba2a6 100644 --- a/indra/newview/lltoolmorph.cpp +++ b/indra/newview/lltoolmorph.cpp @@ -239,7 +239,15 @@ BOOL LLVisualParamHint::render() LLViewerCamera::getInstance()->setPerspective(FALSE, mOrigin.mX, mOrigin.mY, mFullWidth, mFullHeight, FALSE); - gPipeline.previewAvatar(gAgentAvatarp); + if (gAgentAvatarp->mDrawable.notNull()) + { + LLGLDepthTest gls_depth(GL_TRUE, GL_TRUE); + gGL.flush(); + gGL.setSceneBlendType(LLRender::BT_REPLACE); + gPipeline.generateImpostor(gAgentAvatarp, true); + gGL.setSceneBlendType(LLRender::BT_ALPHA); + gGL.flush(); + } gAgentAvatarp->setVisualParamWeight(mVisualParam->getID(), mLastParamWeight); mWearablePtr->setVisualParamWeight(mVisualParam->getID(), mLastParamWeight); diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index 2aff3de29b..a5ae52af93 100644 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -10818,7 +10818,7 @@ void LLPipeline::renderRiggedGroups(LLRenderPass* pass, U32 type, U32 mask, bool static LLTrace::BlockTimerStatHandle FTM_GENERATE_IMPOSTOR("Generate Impostor"); -void LLPipeline::generateImpostor(LLVOAvatar* avatar) +void LLPipeline::generateImpostor(LLVOAvatar* avatar, bool preview_avatar) { LL_RECORD_BLOCK_TIME(FTM_GENERATE_IMPOSTOR); LLGLState::checkStates(); @@ -10837,11 +10837,12 @@ void LLPipeline::generateImpostor(LLVOAvatar* avatar) assertInitialized(); - bool visually_muted = avatar->isVisuallyMuted(); + // previews can't be muted or impostered + bool visually_muted = !preview_avatar && avatar->isVisuallyMuted(); LL_DEBUGS_ONCE("AvatarRenderPipeline") << "Avatar " << avatar->getID() << " is " << ( visually_muted ? "" : "not ") << "visually muted" << LL_ENDL; - bool too_complex = avatar->isTooComplex(); + bool too_complex = !preview_avatar && avatar->isTooComplex(); LL_DEBUGS_ONCE("AvatarRenderPipeline") << "Avatar " << avatar->getID() << " is " << ( too_complex ? "" : "not ") << "too complex" << LL_ENDL; @@ -10915,6 +10916,7 @@ void LLPipeline::generateImpostor(LLVOAvatar* avatar) U32 resY = 0; U32 resX = 0; + if (!preview_avatar) { const LLVector4a* ext = avatar->mDrawable->getSpatialExtents(); LLVector3 pos(avatar->getRenderPosition()+avatar->getImpostorOffset()); @@ -11001,7 +11003,20 @@ void LLPipeline::generateImpostor(LLVOAvatar* avatar) LLDrawPoolAvatar::sMinimumAlpha = 0.f; } - if (LLPipeline::sRenderDeferred) + if (preview_avatar) + { + // previews don't care about imposters + if (LLPipeline::sRenderDeferred) + { + renderGeomDeferred(camera); + renderGeomPostDeferred(camera); + } + else + { + renderGeom(camera); + } + } + else if (LLPipeline::sRenderDeferred) { avatar->mImpostor.clear(); renderGeomDeferred(camera); @@ -11089,7 +11104,7 @@ void LLPipeline::generateImpostor(LLVOAvatar* avatar) LL_DEBUGS_ONCE("AvatarRenderPipeline") << "Avatar " << avatar->getID() << " MUTED set solid color " << muted_color << LL_ENDL; gGL.diffuseColor4fv( muted_color.mV ); } - else + else if (!preview_avatar) { //grey muted avatar LL_DEBUGS_ONCE("AvatarRenderPipeline") << "Avatar " << avatar->getID() << " MUTED set grey" << LL_ENDL; gGL.diffuseColor4fv(LLColor4::pink.mV ); @@ -11110,9 +11125,11 @@ void LLPipeline::generateImpostor(LLVOAvatar* avatar) gGL.popMatrix(); } - avatar->mImpostor.flush(); - - avatar->setImpostorDim(tdim); + if (!preview_avatar) + { + avatar->mImpostor.flush(); + avatar->setImpostorDim(tdim); + } sUseOcclusion = occlusion; sReflectionRender = false; @@ -11125,176 +11142,18 @@ void LLPipeline::generateImpostor(LLVOAvatar* avatar) gGL.matrixMode(LLRender::MM_MODELVIEW); gGL.popMatrix(); - avatar->mNeedsImpostorUpdate = FALSE; - avatar->cacheImpostorValues(); - avatar->mLastImpostorUpdateFrameTime = gFrameTimeSeconds; + if (!preview_avatar) + { + avatar->mNeedsImpostorUpdate = FALSE; + avatar->cacheImpostorValues(); + avatar->mLastImpostorUpdateFrameTime = gFrameTimeSeconds; + } LLVertexBuffer::unbind(); LLGLState::checkStates(); LLGLState::checkTextureChannels(); } -static LLTrace::BlockTimerStatHandle FTM_PREVIEW_AVATAR("Preview Avatar"); - -void LLPipeline::previewAvatar(LLVOAvatar* avatar) -{ - LL_RECORD_BLOCK_TIME(FTM_PREVIEW_AVATAR); - - LLGLDepthTest gls_depth(GL_TRUE, GL_TRUE); - gGL.flush(); - gGL.setSceneBlendType(LLRender::BT_REPLACE); - - LLGLState::checkStates(); - LLGLState::checkTextureChannels(); - - static LLCullResult result; - result.clear(); - grabReferences(result); - - if (!avatar || !avatar->mDrawable) - { - LL_WARNS_ONCE("AvatarRenderPipeline") << "Avatar is " << (avatar ? "not drawable" : "null") << LL_ENDL; - return; - } - LL_DEBUGS_ONCE("AvatarRenderPipeline") << "Avatar " << avatar->getID() << " is drawable" << LL_ENDL; - - assertInitialized(); - - pushRenderTypeMask(); - - { - //hide world geometry - clearRenderTypeMask( - RENDER_TYPE_SKY, - RENDER_TYPE_WL_SKY, - RENDER_TYPE_GROUND, - RENDER_TYPE_TERRAIN, - RENDER_TYPE_GRASS, - RENDER_TYPE_CONTROL_AV, // Animesh - RENDER_TYPE_TREE, - RENDER_TYPE_VOIDWATER, - RENDER_TYPE_WATER, - RENDER_TYPE_PASS_GRASS, - RENDER_TYPE_HUD, - RENDER_TYPE_PARTICLES, - RENDER_TYPE_CLOUDS, - RENDER_TYPE_HUD_PARTICLES, - END_RENDER_TYPES - ); - } - - S32 occlusion = sUseOcclusion; - sUseOcclusion = 0; - - sReflectionRender = !sRenderDeferred; - - sShadowRender = true; - sImpostorRender = true; // Likely not needed for previews - - LLViewerCamera* viewer_camera = LLViewerCamera::getInstance(); - - { - markVisible(avatar->mDrawable, *viewer_camera); - - LLVOAvatar::attachment_map_t::iterator iter; - for (iter = avatar->mAttachmentPoints.begin(); - iter != avatar->mAttachmentPoints.end(); - ++iter) - { - LLViewerJointAttachment *attachment = iter->second; - for (LLViewerJointAttachment::attachedobjs_vec_t::iterator attachment_iter = attachment->mAttachedObjects.begin(); - attachment_iter != attachment->mAttachedObjects.end(); - ++attachment_iter) - { - if (LLViewerObject* attached_object = attachment_iter->get()) - { - markVisible(attached_object->mDrawable->getSpatialBridge(), *viewer_camera); - } - } - } - } - - stateSort(*LLViewerCamera::getInstance(), result); - - LLCamera camera = *viewer_camera; - - F32 old_alpha = LLDrawPoolAvatar::sMinimumAlpha; - - if (LLPipeline::sRenderDeferred) - { - renderGeomDeferred(camera); - - renderGeomPostDeferred(camera); - } - else - { - renderGeom(camera); - } - - LLDrawPoolAvatar::sMinimumAlpha = old_alpha; - - { //create alpha mask based on depth buffer - if (LLPipeline::sRenderDeferred) - { - GLuint buff = GL_COLOR_ATTACHMENT0; - LL_PROFILER_GPU_ZONEC("gl.DrawBuffersARB", 0x8000FF); - glDrawBuffersARB(1, &buff); - } - - LLGLDisable blend(GL_BLEND); - - gGL.setColorMask(false, true); - - gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); - - LLGLDepthTest depth(GL_TRUE, GL_FALSE, GL_GREATER); - - gGL.flush(); - - gGL.pushMatrix(); - gGL.loadIdentity(); - gGL.matrixMode(LLRender::MM_PROJECTION); - gGL.pushMatrix(); - gGL.loadIdentity(); - - static const F32 clip_plane = 0.99999f; - - gDebugProgram.bind(); - - gGL.begin(LLRender::QUADS); - gGL.vertex3f(-1, -1, clip_plane); - gGL.vertex3f(1, -1, clip_plane); - gGL.vertex3f(1, 1, clip_plane); - gGL.vertex3f(-1, 1, clip_plane); - gGL.end(); - gGL.flush(); - - gDebugProgram.unbind(); - - gGL.popMatrix(); - gGL.matrixMode(LLRender::MM_MODELVIEW); - gGL.popMatrix(); - } - - sUseOcclusion = occlusion; - sReflectionRender = false; - sImpostorRender = false; - sShadowRender = false; - popRenderTypeMask(); - - gGL.matrixMode(LLRender::MM_PROJECTION); - gGL.popMatrix(); - gGL.matrixMode(LLRender::MM_MODELVIEW); - gGL.popMatrix(); - - LLVertexBuffer::unbind(); - LLGLState::checkStates(); - LLGLState::checkTextureChannels(); - - gGL.setSceneBlendType(LLRender::BT_ALPHA); - gGL.flush(); -} - bool LLPipeline::hasRenderBatches(const U32 type) const { return sCull->getRenderMapSize(type) > 0; diff --git a/indra/newview/pipeline.h b/indra/newview/pipeline.h index df5c060417..62d3ae7a39 100644 --- a/indra/newview/pipeline.h +++ b/indra/newview/pipeline.h @@ -134,8 +134,7 @@ public: void allocatePhysicsBuffer(); void resetVertexBuffers(LLDrawable* drawable); - void generateImpostor(LLVOAvatar* avatar); - void previewAvatar(LLVOAvatar* avatar); + void generateImpostor(LLVOAvatar* avatar, bool preview_avatar = false); void bindScreenToTexture(); void renderFinalize(); diff --git a/indra/newview/skins/default/xui/en/floater_model_preview.xml b/indra/newview/skins/default/xui/en/floater_model_preview.xml index ca3e40465c..1bfa459310 100644 --- a/indra/newview/skins/default/xui/en/floater_model_preview.xml +++ b/indra/newview/skins/default/xui/en/floater_model_preview.xml @@ -34,7 +34,7 @@ <string name="mesh_status_missing_lod">Missing required level of detail.</string> <string name="mesh_status_invalid_material_list">LOD materials are not a subset of reference model.</string> <string name="phys_status_vertex_limit_exceeded">Some physical hulls exceed vertex limitations.</string> - <string name="phys_status_degenerate_triangles">The physics mesh too dense remove the small thin triangles (see preview)</string> + <string name="phys_status_degenerate_triangles">The physics mesh contains degenerate triangles. Use Analyze/Simplify to resolve.</string> <string name="layer_all">All</string> <!-- Text to display in physics layer combo box for "all layers" --> <string name="decomposing">Analyzing...</string> <string name="simplifying">Simplifying...</string> diff --git a/indra/newview/viewer_manifest.py b/indra/newview/viewer_manifest.py index 6aafc07bc7..76160b73ba 100755 --- a/indra/newview/viewer_manifest.py +++ b/indra/newview/viewer_manifest.py @@ -1335,7 +1335,7 @@ class DarwinManifest(ViewerManifest): # 'err' goes out of scope sign_failed = err else: - print >> sys.stderr, "Maximum codesign attempts exceeded; giving up" + print("Maximum codesign attempts exceeded; giving up", file=sys.stderr) raise sign_failed self.run_command(['spctl', '-a', '-texec', '-vvvv', app_in_dmg]) self.run_command([self.src_path_of("installers/darwin/apple-notarize.sh"), app_in_dmg]) |