/// <summary>
        /// This is the method that actually does the work.
        /// </summary>
        /// <param name="DA">The DA object is used to retrieve from inputs and store in outputs.</param>
        protected override void SolveInstance(IGH_DataAccess DA)
        {
            Plane  iBasePlane = Plane.WorldXY;
            double iLength    = double.NaN;
            double iWidth     = double.NaN;
            double iHeight    = double.NaN;

            DA.GetData("Base Plane", ref iBasePlane);
            DA.GetData("Length", ref iLength);
            DA.GetData("Width", ref iWidth);
            DA.GetData("Height", ref iHeight);

            Pyramid myPyramid = new Pyramid(iBasePlane, iLength, iWidth, iHeight);

            DA.SetDataList("Display Lines", myPyramid.ComputeDisplayLines());
        }
Exemple #2
0
        /// <summary>
        /// This is the method that actually does the work.
        /// </summary>
        /// <param name="DA">The DA object is used to retrieve from inputs and store in outputs.</param>
        protected override void SolveInstance(IGH_DataAccess DA)
        {
            Plane  iBasePlane = Plane.WorldXY;
            double iLength    = 1.0;
            double iWidth     = 1.0;
            double iHeight    = 1.0;
            double iNo        = 1;

            DA.GetData(0, ref iBasePlane);
            DA.GetData(1, ref iLength);
            DA.GetData(2, ref iWidth);
            DA.GetData(3, ref iHeight);
            DA.GetData(4, ref iNo);

            Pyramid          myPyramid    = new Pyramid(iBasePlane, iLength, iWidth, iHeight);
            List <LineCurve> displayLines = myPyramid.ComputeDisplayLines();

            DA.SetDataList("Display Lines", displayLines);
        }