Revision 513b2e9c
Added by Leszek Koltunski almost 4 years ago
src/main/java/org/distorted/examples/triblur/TriblurRenderer.java | ||
---|---|---|
32 | 32 |
import org.distorted.library.effect.MatrixEffectScale; |
33 | 33 |
import org.distorted.library.effect.PostprocessEffectBlur; |
34 | 34 |
import org.distorted.library.effect.PostprocessEffectGlow; |
35 |
import org.distorted.library.effect.VertexEffectScale; |
|
35 | 36 |
import org.distorted.library.main.DistortedLibrary; |
36 | 37 |
import org.distorted.library.main.DistortedEffects; |
37 | 38 |
import org.distorted.library.main.DistortedNode; |
... | ... | |
110 | 111 |
mScale2 = new Static3D(1.5f,1.5f,1.5f); |
111 | 112 |
Static3D center = new Static3D(0,0,0); |
112 | 113 |
|
114 |
// VertexEffectScale scaleEffectV = new VertexEffectScale(OBJ_SIZE); |
|
113 | 115 |
MatrixEffectScale scaleEffect1 = new MatrixEffectScale(mScale1); |
114 | 116 |
MatrixEffectScale scaleEffect2 = new MatrixEffectScale(mScale2); |
115 | 117 |
MatrixEffectQuaternion quatEffect1 = new MatrixEffectQuaternion(mQuat1, center); |
... | ... | |
126 | 128 |
effects[i] = new DistortedEffects(); |
127 | 129 |
effects[i].apply(mBlur[i]); |
128 | 130 |
effects[i].apply(chroma[i]); |
129 |
|
|
131 |
// effects[i].apply(scaleEffectV); |
|
130 | 132 |
effects[i].apply(new MatrixEffectMove(moveVector[i])); |
131 | 133 |
effects[i].apply(quatEffect2); |
132 | 134 |
effects[i].apply(quatEffect1); |
... | ... | |
193 | 195 |
|
194 | 196 |
mTex.setTexture(bitmap); |
195 | 197 |
|
198 |
VertexEffectScale.enable(); |
|
196 | 199 |
PostprocessEffectBlur.enable(); |
197 | 200 |
FragmentEffectChroma.enable(); |
198 | 201 |
|
Also available in: Unified diff
A lot of changes.
1) main vertex shader: remove support for degree_object. This functionality will hopefully come back when we introduce other than circular regions.
2) MeshBase: remove the need to set a Bounding box (this is the point of the whole thing - we wanted to get rid of this so that the advances in MeshJoined will be easier)
3) Set ground for removing the MeshBase.setStretch / getStretch (another thing needed to advance MeshJoined )
4) since we removed the Bounding box, we need to change the DEFORN effect to have 1 additional parameter, the 'radius' which takes over the function of the bounding box in the vertex shader.
5) since the'res no bounding box, simplify the postprocessing Halo (remove EffectQueueMatrix.magnify() )
6) adjust applications.
After this we will hopefully be ready to introduce MeshBase.preApply(VertexEffect), i.e. bending several simple Meshes with any VertexEffect - including the freshly-introduced PseudoMatrix-Vertex effects like VertexEffectScale - and then combining them into one MeshJoined.