Kanji
#1
I’m trying apply Ripple3D effect to a layer that is behind another layer, and partially visible.
However, the tips of the waves appear penetrating the upper layer, when I run the action.
I tried the solution written here, but I couldn’t even make it build because of the problem with referenct to glDepthFunc.
How can I apply Ripple3D to a layer (or sprite) without any side-effect to other object?
zhangxm
#2
I think Ripple3D and other effect can not be used like this way. I effect the whole view.
Kanji
#3
Thanks for your reply!
The demo app shows Ripple3D working without any side-effects to other object like label or menu icon overlaid on the moving node.
Its source code is cocos2d-x/tests/tests/EffectsTest/EffectsTest.cpp.
I’m trying to do the same way, but it seems I’m doing something wrong…
Kanji
#4
I figured it myself.
Adding the line below fixed everything.
CCDirector::sharedDirector()->setDepthTest(false);