本文整理汇总了C++中LLBumpImageList类的典型用法代码示例。如果您正苦于以下问题:C++ LLBumpImageList类的具体用法?C++ LLBumpImageList怎么用?C++ LLBumpImageList使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了LLBumpImageList类的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: bindBumpMap
// static
BOOL LLDrawPoolBump::bindBumpMap(LLDrawInfo& params, S32 channel)
{
LLImageGL* bump = NULL;
U8 bump_code = params.mBump;
LLViewerImage* tex = params.mTexture;
switch( bump_code )
{
case BE_NO_BUMP:
bump = NULL;
break;
case BE_BRIGHTNESS:
case BE_DARKNESS:
if( tex )
{
if(tex->getID()== IMG_DEFAULT)
{
return TRUE;
}
bump = gBumpImageList.getBrightnessDarknessImage( tex, bump_code );
}
break;
default:
if( bump_code < LLStandardBumpmap::sStandardBumpmapCount )
{
bump = gStandardBumpmapList[bump_code].mImage;
gBumpImageList.addTextureStats(bump_code, tex->getID(), params.mVSize);
}
break;
}
if (bump)
{
if (channel == -2)
{
gGL.getTexUnit(1)->bind(bump);
gGL.getTexUnit(0)->bind(bump);
}
else
{
gGL.getTexUnit(channel)->bind(bump);
}
return TRUE;
}
return FALSE;
}
示例2: bindBumpMap
// static
BOOL LLDrawPoolBump::bindBumpMap(LLDrawInfo& params)
{
LLImageGL* bump = NULL;
U8 bump_code = params.mBump;
LLViewerImage* tex = params.mTexture;
switch( bump_code )
{
case BE_NO_BUMP:
bump = NULL;
break;
case BE_BRIGHTNESS:
case BE_DARKNESS:
if( tex )
{
bump = gBumpImageList.getBrightnessDarknessImage( tex, bump_code );
}
break;
default:
if( bump_code < LLStandardBumpmap::sStandardBumpmapCount )
{
bump = gStandardBumpmapList[bump_code].mImage;
gBumpImageList.addTextureStats(bump_code, tex->getID(), params.mVSize, 1, 1);
}
break;
}
if (bump)
{
bump->bind(1);
bump->bind(0);
return TRUE;
}
return FALSE;
}