Revision 061449ed
Added by Leszek Koltunski almost 4 years ago
src/main/java/org/distorted/examples/movingglow/MovingGlowRenderer.java | ||
---|---|---|
52 | 52 |
|
53 | 53 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
54 | 54 |
|
55 |
class MovingGlowRenderer implements GLSurfaceView.Renderer,EffectListener
|
|
55 |
class MovingGlowRenderer implements GLSurfaceView.Renderer, EffectListener, DistortedLibrary.ExceptionListener
|
|
56 | 56 |
{ |
57 | 57 |
private static final int[] colors = new int[] {0,0,1, 1,0,1, 1,0,0, 1,1,0, 0,1,0, 1,1,1}; // blue, pink, red, yellow, green, white |
58 | 58 |
private static final int FLASH_TIME = 2000; |
... | ... | |
194 | 194 |
FragmentEffectChroma.enable(); |
195 | 195 |
PostprocessEffectGlow.enable(); |
196 | 196 |
|
197 |
try |
|
198 |
{ |
|
199 |
DistortedLibrary.onCreate(mView.getContext()); |
|
200 |
} |
|
201 |
catch(Exception ex) |
|
202 |
{ |
|
203 |
android.util.Log.e("MovingGlow", ex.getMessage() ); |
|
204 |
} |
|
197 |
DistortedLibrary.onCreate(mView.getContext(), this); |
|
205 | 198 |
} |
199 |
|
|
200 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
|
201 |
|
|
202 |
public void distortedException(Exception ex) |
|
203 |
{ |
|
204 |
android.util.Log.e("MovingGlow", ex.getMessage() ); |
|
205 |
} |
|
206 | 206 |
} |
Also available in: Unified diff
Only compile the Full, Normal & OIT programs when they are actually needed.