本文整理汇总了C++中LLControlGroup::setVector3方法的典型用法代码示例。如果您正苦于以下问题:C++ LLControlGroup::setVector3方法的具体用法?C++ LLControlGroup::setVector3怎么用?C++ LLControlGroup::setVector3使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类LLControlGroup
的用法示例。
在下文中一共展示了LLControlGroup::setVector3方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: handleRightMouseDown
BOOL LLToolCompGun::handleRightMouseDown(S32 x, S32 y, MASK mask)
{
/* JC - suppress context menu 8/29/2002
// On right mouse, go through some convoluted steps to
// make the build menu appear.
setCurrentTool( (LLTool*) mNull );
// This should return FALSE, meaning the context menu will
// be shown.
return FALSE;
*/
// Returning true will suppress the context menu
// NaCl - Rightclick-mousewheel zoom
if (!(gKeyboard->currentMask(TRUE) & MASK_ALT))
{
static LLCachedControl<LLVector3> _NACL_MLFovValues(gSavedSettings,"_NACL_MLFovValues");
static LLCachedControl<F32> CameraAngle(gSavedSettings,"CameraAngle");
LLVector3 vTemp=_NACL_MLFovValues;
vTemp.mV[0]=CameraAngle;
vTemp.mV[2]=1.0f;
gSavedSettings.setVector3("_NACL_MLFovValues",vTemp);
gSavedSettings.setF32("CameraAngle",vTemp.mV[1]);
return TRUE;
}
// NaCl End
// <FS:Ansariel> Enable context/pie menu in mouselook
//return TRUE;
return (!gSavedSettings.getBOOL("FSEnableRightclickMenuInMouselook"));
// </FS:Ansariel>
}
示例2: handleRightMouseUp
// NaCl - Rightclick-mousewheel zoom
BOOL LLToolCompGun::handleRightMouseUp(S32 x, S32 y, MASK mask)
{
static LLCachedControl<LLVector3> _NACL_MLFovValues(gSavedSettings,"_NACL_MLFovValues");
static LLCachedControl<F32> CameraAngle(gSavedSettings,"CameraAngle");
LLVector3 vTemp=_NACL_MLFovValues;
// Only reset if zoomed
if (vTemp.mV[2] == 1.0f)
{
vTemp.mV[1]=CameraAngle;
vTemp.mV[2]=0.0f;
gSavedSettings.setVector3("_NACL_MLFovValues",vTemp);
gSavedSettings.setF32("CameraAngle",vTemp.mV[0]);
}
return TRUE;
}
示例3: handleScrollWheel
BOOL LLToolCompGun::handleScrollWheel(S32 x, S32 y, S32 clicks)
{
// NaCl - Rightclick-mousewheel zoom
static LLCachedControl<LLVector3> _NACL_MLFovValues(gSavedSettings, "_NACL_MLFovValues");
static LLCachedControl<F32> CameraAngle(gSavedSettings, "CameraAngle");
LLVector3 vTemp = _NACL_MLFovValues;
vTemp.mV[VY] = CameraAngle;
if (vTemp.mV[VZ] > 0.0f)
{
vTemp.mV[VY] = llclamp(vTemp.mV[VY] + (F32)(clicks * 0.1f), LLViewerCamera::getInstance()->getMinView(), LLViewerCamera::getInstance()->getMaxView());
gSavedSettings.setVector3("_NACL_MLFovValues", vTemp);
gSavedSettings.setF32("CameraAngle", vTemp.mV[VY]);
}
else if (clicks > 0 && gSavedSettings.getBOOL("FSScrollWheelExitsMouselook"))
// NaCl End
{
gAgentCamera.changeCameraToDefault();
}
return TRUE;
}