summaryrefslogtreecommitdiff
path: root/indra/newview/llglsandbox.cpp
diff options
context:
space:
mode:
authorSteven Bennetts <steve@lindenlab.com>2008-09-12 06:27:13 +0000
committerSteven Bennetts <steve@lindenlab.com>2008-09-12 06:27:13 +0000
commitda94c0eaa2ce2711f0ae26968e87ef3e409126a9 (patch)
treee0b23896f17e0a0ea60160b2c7e39331f3cb9668 /indra/newview/llglsandbox.cpp
parent642cdd95726755b7c24c7f2b25e2fea8e49b5b9b (diff)
QAR-855 Viewer 1.21 RC 2
merge viewer_1-21 94770-96059 -> release
Diffstat (limited to 'indra/newview/llglsandbox.cpp')
-rw-r--r--indra/newview/llglsandbox.cpp41
1 files changed, 0 insertions, 41 deletions
diff --git a/indra/newview/llglsandbox.cpp b/indra/newview/llglsandbox.cpp
index 6b89d52b68..a021a66af2 100644
--- a/indra/newview/llglsandbox.cpp
+++ b/indra/newview/llglsandbox.cpp
@@ -1111,44 +1111,3 @@ void LLViewerObjectList::renderObjectBeacons()
}
-void pre_show_depth_buffer()
-{
- glClear(GL_STENCIL_BUFFER_BIT);
- glEnable(GL_STENCIL_TEST);
- glStencilFunc(GL_ALWAYS,0,0);
- glStencilOp(GL_INCR,GL_INCR,GL_INCR);
-}
-
-void post_show_depth_buffer()
-{
- int xsize =500, ysize =500;
- U8 *buf = new U8[xsize*ysize];
-
- glReadPixels(0,0,xsize,ysize,GL_STENCIL_INDEX,GL_UNSIGNED_BYTE, buf);
-
- int total = 0;
- int i;
- for (i=0;i<xsize*ysize;i++)
- {
- total += buf[i];
- buf[i] <<= 3;
- }
-
- float DC = (float)total/(float)(ysize*xsize);
- int DCline = llfloor((xsize-20) * DC / 10.0f);
- int stride = xsize / 10;
-
- int y = 2;
-
- for (i=0;i<DCline;i++)
- {
- if (i % stride == 0) i+=2;
- if (i > xsize) y=6;
- buf[ysize*(y+0)+i]=255;
- buf[ysize*(y+1)+i]=255;
- buf[ysize*(y+2)+i]=255;
- }
- glDrawPixels(xsize,ysize,GL_RED,GL_UNSIGNED_BYTE,buf);
-
- delete [] buf;
-}