Scale an Object - Rhino-grasshopper-scripting Typing CST Test
Loading…
Scale an Object — Rhino-grasshopper-scripting Code
Scales an object relative to a base point.
obj = rs.AddSphere(rs.AddPoint(0,0,0), 5)
base = rs.AddPoint(0,0,0)
rs.ScaleObject(obj, base, [2,2,2])Rhino-grasshopper-scripting Language Guide
Rhino is a 3D modeling software widely used in architecture, product design, and industrial design. Grasshopper is its visual programming environment that allows parametric and algorithmic design. Scripting in Rhino/Grasshopper enables automation, customization, and complex parametric workflows.
Primary Use Cases
- ▸Parametric architectural modeling
- ▸Automated repetitive design tasks
- ▸Generative and algorithmic design
- ▸Digital fabrication workflows (CNC, 3D printing)
- ▸Custom plugins or tools for design teams
Notable Features
- ▸Node-based parametric visual programming
- ▸Direct access to Rhino geometry through scripts
- ▸Supports Python, C#, and VB.NET scripting
- ▸Real-time model updates
- ▸Integration with external plugins and APIs
Origin & Creator
Rhino was developed by Robert McNeel & Associates in the 1990s. Grasshopper was introduced as a visual programming plugin in 2007 by David Rutten to enable parametric design workflows.
Industrial Note
Rhino/Grasshopper scripting is niche but essential in architecture, product design, computational geometry, digital fabrication, and generative design projects where parametric modeling and automation save significant time.
Quick Explain
- ▸Rhino provides precise NURBS-based 3D modeling.
- ▸Grasshopper allows node-based, visual programming for parametric models.
- ▸Scripting enables custom logic, automation, and integration.
- ▸Supports multiple scripting languages (Python, C#, VB.NET) within Rhino/Grasshopper.
- ▸Widely used in architecture, jewelry, product design, and digital fabrication.
Core Features
- ▸Geometry creation and manipulation (points, curves, surfaces, solids)
- ▸Data trees and parametric control in Grasshopper
- ▸Event-driven updates and triggers
- ▸Custom components and scripting in Grasshopper
- ▸Automation and batch processing via Rhino scripts
Learning Path
- ▸Learn Rhino basic modeling tools
- ▸Understand Grasshopper components and data trees
- ▸Explore Python or C# scripting in GH
- ▸Practice small parametric projects
- ▸Move to complex generative design tasks
Practical Examples
- ▸Generate parametric facade panels
- ▸Automate furniture design with variable dimensions
- ▸Procedural 3D patterns for jewelry
- ▸Optimize structural geometry using Kangaroo
- ▸Batch export multiple 3D files for fabrication
Comparisons
- ▸Grasshopper vs Dynamo: GH more flexible for freeform geometry; Dynamo better for Revit integration
- ▸RhinoScript vs Python: RhinoScript legacy, Python more modern and versatile
- ▸GH scripting vs direct Rhino modeling: scripting allows parametric control and automation
- ▸GH vs CatScript: GH professional parametric modeling, CatScript for playful learning
- ▸GH vs Processing: GH for CAD/fab, Processing for creative coding and visualization
Strengths
- ▸Highly flexible parametric modeling
- ▸Visual programming reduces coding barrier
- ▸Seamless integration with Rhino geometry engine
- ▸Supports complex generative and algorithmic designs
- ▸Strong community and plugin ecosystem
Limitations
- ▸Steep learning curve for scripting and data trees
- ▸Not suitable for large-scale computation without optimization
- ▸Grasshopper scripts can become complex and hard to debug
- ▸Single-threaded execution in many cases
- ▸Dependent on Rhino runtime environment
When NOT to Use
- ▸Real-time game engines
- ▸Heavy numerical simulations (use MATLAB/NumPy)
- ▸Large-scale BIM without Rhino.Inside
- ▸Non-parametric modeling tasks
- ▸Standalone applications outside Rhino ecosystem
Cheat Sheet
- ▸Sliders control numeric inputs
- ▸Panels display data
- ▸Graft/Flatten to manage data trees
- ▸Python/C# components manipulate geometry
- ▸Bake outputs to Rhino for final model
FAQ
- ▸Can I script in Python inside Grasshopper? -> Yes, using GhPython component.
- ▸Is Grasshopper free? -> Bundled with Rhino 6+.
- ▸Can I automate tasks in Rhino? -> Yes, via Python, C#, or RhinoScript.
- ▸Do I need programming knowledge? -> Helpful but visual programming reduces coding barrier.
- ▸Which plugins are recommended? -> Kangaroo, Weaverbird, LunchBox, Human UI.
30-Day Skill Plan
- ▸Week 1: Rhino modeling basics
- ▸Week 2: Grasshopper sliders and simple definitions
- ▸Week 3: Python scripting for geometry manipulation
- ▸Week 4: Data tree management and parametric logic
- ▸Week 5: Plugin usage and fabrication export
Final Summary
- ▸Rhino + Grasshopper scripting enables parametric and generative 3D modeling.
- ▸Supports Python, C#, and VB.NET for automation and customization.
- ▸Widely used in architecture, product design, and digital fabrication.
- ▸Visual programming simplifies complex parametric workflows.
- ▸Integration with plugins and fabrication tools expands design possibilities.
Project Structure
- ▸Base Rhino file (.3dm)
- ▸Grasshopper definition (.gh)
- ▸Scripts folder for Python/C# components
- ▸Assets folder for textures, CAD files
- ▸Documentation and notes for parametric logic
Monetization
- ▸Custom parametric design services
- ▸Generative design consulting
- ▸Digital fabrication workflows
- ▸Plugin and GH component development
- ▸Workshops and training for architecture studios
Productivity Tips
- ▸Use clusters to simplify GH canvas
- ▸Reuse scripts and components
- ▸Keep data trees organized
- ▸Test small subsets before full model
- ▸Leverage plugins for common geometry tasks
Basic Concepts
- ▸Rhino geometry: points, curves, surfaces, solids
- ▸Grasshopper components and wires
- ▸Data trees: hierarchical data structures
- ▸Parameters and sliders for controlling geometry
- ▸Scripting nodes to manipulate geometry programmatically