summaryrefslogtreecommitdiff
path: root/legacy
diff options
context:
space:
mode:
authorSung Park <sungwoo@gmail.com>2012-06-28 03:37:13 +0000
committerSung Park <sungwoo@gmail.com>2012-06-28 03:37:13 +0000
commit06aa05c2c396eba0cb36636c6042a5762935deb9 (patch)
tree2811de627e9c1cb0513ef9c926c1481d61fef403 /legacy
parentecde500eb86fb98e15d759bd39eb0b1391da9c58 (diff)
EvasGL: Adding MSAA for depth_24_stencil_8 format that was missing
from the previous commit. SVN revision: 72970
Diffstat (limited to 'legacy')
-rw-r--r--legacy/evas/src/modules/engines/gl_x11/evas_engine.c29
1 files changed, 24 insertions, 5 deletions
diff --git a/legacy/evas/src/modules/engines/gl_x11/evas_engine.c b/legacy/evas/src/modules/engines/gl_x11/evas_engine.c
index 55cd7b2e19..9fa5dcba16 100644
--- a/legacy/evas/src/modules/engines/gl_x11/evas_engine.c
+++ b/legacy/evas/src/modules/engines/gl_x11/evas_engine.c
@@ -3367,7 +3367,10 @@ _attach_fbo_surface(Render_Engine *data __UNUSED__,
3367 3367
3368 // Attach texture to FBO 3368 // Attach texture to FBO
3369 if (sfc->rt_msaa_samples) 3369 if (sfc->rt_msaa_samples)
3370 glsym_glFramebufferTexture2DMultisample(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, sfc->rt_tex, 0, sfc->rt_msaa_samples); 3370 glsym_glFramebufferTexture2DMultisample(GL_FRAMEBUFFER,
3371 GL_COLOR_ATTACHMENT0,
3372 GL_TEXTURE_2D, sfc->rt_tex,
3373 0, sfc->rt_msaa_samples);
3371 else 3374 else
3372 glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, 3375 glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0,
3373 GL_TEXTURE_2D, sfc->rt_tex, 0); 3376 GL_TEXTURE_2D, sfc->rt_tex, 0);
@@ -3387,10 +3390,26 @@ _attach_fbo_surface(Render_Engine *data __UNUSED__,
3387 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST); 3390 glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
3388 glTexImage2D(GL_TEXTURE_2D, 0, GL_DEPTH_STENCIL_OES, sfc->w, sfc->h, 3391 glTexImage2D(GL_TEXTURE_2D, 0, GL_DEPTH_STENCIL_OES, sfc->w, sfc->h,
3389 0, GL_DEPTH_STENCIL_OES, GL_UNSIGNED_INT_24_8_OES, NULL); 3392 0, GL_DEPTH_STENCIL_OES, GL_UNSIGNED_INT_24_8_OES, NULL);
3390 glFramebufferTexture2D(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT, 3393 if (sfc->rt_msaa_samples)
3391 GL_TEXTURE_2D, sfc->rb_depth_stencil, 0); 3394 {
3392 glFramebufferTexture2D(GL_FRAMEBUFFER, GL_STENCIL_ATTACHMENT, 3395 glsym_glFramebufferTexture2DMultisample(GL_FRAMEBUFFER,
3393 GL_TEXTURE_2D, sfc->rb_depth_stencil, 0); 3396 GL_DEPTH_ATTACHMENT,
3397 GL_TEXTURE_2D,
3398 sfc->rb_depth_stencil,
3399 0, sfc->rt_msaa_samples);
3400 glsym_glFramebufferTexture2DMultisample(GL_FRAMEBUFFER,
3401 GL_STENCIL_ATTACHMENT,
3402 GL_TEXTURE_2D,
3403 sfc->rb_depth_stencil,
3404 0, sfc->rt_msaa_samples);
3405 }
3406 else
3407 {
3408 glFramebufferTexture2D(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT,
3409 GL_TEXTURE_2D, sfc->rb_depth_stencil, 0);
3410 glFramebufferTexture2D(GL_FRAMEBUFFER, GL_STENCIL_ATTACHMENT,
3411 GL_TEXTURE_2D, sfc->rb_depth_stencil, 0);
3412 }
3394 glBindTexture(GL_TEXTURE_2D, curr_tex); 3413 glBindTexture(GL_TEXTURE_2D, curr_tex);
3395 3414
3396#else 3415#else