如何在 Android 中对 GLSurfaceView 应用多重效果?
How to apply multiple effect on GLSurfaceView in Android?
这是我的代码,运行良好
mEffect = effectFactory.createEffect(EffectFactory.EFFECT_BLACKWHITE);
mEffect.setParameter("black", .9f);
mEffect.setParameter("white", .5f);
break;
但是现在我想要两个效果,怎么办?
mEffect = effectFactory.createEffect(EffectFactory.EFFECT_BLACKWHITE);
mEffect.setParameter("brightness", 2.0f);
我想用 "grayscale image"
合并这两种效果
mEffect = effectFactory.createEffect(EffectFactory.EFFECT_GRAYSCALE);
我也看了这个文档,但没有帮助[GLSurfaceView][1]
1: https://developer.android.com/reference/android/opengl/GLSurfaceView.html ,
EGLDisplay
1: https://developer.android.com/reference/android/opengl/EGLDisplay.html and Effect factory too
这是我的代码,运行良好
mEffect = effectFactory.createEffect(EffectFactory.EFFECT_BLACKWHITE);
mEffect.setParameter("black", .9f);
mEffect.setParameter("white", .5f);
break;
但是现在我想要两个效果,怎么办?
mEffect = effectFactory.createEffect(EffectFactory.EFFECT_BLACKWHITE);
mEffect.setParameter("brightness", 2.0f);
我想用 "grayscale image"
合并这两种效果 mEffect = effectFactory.createEffect(EffectFactory.EFFECT_GRAYSCALE);
我也看了这个文档,但没有帮助[GLSurfaceView][1]
1: https://developer.android.com/reference/android/opengl/GLSurfaceView.html , EGLDisplay
1: https://developer.android.com/reference/android/opengl/EGLDisplay.html and Effect factory too