private void Modifierdimension(object sender, RoutedEventArgs e) { //Formes.OfType<ArrowVisual3D>().First().Diameter = Taille; //Formes.OfType<BoxVisual3D>().First().Width = Taille; //Formes.OfType<BoxVisual3D>().First().Height = Taille; //Formes.OfType<BoxVisual3D>().First().Length = Taille; //Formes.OfType<CubeVisual3D>().First().SideLength = Taille; //Formes.OfType<EllipsoidVisual3D>().First().RadiusX = Taille; //Formes.OfType<EllipsoidVisual3D>().First().RadiusY = Taille; //Formes.OfType<EllipsoidVisual3D>().First().RadiusZ = Taille; //Formes.OfType<HelixVisual3D>().First().Diameter = Taille; //Formes.OfType<HelixVisual3D>().First().Turns = Taille; //Formes.OfType<HelixVisual3D>().First().Length = Taille; //Formes.OfType<HelixVisual3D>().First().Radius = Taille; //Formes.OfType<PieSliceVisual3D>().First().OuterRadius = Taille; //Formes.OfType<PieSliceVisual3D>().First().InnerRadius = Taille; //Formes.OfType<PipeVisual3D>().First().Diameter = Taille; //Formes.OfType<PipeVisual3D>().First().InnerDiameter = Taille; //Formes.OfType<RectangleVisual3D>().First().Width = Taille; //Formes.OfType<RectangleVisual3D>().First().Length = Taille; Formes.OfType <SphereVisual3D>().First().Radius = Taille; //Formes.OfType<TruncatedConeVisual3D>().First().Height = Taille; //Formes.OfType<TubeVisual3D>().First().Diameter = Taille; }
private void AjouterSphere(object sender, RoutedEventArgs e) { var sphere = new SphereVisual3D { Radius = i++ }; Formes.Add(sphere); }
static void Main(string[] args) { Formes dessin = new Formes(); }
private void SupprimerItem(object sender, RoutedEventArgs e) { Formes.Remove(Formes.Last()); }
private void AjouterItem(object sender, RoutedEventArgs e) { Formes.Add(GenererFormeAleatoire()); }
private void ResetSphere(object sender, RoutedEventArgs e) { Formes.Clear(); }
private void MoveSphere(object sender, RoutedEventArgs e) { Formes.Move(0, Formes.Count - 2); }
private void Modifierdimension(object sender, RoutedEventArgs e) { Formes.OfType <SphereVisual3D>().First().Radius = Aleatoire.Next(5, 20); }