cylinder transparency
Posted: Thu 12. Aug 2010, 17:18
Hello,
i'm creating a closed clinder with this code:
The problem is that the cylinder is not transparent. What i'm doing wrong?
Is it possible to set certain coordinates for the central point of the cylinder and then to translate the cylinder by changing the center position?
i'm creating a closed clinder with this code:
Code: Select all
SceneGraphComponent stu = Primitives.closedCylinder(10, 5, 10, 10 , Math.PI*2);
SceneGraphComponent sgc = SceneGraphUtility.createFullSceneGraphComponent();
Appearance appearance = sgc.getAppearance();
DefaultGeometryShader dgs = ShaderUtility.createDefaultGeometryShader(appearance, false);
dgs.setShowPoints(false);
dgs.setShowLines(false);
dgs.setShowFaces(true);
DefaultPolygonShader dps = (DefaultPolygonShader) dgs.createPolygonShader("default");
dps.setDiffuseColor(Color.RED);
dps.setTransparency(0.5);
Is it possible to set certain coordinates for the central point of the cylinder and then to translate the cylinder by changing the center position?