Revision 306aa049
Added by Leszek Koltunski over 2 years ago
src/main/java/org/distorted/bandaged/BandagedPlayRenderer.java | ||
---|---|---|
18 | 18 |
import org.distorted.library.main.DistortedScreen; |
19 | 19 |
import org.distorted.library.mesh.MeshBase; |
20 | 20 |
import org.distorted.objectlib.effects.BaseEffect; |
21 |
import org.distorted.objectlib.scrambling.ScrambleStateBandagedCuboid; |
|
21 | 22 |
|
22 | 23 |
import javax.microedition.khronos.egl.EGLConfig; |
23 | 24 |
import javax.microedition.khronos.opengles.GL10; |
... | ... | |
64 | 65 |
@Override |
65 | 66 |
public void onSurfaceCreated(GL10 glUnused, EGLConfig config) |
66 | 67 |
{ |
68 |
int maxS = ScrambleStateBandagedCuboid.MAX_SUPPORTED_SIZE; |
|
69 |
int numComponents = maxS*maxS*maxS - (maxS-2)*(maxS-2)*(maxS-2); |
|
70 |
|
|
67 | 71 |
DistortedLibrary.setMax(EffectType.VERTEX,25); // 24 quaternions + rotation |
68 |
MeshBase.setMaxEffComponents(98); // max 5^3-3^3 moving parts
|
|
72 |
MeshBase.setMaxEffComponents(numComponents);
|
|
69 | 73 |
VertexEffectRotate.enable(); |
70 | 74 |
VertexEffectQuaternion.enable(); |
71 | 75 |
BaseEffect.Type.enableEffects(); |
Also available in: Unified diff
Make the bandaged cuboids work up to any size.