private void createLineLine4ViewsAnimation(Alpha a) {
TransparencyAttributes ta = new TransparencyAttributes();
ta.setCapability(TransparencyAttributes.ALLOW_VALUE_WRITE);
ta.setCapability(TransparencyAttributes.ALLOW_VALUE_READ);
ta.setCapability(TransparencyAttributes.ALLOW_BLEND_FUNCTION_READ);
ta.setCapability(TransparencyAttributes.ALLOW_BLEND_FUNCTION_WRITE);
ta.setTransparencyMode(TransparencyAttributes.NICEST);
Appearance appearance = getToothCopyPosObjects(getVisibleTooth(n)).getToothCopyAppearance(n, JawsConst.MESIAL);
appearance.setTransparencyAttributes(ta);
for (Appearance app : getToothCopyPosObjects(getVisibleTooth(n)).getToothCopyAllAppearance(n)) {
app.setTransparencyAttributes(ta);
TransparencyInterpolator ti = null;
if (jawsMode == JawsConst.LINE) {
ti = new TransparencyInterpolator(a, ta, 1.0f, 0);
}
if (jawsMode == JawsConst.LINE4VIEWS) {
ti = new TransparencyInterpolator(a, ta, 0, 1.0f);
}
ti.setSchedulingBounds(new BoundingSphere(new Point3d(0, 0, 0), 10000.0));
animation.addChild(ti);
public Appearance getToothCopyAppearance(int toothPos, int surface) {
ToothSurface toothSurface = new ToothSurface(toothPos, surface);
List<Shape3D> shapes = ToothHashManager.getShape3D(toothSurface);
if (shapes != null && shapes.size() >= 2) {
return shapes.get(1).getAppearance();
} else {
return null;
}
}
}