Revision 2ed1c692
Added by Leszek Koltunski about 7 years ago
src/main/java/org/distorted/library/Distorted.java | ||
---|---|---|
105 | 105 |
throws FragmentCompilationException,VertexCompilationException,VertexUniformsException,FragmentUniformsException,LinkingException |
106 | 106 |
{ |
107 | 107 |
final Resources resources = context.getResources(); |
108 |
|
|
109 |
GLES30.glDepthFunc(GLES30.GL_LEQUAL); |
|
110 |
GLES30.glEnable(GLES30.GL_BLEND); |
|
111 |
GLES30.glBlendFunc(GLES30.GL_SRC_ALPHA, GLES30.GL_ONE_MINUS_SRC_ALPHA); |
|
112 |
GLES30.glEnable(GLES30.GL_CULL_FACE); |
|
113 |
GLES30.glCullFace(GLES30.GL_BACK); |
|
114 |
GLES30.glFrontFace(GLES30.GL_CW); |
|
115 |
|
|
116 | 108 |
DistortedEffects.createProgram(resources); |
117 | 109 |
EffectQueuePostprocess.createProgram(resources); |
118 |
|
|
119 | 110 |
EffectMessageSender.startSending(); |
120 | 111 |
|
121 | 112 |
mInitialized = true; |
Also available in: Unified diff
1) stop culling back face
2) reset OpenGL state beore each render (and not in onCreate)
3) Improve Matrix3D so that we can test negative Scales