Change texture default to non-auto-alphamaskable, non-pickable. Only 'fetchable' textures may qualify for either.

This commit is contained in:
Shyotl
2014-06-22 03:53:08 -05:00
parent 5cb5d284c3
commit 96df7b82de
4 changed files with 10 additions and 17 deletions

View File

@@ -914,6 +914,7 @@ LLViewerFetchedTexture::LLViewerFetchedTexture(const LLUUID& id, const LLHost& h
{
init(TRUE) ;
generateGLTexture() ;
mGLTexturep->setNeedsAlphaAndPickMask(TRUE) ;
}
LLViewerFetchedTexture::LLViewerFetchedTexture(const LLImageRaw* raw, BOOL usemipmaps)
@@ -928,6 +929,7 @@ LLViewerFetchedTexture::LLViewerFetchedTexture(const std::string& url, const LLU
{
init(TRUE) ;
generateGLTexture() ;
mGLTexturep->setNeedsAlphaAndPickMask(TRUE) ;
}
void LLViewerFetchedTexture::init(bool firstinit)
@@ -3172,8 +3174,6 @@ LLViewerMediaTexture::LLViewerMediaTexture(const LLUUID& id, BOOL usemipmaps, LL
mGLTexturep->setAllowCompression(false);
mGLTexturep->setNeedsAlphaAndPickMask(FALSE) ;
mIsPlaying = FALSE ;
setMediaImpl() ;
@@ -3204,7 +3204,6 @@ void LLViewerMediaTexture::reinit(BOOL usemipmaps /* = TRUE */)
mUseMipMaps = usemipmaps ;
getLastReferencedTimer()->reset() ;
mGLTexturep->setUseMipMaps(mUseMipMaps) ;
mGLTexturep->setNeedsAlphaAndPickMask(FALSE) ;
}
void LLViewerMediaTexture::setUseMipMaps(BOOL mipmap)

View File

@@ -298,7 +298,6 @@ void LLSkyTex::create(const F32 brightness)
void LLSkyTex::createGLImage(S32 which)
{
mTexture[which]->setNeedsAlphaAndPickMask(false); //Needed, else analyzeAlpha is called every frame for each texture.
mTexture[which]->createGLTexture(0, mImageRaw[which], 0, TRUE, LLGLTexture::LOCAL);
mTexture[which]->setAddressMode(LLTexUnit::TAM_CLAMP);
}