diff options
Diffstat (limited to 'indra')
-rw-r--r-- | indra/llrender/llrender2dutils.cpp | 2 | ||||
-rwxr-xr-x | indra/newview/llworldmapview.cpp | 64 |
2 files changed, 7 insertions, 59 deletions
diff --git a/indra/llrender/llrender2dutils.cpp b/indra/llrender/llrender2dutils.cpp index 3d32d3ca31..2d6f3c9469 100644 --- a/indra/llrender/llrender2dutils.cpp +++ b/indra/llrender/llrender2dutils.cpp @@ -117,7 +117,6 @@ void gl_rect_2d_offset_local( S32 left, S32 top, S32 right, S32 bottom, S32 pixe void gl_rect_2d(S32 left, S32 top, S32 right, S32 bottom, BOOL filled ) { - stop_glerror(); gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); // Counterclockwise quad will face the viewer @@ -142,7 +141,6 @@ void gl_rect_2d(S32 left, S32 top, S32 right, S32 bottom, BOOL filled ) gGL.vertex2i(left, top); gGL.end(); } - stop_glerror(); } void gl_rect_2d(S32 left, S32 top, S32 right, S32 bottom, const LLColor4 &color, BOOL filled ) diff --git a/indra/newview/llworldmapview.cpp b/indra/newview/llworldmapview.cpp index 6e994b4e68..0b1082b540 100755 --- a/indra/newview/llworldmapview.cpp +++ b/indra/newview/llworldmapview.cpp @@ -398,28 +398,17 @@ void LLWorldMapView::draw() S32 level = LLWorldMipmap::scaleToLevel(mMapScale); LLLocalClipRect clip(getLocalRect()); - { - gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); - - gGL.matrixMode(LLRender::MM_MODELVIEW); + gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); - // Clear the background alpha to 0 - gGL.flush(); - gGL.setColorMask(false, true); - gGL.flush(); - gGL.setSceneBlendType(LLRender::BT_REPLACE); - gGL.color4f(0.0f, 0.0f, 0.0f, 0.0f); - gl_rect_2d(0, height, width, 0); - } + gGL.matrixMode(LLRender::MM_MODELVIEW); - gGL.flush(); - gGL.setColorMask(true, true); + // Draw background rectangle + gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); + gGL.color4fv(mBackgroundColor.mV); + gl_rect_2d(0, height, width, 0); // Draw the image tiles drawMipmap(width, height); - gGL.flush(); - - gGL.setColorMask(true, true); // Draw per sim overlayed information (names, mature, offline...) for (LLWorldMap::sim_info_map_t::const_iterator it = LLWorldMap::getInstance()->getRegionMap().begin(); @@ -464,7 +453,6 @@ void LLWorldMapView::draw() if (info->isDown()) { // Draw a transparent red square over down sims - gGL.blendFunc(LLRender::BF_DEST_ALPHA, LLRender::BF_SOURCE_ALPHA); gGL.color4f(0.2f, 0.0f, 0.0f, 0.4f); gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); @@ -475,26 +463,7 @@ void LLWorldMapView::draw() gGL.vertex2f(right, top); gGL.end(); } - // As part of the AO project, we no longer want to draw access indicators; - // it's too complicated to get all the rules straight and will only - // cause confusion. - /********************** - else if (!info->isPG() && gAgent.isTeen()) - { - // If this is a mature region, and you are not, draw a line across it - gGL.blendFunc(LLRender::BF_DEST_ALPHA, LLRender::BF_ZERO); - - gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); - gGL.color3f(1.f, 0.f, 0.f); - gGL.begin(LLRender::LINES); - gGL.vertex2f(left, top); - gGL.vertex2f(right, bottom); - gGL.vertex2f(left, bottom); - gGL.vertex2f(right, top); - gGL.end(); - } - **********************/ - else if (gSavedSettings.getBOOL("MapShowLandForSale") && (level <= DRAW_LANDFORSALE_THRESHOLD)) + else if (gSavedSettings.getBOOL("MapShowLandForSale") && (level <= DRAW_LANDFORSALE_THRESHOLD)) { // Draw the overlay image "Land for Sale / Land for Auction" LLViewerFetchedTexture* overlayimage = info->getLandForSaleImage(); @@ -506,7 +475,6 @@ void LLWorldMapView::draw() // Draw something whenever we have enough info if (overlayimage->hasGLTexture()) { - gGL.blendFunc(LLRender::BF_SOURCE_ALPHA, LLRender::BF_ONE_MINUS_SOURCE_ALPHA); gGL.getTexUnit(0)->bind(overlayimage); gGL.color4f(1.f, 1.f, 1.f, 1.f); gGL.begin(LLRender::QUADS); @@ -556,21 +524,6 @@ void LLWorldMapView::draw() } } - - - // Draw background rectangle - LLGLSUIDefault gls_ui; - { - gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); - gGL.flush(); - gGL.blendFunc(LLRender::BF_ONE_MINUS_DEST_ALPHA, LLRender::BF_DEST_ALPHA); - gGL.color4fv( mBackgroundColor.mV ); - gl_rect_2d(0, height, width, 0); - } - - gGL.flush(); - gGL.setSceneBlendType(LLRender::BT_ALPHA); - // Draw item infos if we're not zoomed out too much and there's something to draw if ((level <= DRAW_SIMINFO_THRESHOLD) && (gSavedSettings.getBOOL("MapShowInfohubs") || gSavedSettings.getBOOL("MapShowTelehubs") || @@ -771,7 +724,6 @@ bool LLWorldMapView::drawMipmapLevel(S32 width, S32 height, S32 level, bool load gGL.getTexUnit(0)->bind(simimage.get()); simimage->setAddressMode(LLTexUnit::TAM_CLAMP); - gGL.setSceneBlendType(LLRender::BT_ALPHA); gGL.color4f(1.f, 1.0f, 1.0f, 1.0f); gGL.begin(LLRender::QUADS); @@ -810,8 +762,6 @@ bool LLWorldMapView::drawMipmapLevel(S32 width, S32 height, S32 level, bool load // Used for debug only void LLWorldMapView::drawTileOutline(S32 level, F32 top, F32 left, F32 bottom, F32 right) { - gGL.blendFunc(LLRender::BF_DEST_ALPHA, LLRender::BF_ZERO); - gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); if (level == 1) gGL.color3f(1.f, 0.f, 0.f); // red |