Java examples for javax.media.j3d:Transform3D
output Java 3D Transform
import java.math.BigDecimal; import java.math.RoundingMode; import java.util.Enumeration; import javax.media.j3d.Appearance; import javax.media.j3d.BoundingSphere; import javax.media.j3d.BranchGroup; import javax.media.j3d.Material; import javax.media.j3d.Node; import javax.media.j3d.PolygonAttributes; import javax.media.j3d.Shape3D; import javax.media.j3d.Transform3D; import javax.media.j3d.TransformGroup; import javax.vecmath.Color3f; import javax.vecmath.Point3d; import javax.vecmath.Point3f; import javax.vecmath.Quat4f; import javax.vecmath.Vector3f; public class Main{ public static String outputTransform(Transform3D t2) { if (t2 != null) { Vector3f v2 = new Vector3f(); t2.get(v2);/*from w w w . j av a 2 s .com*/ return "Transform " + outputTrans(t2) + " :: " + outputRot(t2); } else { return "null"; } } public static String outputTrans(Transform3D t2) { if (t2 != null) { Vector3f v2 = new Vector3f(); t2.get(v2); return "Trans:" + v2; } else { return "null"; } } public static String outputRot(Transform3D t2) { if (t2 != null) { Quat4f v2 = new Quat4f(); t2.get(v2); return "Quat:" + v2; } else { return "null"; } } }