public override void init() { cylinder = new Cylinder(new Vector3(0, 0, 0), 2, 4); sphere = new TgcBoundingSphere(new Vector3(0, 0, 0), 3); //cylinder.Transform = Matrix.Scaling(2, 1, 1); //cylinder.AutoTransformEnable = false; //cylinder.updateValues(); GuiController.Instance.Modifiers.addBoolean("boundingCylinder", "boundingCylinder", false); GuiController.Instance.Modifiers.addColor("color", Color.DarkGoldenrod); GuiController.Instance.Modifiers.addVertex2f("size", new Vector2(1, 1), new Vector2(5, 10), new Vector2(2, 5)); GuiController.Instance.Modifiers.addVertex3f("position", new Vector3(-20, -20, -20), new Vector3(20, 20, 20), new Vector3(0, 0, 0)); float angle = FastMath.TWO_PI; GuiController.Instance.Modifiers.addVertex3f("rotation", new Vector3(-angle, -angle, -angle), new Vector3(angle, angle, angle), new Vector3(0, 0, 0)); }
public override void init() { cylinder = new Cylinder(new Vector3(0, 0, 0), 2, 4); //cylinder.Transform = Matrix.Scaling(2, 1, 1); //cylinder.AutoTransformEnable = false; //cylinder.updateValues(); cylinder.AlphaBlendEnable = true; //cylinder.Effect = TgcShaders.loadEffect(GuiController.Instance.ExamplesMediaDir + "Shaders\\Ejemplo1.fx"); //cylinder.Technique = "RandomColorVS"; GuiController.Instance.Modifiers.addBoolean("boundingCylinder", "boundingCylinder", false); GuiController.Instance.Modifiers.addColor("color", Color.DarkGoldenrod); GuiController.Instance.Modifiers.addInt("alpha", 0, 255, 255); GuiController.Instance.Modifiers.addTexture("texture", GuiController.Instance.ExamplesMediaDir + "\\Texturas\\madera.jpg"); GuiController.Instance.Modifiers.addBoolean("useTexture", "useTexture", false); GuiController.Instance.Modifiers.addVertex2f("size", new Vector2(1, 1), new Vector2(5, 10), new Vector2(2, 5)); GuiController.Instance.Modifiers.addVertex3f("position", new Vector3(-20, -20, -20), new Vector3(20, 20, 20), new Vector3(0, 0, 0)); float angle = FastMath.TWO_PI; GuiController.Instance.Modifiers.addVertex3f("rotation", new Vector3(-angle, -angle, -angle), new Vector3(angle, angle, angle), new Vector3(0, 0, 0)); }