Revision 0e80d8a9
Added by Leszek Koltunski over 4 years ago
src/main/java/org/distorted/examples/meshjoin/MeshJoinRenderer.java | ||
---|---|---|
88 | 88 |
|
89 | 89 |
mSinkAssociation = 0; |
90 | 90 |
mSink = new VertexEffectSink( sink, center, new Static4D(0,0,0,0.75f) ); |
91 |
mSink.setMeshAssociation(mSinkAssociation); |
|
91 |
mSink.setMeshAssociation(-1,mSinkAssociation);
|
|
92 | 92 |
|
93 | 93 |
mEffects = new DistortedEffects(); |
94 | 94 |
mEffects.apply( new MatrixEffectQuaternion(quatInt2, center) ); |
... | ... | |
151 | 151 |
if( checked ) mSinkAssociation |= n; |
152 | 152 |
else mSinkAssociation &= (15-n); |
153 | 153 |
|
154 |
mSink.setMeshAssociation(mSinkAssociation); |
|
154 |
mSink.setMeshAssociation(-1,mSinkAssociation);
|
|
155 | 155 |
} |
156 | 156 |
|
157 | 157 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
... | ... | |
267 | 267 |
VertexEffectDeform effect10= new VertexEffectDeform(dVec2, dRad, dCen2, dReg); |
268 | 268 |
VertexEffectDeform effect11= new VertexEffectDeform(dVec3, dRad, dCen3, dReg); |
269 | 269 |
|
270 |
effect4.setMeshAssociation(14); // apply to mesh[1], [2] and [3] |
|
271 |
effect5.setMeshAssociation( 2); // apply only to mesh[1] |
|
272 |
effect6.setMeshAssociation( 4); // apply only to mesh[2] |
|
273 |
effect7.setMeshAssociation( 8); // apply only to mesh[3] |
|
270 |
effect4.setMeshAssociation(-1,14); // apply to mesh[1], [2] and [3]
|
|
271 |
effect5.setMeshAssociation(-1, 2); // apply only to mesh[1]
|
|
272 |
effect6.setMeshAssociation(-1, 4); // apply only to mesh[2]
|
|
273 |
effect7.setMeshAssociation(-1, 8); // apply only to mesh[3]
|
|
274 | 274 |
|
275 | 275 |
result.apply(effect1); |
276 | 276 |
result.apply(effect2); |
Also available in: Unified diff
Progress making it possible to apply Vertex Effects only to some Components of a Mesh.