当前位置: 首页>>代码示例>>C++>>正文


C++ LLColor4::setVec方法代码示例

本文整理汇总了C++中LLColor4::setVec方法的典型用法代码示例。如果您正苦于以下问题:C++ LLColor4::setVec方法的具体用法?C++ LLColor4::setVec怎么用?C++ LLColor4::setVec使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在LLColor4的用法示例。


在下文中一共展示了LLColor4::setVec方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: getAttributeColor

//static
BOOL LLUICtrlFactory::getAttributeColor(LLXMLNodePtr node, const std::string& name, LLColor4& color)
{
	std::string colorstring;
	BOOL res = node->getAttributeString(name.c_str(), colorstring);
	if (res && LLUI::sColorsGroup)
	{
		if (LLUI::sColorsGroup->controlExists(colorstring))
		{
			color.setVec(LLUI::sColorsGroup->getColor(colorstring));
		}
		else
		{
			res = FALSE;
		}
	}
	if (!res)
	{
		res = LLColor4::parseColor(colorstring, &color);
	}	
	if (!res)
	{
		res = node->getAttributeColor(name.c_str(), color);
	}
	return res;
}
开发者ID:Xara,项目名称:Meerkat-Viewer,代码行数:26,代码来源:lluictrlfactory.cpp

示例2: init_colors

void init_colors()
{
	gTrackColor = LLColor4::red;
	gDisabledTrackColor.setVec(		0.5f, 0.f, 0.f, 1.f );
	gLandmarkMapColor = LLColor4::red;
	gLocationMapColor.setVec(		0.f, 0.72f, 1.f, 1.f);
	gTelehubMapColor.setVec(		0.9f, 0.9f, 0.f, 1.f); // dk yellow
	gEventColor.setVec(				1.f, 0.5f, 1.f, 1.f );
	gPopularColor.setVec(			1.f, 0.0f, 0.f, 1.f );
	gPickColor.setVec(				1.f, 0.0f, 0.f, 1.f );
	gHomeColor.setVec(				0.f, 0.5f, 1.f, 1.f );
}
开发者ID:1234-,项目名称:SingularityViewer,代码行数:12,代码来源:llcolorscheme.cpp

示例3: init_colors

void init_colors()
{
	gTrackColor	= LLColor4::red;
	gDisabledTrackColor.setVec(		0.5f, 0.f, 0.f, 1.f );

	gSelfMapColor     = LLColor4::white;
	gAvatarMapColor   = LLColor4::green;
	gFriendMapColor   = LLColor4::yellow;
	// fleshy color
	//gAvatarMapColor.setVec( 255.f/255.f, 223.f/255.f, 170.f/255.f, 1.f);

	gLandmarkMapColor = LLColor4::red;
	gLocationMapColor.setVec(		0.f, 0.72f, 1.f, 1.f);
	gTelehubMapColor.setVec(		0.9f, 0.9f, 0.f, 1.f); // dk yellow
	gFrustumMapColor.setVec(		1.f, 1.f, 1.f, 0.08f);
	gRotatingFrustumMapColor.setVec(1.f, 1.f, 1.f, 0.2f);
	gEventColor.setVec(				1.f, 0.5f, 1.f, 1.f );
	gPopularColor.setVec(			1.f, 0.0f, 0.f, 1.f );
	gPickColor.setVec(				1.f, 0.0f, 0.f, 1.f );
	gHomeColor.setVec(				0.f, 0.5f, 1.f, 1.f );
}
开发者ID:AlexRa,项目名称:Kirstens-clone,代码行数:21,代码来源:llcolorscheme.cpp

示例4: triggerLocal

void LLHUDEffectSpiral::triggerLocal()
{
	mKillTime = mTimer.getElapsedTimeF32() + mDuration;

	BOOL show_beam = gSavedSettings.getBOOL("ShowSelectionBeam");

	LLColor4 color;
	color.setVec(mColor);

	if (!mPartSourcep)
	{
		if (!mTargetObject.isNull() && !mSourceObject.isNull())
		{
			if (show_beam)
			{
				LLPointer<LLViewerPartSourceBeam> psb = new LLViewerPartSourceBeam;
				psb->setColor(color);
				psb->setSourceObject(mSourceObject);
				psb->setTargetObject(mTargetObject);
				psb->setOwnerUUID(gAgent.getID());
				LLViewerPartSim::getInstance()->addPartSource(psb);
				mPartSourcep = psb;
			}
		}
		else
		{
			if (!mSourceObject.isNull() && !mPositionGlobal.isExactlyZero())
			{
				if (show_beam)
				{
					LLPointer<LLViewerPartSourceBeam> psb = new LLViewerPartSourceBeam;
					psb->setSourceObject(mSourceObject);
					psb->setTargetObject(NULL);
					psb->setColor(color);
					psb->mLKGTargetPosGlobal = mPositionGlobal;
					psb->setOwnerUUID(gAgent.getID());
					LLViewerPartSim::getInstance()->addPartSource(psb);
					mPartSourcep = psb;
				}
			}
			else
			{
				LLVector3 pos;
				if (mSourceObject)
				{
					pos = mSourceObject->getPositionAgent();
				}
				else
				{
					pos = gAgent.getPosAgentFromGlobal(mPositionGlobal);
				}
				LLPointer<LLViewerPartSourceSpiral> pss = new LLViewerPartSourceSpiral(pos);
				if (!mSourceObject.isNull())
				{
					pss->setSourceObject(mSourceObject);
				}
				pss->setColor(color);
				pss->setOwnerUUID(gAgent.getID());
				LLViewerPartSim::getInstance()->addPartSource(pss);
				mPartSourcep = pss;
			}
		}
	}
	else
	{
		LLPointer<LLViewerPartSource>& ps = mPartSourcep;
		if (mPartSourcep->getType() == LLViewerPartSource::LL_PART_SOURCE_BEAM)
		{
			LLViewerPartSourceBeam *psb = (LLViewerPartSourceBeam *)ps.get();
			psb->setSourceObject(mSourceObject);
			psb->setTargetObject(mTargetObject);
			psb->setColor(color);
			if (mTargetObject.isNull())
			{
				psb->mLKGTargetPosGlobal = mPositionGlobal;
			}
		}
		else
		{
			LLViewerPartSourceSpiral *pss = (LLViewerPartSourceSpiral *)ps.get();
			pss->setSourceObject(mSourceObject);
		}
	}

	mbInit = TRUE;
}
开发者ID:Boy,项目名称:rainbow,代码行数:86,代码来源:llhudeffecttrail.cpp


注:本文中的LLColor4::setVec方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。