Huge renderer update (WIP). Still plenty to do, especially pertaining to UI.
-Nametag bubble visbility is oddly inconsistent. May vanish with future planned UI merges... -VBOs are PAINFULLY slow on ATI hardware. This repos self-compiled davep/shining-fixes branch, so I'll leave the ball in LL's court for now regarding that.
This commit is contained in:
@@ -170,7 +170,6 @@ void LLVisualParamHint::preRender(BOOL clear_depth)
|
||||
BOOL LLVisualParamHint::render()
|
||||
{
|
||||
LLVisualParamReset::sDirty = TRUE;
|
||||
LLVOAvatar* avatarp = gAgentAvatarp;
|
||||
|
||||
gGL.matrixMode(LLRender::MM_PROJECTION);
|
||||
gGL.pushMatrix();
|
||||
@@ -181,6 +180,11 @@ BOOL LLVisualParamHint::render()
|
||||
gGL.pushMatrix();
|
||||
gGL.loadIdentity();
|
||||
|
||||
if (LLGLSLShader::sNoFixedFunction)
|
||||
{
|
||||
gUIProgram.bind();
|
||||
}
|
||||
|
||||
LLGLSUIDefault gls_ui;
|
||||
//LLGLState::verify(TRUE);
|
||||
mBackgroundp->draw(0, 0, mFullWidth, mFullHeight);
|
||||
@@ -198,7 +202,7 @@ BOOL LLVisualParamHint::render()
|
||||
const std::string& cam_target_mesh_name = mVisualParam->getCameraTargetName();
|
||||
if( !cam_target_mesh_name.empty() )
|
||||
{
|
||||
cam_target_joint = (LLViewerJointMesh*)avatarp->getJoint( cam_target_mesh_name );
|
||||
cam_target_joint = (LLViewerJointMesh*)gAgentAvatarp->getJoint( cam_target_mesh_name );
|
||||
}
|
||||
if( !cam_target_joint )
|
||||
{
|
||||
@@ -206,7 +210,7 @@ BOOL LLVisualParamHint::render()
|
||||
}
|
||||
if( !cam_target_joint )
|
||||
{
|
||||
cam_target_joint = (LLViewerJointMesh*)avatarp->getJoint("mHead");
|
||||
cam_target_joint = (LLViewerJointMesh*)gAgentAvatarp->getJoint("mHead");
|
||||
}
|
||||
|
||||
LLQuaternion avatar_rotation;
|
||||
@@ -233,7 +237,7 @@ BOOL LLVisualParamHint::render()
|
||||
LLViewerCamera::getInstance()->setAspect((F32)mFullWidth / (F32)mFullHeight);
|
||||
LLViewerCamera::getInstance()->setOriginAndLookAt(
|
||||
camera_pos, // camera
|
||||
LLVector3(0.f, 0.f, 1.f), // up
|
||||
LLVector3::z_axis, // up
|
||||
target_pos ); // point of interest
|
||||
|
||||
LLViewerCamera::getInstance()->setPerspective(FALSE, mOrigin.mX, mOrigin.mY, mFullWidth, mFullHeight, FALSE);
|
||||
@@ -248,7 +252,7 @@ BOOL LLVisualParamHint::render()
|
||||
gGL.setSceneBlendType(LLRender::BT_ALPHA);
|
||||
gGL.setAlphaRejectSettings(LLRender::CF_DEFAULT);
|
||||
}
|
||||
avatarp->setVisualParamWeight(mVisualParam, mLastParamWeight);
|
||||
gAgentAvatarp->setVisualParamWeight(mVisualParam, mLastParamWeight);
|
||||
gGL.color4f(1,1,1,1);
|
||||
mGLTexturep->setGLTextureCreated(true);
|
||||
return TRUE;
|
||||
|
||||
Reference in New Issue
Block a user