Sync llcommon with Alchemy a bit.
llmath::llround->ll_round LL_ICC->LL_INTELC Add llpredicate Add LL_CPP11 macro Remove llhash Update llinitparam, llsd and all relatives of it.
This commit is contained in:
@@ -1254,8 +1254,8 @@ LLRect get_whole_screen_region()
|
||||
if (zoom_factor > 1.f)
|
||||
{
|
||||
S32 num_horizontal_tiles = llceil(zoom_factor);
|
||||
S32 tile_width = llmath::llround((F32)gViewerWindow->getWorldViewWidthScaled() / zoom_factor);
|
||||
S32 tile_height = llmath::llround((F32)gViewerWindow->getWorldViewHeightScaled() / zoom_factor);
|
||||
S32 tile_width = ll_round((F32)gViewerWindow->getWorldViewWidthScaled() / zoom_factor);
|
||||
S32 tile_height = ll_round((F32)gViewerWindow->getWorldViewHeightScaled() / zoom_factor);
|
||||
int tile_y = sub_region / num_horizontal_tiles;
|
||||
int tile_x = sub_region - (tile_y * num_horizontal_tiles);
|
||||
|
||||
@@ -1539,8 +1539,8 @@ void render_ui_2d()
|
||||
int pos_y = sub_region / llceil(zoom_factor);
|
||||
int pos_x = sub_region - (pos_y*llceil(zoom_factor));
|
||||
// offset for this tile
|
||||
LLFontGL::sCurOrigin.mX -= llmath::llround((F32)gViewerWindow->getWindowWidthScaled() * (F32)pos_x / zoom_factor);
|
||||
LLFontGL::sCurOrigin.mY -= llmath::llround((F32)gViewerWindow->getWindowHeightScaled() * (F32)pos_y / zoom_factor);
|
||||
LLFontGL::sCurOrigin.mX -= ll_round((F32)gViewerWindow->getWindowWidthScaled() * (F32)pos_x / zoom_factor);
|
||||
LLFontGL::sCurOrigin.mY -= ll_round((F32)gViewerWindow->getWindowHeightScaled() * (F32)pos_y / zoom_factor);
|
||||
}
|
||||
|
||||
stop_glerror();
|
||||
|
||||
Reference in New Issue
Block a user