Revision 513b2e9c
Added by Leszek Koltunski almost 4 years ago
src/main/java/org/distorted/examples/deform/DeformRenderer.java | ||
---|---|---|
36 | 36 |
|
37 | 37 |
import org.distorted.library.message.EffectListener; |
38 | 38 |
import org.distorted.library.type.Dynamic3D; |
39 |
import org.distorted.library.type.Static1D; |
|
39 | 40 |
import org.distorted.library.type.Static3D; |
40 | 41 |
import org.distorted.library.type.Static4D; |
41 | 42 |
|
... | ... | |
140 | 141 |
mScreen = new DistortedScreen(); |
141 | 142 |
mScreen.showFPS(); |
142 | 143 |
|
143 |
mMovingDistort = new VertexEffectDistort( movingDistortDynamic , mTouchPoint, mRegion); |
|
144 |
mMovingDeform = new VertexEffectDeform ( movingDeformDynamic , mTouchPoint, mRegion); |
|
145 |
mMovingShear = new MatrixEffectShear ( movingShearDynamic , mTouchPoint ); |
|
146 |
mReleasedDistort = new VertexEffectDistort( releasedDistortDynamic, mTouchPoint, mRegion); |
|
147 |
mReleasedDeform = new VertexEffectDeform ( releasedDeformDynamic , mTouchPoint, mRegion); |
|
148 |
mReleasedShear = new MatrixEffectShear ( releasedShearDynamic , mTouchPoint ); |
|
144 |
Static1D deformRadius = new Static1D(0.5f); |
|
145 |
|
|
146 |
mMovingDistort = new VertexEffectDistort( movingDistortDynamic , mTouchPoint, mRegion); |
|
147 |
mMovingDeform = new VertexEffectDeform ( movingDeformDynamic , deformRadius, mTouchPoint, mRegion); |
|
148 |
mMovingShear = new MatrixEffectShear ( movingShearDynamic , mTouchPoint ); |
|
149 |
mReleasedDistort = new VertexEffectDistort( releasedDistortDynamic, mTouchPoint, mRegion); |
|
150 |
mReleasedDeform = new VertexEffectDeform ( releasedDeformDynamic , deformRadius, mTouchPoint, mRegion); |
|
151 |
mReleasedShear = new MatrixEffectShear ( releasedShearDynamic , mTouchPoint ); |
|
149 | 152 |
} |
150 | 153 |
|
151 | 154 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
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.