summaryrefslogtreecommitdiff
path: root/indra/llrender
diff options
context:
space:
mode:
authorDessie Linden <dessie@lindenlab.com>2010-11-15 12:05:05 -0800
committerDessie Linden <dessie@lindenlab.com>2010-11-15 12:05:05 -0800
commit5bfa6095db3a0a9c7367b7dde3f2e24e023cb7f4 (patch)
tree1ab6b0946d7bfb881a2ccfaa2382d24b46a6b729 /indra/llrender
parent65d847de38614a67ed1bdd86445c1c80f4638cc3 (diff)
parentc13f6afe73bea4311a91d65dde2f6e1c5bc453b3 (diff)
Added viewer-release.release-viewer.jira parameter to write build comment to DRTVWR-13
Diffstat (limited to 'indra/llrender')
-rw-r--r--indra/llrender/llfontgl.cpp18
-rw-r--r--indra/llrender/llimagegl.cpp12
-rw-r--r--indra/llrender/llimagegl.h1
-rw-r--r--indra/llrender/llrendertarget.cpp11
4 files changed, 25 insertions, 17 deletions
diff --git a/indra/llrender/llfontgl.cpp b/indra/llrender/llfontgl.cpp
index 386bb987f9..13008292f6 100644
--- a/indra/llrender/llfontgl.cpp
+++ b/indra/llrender/llfontgl.cpp
@@ -977,37 +977,43 @@ LLFontGL::VAlign LLFontGL::vAlignFromName(const std::string& name)
//static
LLFontGL* LLFontGL::getFontMonospace()
{
- return getFont(LLFontDescriptor("Monospace","Monospace",0));
+ static LLFontGL* fontp = getFont(LLFontDescriptor("Monospace","Monospace",0));
+ return fontp;
}
//static
LLFontGL* LLFontGL::getFontSansSerifSmall()
{
- return getFont(LLFontDescriptor("SansSerif","Small",0));
+ static LLFontGL* fontp = getFont(LLFontDescriptor("SansSerif","Small",0));
+ return fontp;
}
//static
LLFontGL* LLFontGL::getFontSansSerif()
{
- return getFont(LLFontDescriptor("SansSerif","Medium",0));
+ static LLFontGL* fontp = getFont(LLFontDescriptor("SansSerif","Medium",0));
+ return fontp;
}
//static
LLFontGL* LLFontGL::getFontSansSerifBig()
{
- return getFont(LLFontDescriptor("SansSerif","Large",0));
+ static LLFontGL* fontp = getFont(LLFontDescriptor("SansSerif","Large",0));
+ return fontp;
}
//static
LLFontGL* LLFontGL::getFontSansSerifHuge()
{
- return getFont(LLFontDescriptor("SansSerif","Huge",0));
+ static LLFontGL* fontp = getFont(LLFontDescriptor("SansSerif","Large",0));
+ return fontp;
}
//static
LLFontGL* LLFontGL::getFontSansSerifBold()
{
- return getFont(LLFontDescriptor("SansSerif","Medium",BOLD));
+ static LLFontGL* fontp = getFont(LLFontDescriptor("SansSerif","Medium",BOLD));
+ return fontp;
}
//static
diff --git a/indra/llrender/llimagegl.cpp b/indra/llrender/llimagegl.cpp
index 9d037f2565..72dd283bc7 100644
--- a/indra/llrender/llimagegl.cpp
+++ b/indra/llrender/llimagegl.cpp
@@ -368,6 +368,18 @@ void LLImageGL::restoreGL()
}
}
+//static
+void LLImageGL::dirtyTexOptions()
+{
+ for (std::set<LLImageGL*>::iterator iter = sImageList.begin();
+ iter != sImageList.end(); iter++)
+ {
+ LLImageGL* glimage = *iter;
+ glimage->mTexOptionsDirty = true;
+ stop_glerror();
+ }
+
+}
//----------------------------------------------------------------------------
//for server side use only.
diff --git a/indra/llrender/llimagegl.h b/indra/llrender/llimagegl.h
index 87a835cdcc..6c980984c0 100644
--- a/indra/llrender/llimagegl.h
+++ b/indra/llrender/llimagegl.h
@@ -64,6 +64,7 @@ public:
// Save off / restore GL textures
static void destroyGL(BOOL save_state = TRUE);
static void restoreGL();
+ static void dirtyTexOptions();
// Sometimes called externally for textures not using LLImageGL (should go away...)
static S32 updateBoundTexMem(const S32 mem, const S32 ncomponents, S32 category) ;
diff --git a/indra/llrender/llrendertarget.cpp b/indra/llrender/llrendertarget.cpp
index 890230bbe5..7205210fcc 100644
--- a/indra/llrender/llrendertarget.cpp
+++ b/indra/llrender/llrendertarget.cpp
@@ -384,8 +384,6 @@ void LLRenderTarget::flush(BOOL fetch_depth)
}
else
{
-#if !LL_DARWIN
-
stop_glerror();
glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, 0);
@@ -429,7 +427,6 @@ void LLRenderTarget::flush(BOOL fetch_depth)
}
}
}
-#endif
glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, 0);
}
@@ -438,7 +435,6 @@ void LLRenderTarget::flush(BOOL fetch_depth)
void LLRenderTarget::copyContents(LLRenderTarget& source, S32 srcX0, S32 srcY0, S32 srcX1, S32 srcY1,
S32 dstX0, S32 dstY0, S32 dstX1, S32 dstY1, U32 mask, U32 filter)
{
-#if !LL_DARWIN
gGL.flush();
if (!source.mFBO || !mFBO)
{
@@ -477,14 +473,12 @@ void LLRenderTarget::copyContents(LLRenderTarget& source, S32 srcX0, S32 srcY0,
stop_glerror();
}
}
-#endif
}
//static
void LLRenderTarget::copyContentsToFramebuffer(LLRenderTarget& source, S32 srcX0, S32 srcY0, S32 srcX1, S32 srcY1,
S32 dstX0, S32 dstY0, S32 dstX1, S32 dstY1, U32 mask, U32 filter)
{
-#if !LL_DARWIN
if (!source.mFBO)
{
llerrs << "Cannot copy framebuffer contents for non FBO render targets." << llendl;
@@ -501,7 +495,6 @@ void LLRenderTarget::copyContentsToFramebuffer(LLRenderTarget& source, S32 srcX0
glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, 0);
stop_glerror();
}
-#endif
}
BOOL LLRenderTarget::isComplete() const
@@ -646,7 +639,6 @@ void LLMultisampleBuffer::allocate(U32 resx, U32 resy, U32 color_fmt, BOOL depth
void LLMultisampleBuffer::addColorAttachment(U32 color_fmt)
{
-#if !LL_DARWIN
if (color_fmt == 0)
{
return;
@@ -687,12 +679,10 @@ void LLMultisampleBuffer::addColorAttachment(U32 color_fmt)
}
mTex.push_back(tex);
-#endif
}
void LLMultisampleBuffer::allocateDepth()
{
-#if !LL_DARWIN
glGenRenderbuffersEXT(1, (GLuint* ) &mDepth);
glBindRenderbufferEXT(GL_RENDERBUFFER_EXT, mDepth);
if (mStencil)
@@ -703,6 +693,5 @@ void LLMultisampleBuffer::allocateDepth()
{
glRenderbufferStorageMultisampleEXT(GL_RENDERBUFFER_EXT, mSamples, GL_DEPTH_COMPONENT16_ARB, mResX, mResY);
}
-#endif
}