/// <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) { // INPUT // declaration Mesh _terrain = null; DA.GetData(0, ref _terrain); // start df_envimet_lib.Geometry.Material material = new df_envimet_lib.Geometry.Material(); df_envimet_lib.Geometry.Terrain envimetTerrain = new df_envimet_lib.Geometry.Terrain(_terrain, material); // OUTPUT DA.SetData(0, envimetTerrain); DA.SetData(1, envimetTerrain.GetMesh()); }
/// <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) { // INPUT // declaration Mesh _plant2D = null; string _plantId_ = df_envimet_lib.Geometry.Material.CommonPlant2dMaterial; DA.GetData <Mesh>(0, ref _plant2D); DA.GetData <string>(1, ref _plantId_); // actions df_envimet_lib.Geometry.Material material = new df_envimet_lib.Geometry.Material { Custom2dMaterial = _plantId_ }; df_envimet_lib.Geometry.Plant2d trees = new df_envimet_lib.Geometry.Plant2d(_plant2D, material); // OUTPUT DA.SetData(0, trees); }
/// <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) { // INPUT // declaration Mesh _source = null; string _sourceId_ = df_envimet_lib.Geometry.Material.CommonSourceMaterial; DA.GetData <Mesh>(0, ref _source); DA.GetData <string>(1, ref _sourceId_); // actions df_envimet_lib.Geometry.Material material = new df_envimet_lib.Geometry.Material { Custom2dMaterial = _sourceId_ }; df_envimet_lib.Geometry.Source sources = new df_envimet_lib.Geometry.Source(_source, material); // OUTPUT DA.SetData(0, sources); }
/// <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) { // INPUT // declaration Mesh _horizontalPlanarSurface = null; string _singleWallId_ = df_envimet_lib.Geometry.Material.CommonSimpleWall; DA.GetData <Mesh>(0, ref _horizontalPlanarSurface); DA.GetData <string>(1, ref _singleWallId_); // actions df_envimet_lib.Geometry.Material material = new df_envimet_lib.Geometry.Material { CustomSimpleWallMaterial = _singleWallId_ }; df_envimet_lib.Geometry.SimpleWall shadings = new df_envimet_lib.Geometry.SimpleWall(_horizontalPlanarSurface, material); // OUTPUT DA.SetData(0, shadings); }
/// <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) { // INPUT // declaration Mesh _plant3D = null; string _plant3Did_ = df_envimet_lib.Geometry.Material.CommonPlant3dMaterial; DA.GetData <Mesh>(0, ref _plant3D); DA.GetData <string>(1, ref _plant3Did_); // actions df_envimet_lib.Geometry.Material material = new df_envimet_lib.Geometry.Material { Plant3dMaterial = _plant3Did_ }; df_envimet_lib.Geometry.Plant3d trees = new df_envimet_lib.Geometry.Plant3d(material, _plant3D); // OUTPUT DA.SetData(0, trees); trees.Dispose(); }