Removed erroneous switch to the front buffer when reading depth values in sculptmode and retopo.

This commit is contained in:
Nicholas Bishop
2006-11-12 21:28:09 +00:00
parent 3a1b7ece40
commit 521815eab2
2 changed files with 0 additions and 4 deletions

View File

@@ -2689,10 +2689,8 @@ void view3d_update_depths(View3D *v3d)
}
if(d->damaged) {
glReadBuffer(GL_FRONT);
glReadPixels(v3d->area->winrct.xmin,v3d->area->winrct.ymin,d->w,d->h,
GL_DEPTH_COMPONENT,GL_FLOAT, d->depths);
glReadBuffer(GL_BACK);
glGetDoublev(GL_DEPTH_RANGE,d->depth_range);

View File

@@ -547,9 +547,7 @@ float get_depth(short x, short y)
x+= curarea->winrct.xmin;
y+= curarea->winrct.ymin;
glReadBuffer(GL_FRONT);
glReadPixels(x, y, 1, 1, GL_DEPTH_COMPONENT, GL_FLOAT, &depth);
glReadBuffer(GL_BACK);
return depth;
}