git-svn-id: svn://db.shs.com.ru/libs@605 a8b55f48-bf90-11e4-a774-851b48703e85
This commit is contained in:
@@ -49,16 +49,17 @@ void RendererSimple::resizeFBO(int w, int h) {
|
||||
void RendererSimple::renderScene() {
|
||||
int passes = (view.lightsCount() - 1) / 8 + 1;
|
||||
//QMatrix4x4 pm = getGLMatrix(GL_PROJECTION_MATRIX), mvm = getGLMatrix(GL_MODELVIEW_MATRIX), pmvm = pm * mvm, lpm, lmvm, lpmvm;
|
||||
glSetCapEnabled(GL_MULTISAMPLE, view.isFeatureEnabled(QGLView::qglMSAA));
|
||||
//glSetCapEnabled(GL_MULTISAMPLE, view.isFeatureEnabled(QGLView::qglMSAA));
|
||||
if (passes < 1) passes = 1;
|
||||
//glEnable(GL_FOG);
|
||||
if (view.isFeatureEnabled(QGLView::qglFXAA)) fbo.bind();
|
||||
//if (view.isFeatureEnabled(QGLView::qglFXAA)) fbo.bind();
|
||||
//glEnable(GL_TEXTURE_2D);
|
||||
if (passes > 1) {
|
||||
if (passes > 1 || view.isFeatureEnabled(QGLView::qglFXAA)) {
|
||||
fbo.bind();
|
||||
fbo.setWriteBuffer(0);
|
||||
glClearFramebuffer();
|
||||
}
|
||||
} else
|
||||
glSetCapEnabled(GL_MULTISAMPLE, view.isFeatureEnabled(QGLView::qglMSAA));
|
||||
glEnable(GL_RESCALE_NORMAL);
|
||||
for (int l = 0; l < passes; ++l) {
|
||||
if (passes > 1) fbo.setWriteBuffer(1);
|
||||
|
||||
Reference in New Issue
Block a user