Quantcast
Channel: Scripting - McNeel Forum
Browsing all 5793 articles
Browse latest View live

Sprintf Equivalent

Hello, I finally took a deep dive into RhinoScript. I am slowly finding my way after looking at sample scripts. However, I am having a bit of trouble formatting a string, which in turn writes to a...

View Article


Image may be NSFW.
Clik here to view.

Compiler python

I tried the compiler with one of my python script… It’s really nice!!! So I created an *.rhp, I dropped it in rhino, and it run, but I put in this script a rs.enableredraw( false). And when I quit the...

View Article


Como juntar dois ou mais Scripts

Olá pessoal, gostaria de saber como eu poderia juntar dois ou mais scipts para que rodassem um após o outro, sendo que entre cada intervalo eu adicionaria uma informação. 2 posts - 2 participants Read...

View Article

How to extract CurveStartPoint or CurveEndPoint in CPlane Coordinate System?

Hello, I am completely new to Rhino Python. I wish to extract coordinates in CPlane system of start and end points of a Curve. But the CurveStartPoint and CurveEndPoint functions spit out in World...

View Article

Anotation Style Creation in Version 7

I am trying to create an annotation style. From looking at the examples I came up with this: //Create the style and return the index. Don't save with the file. int dsi =...

View Article


Brep.Trim() failure

Hi , Can someone please let me know why this minimal-example trim is not returning a trimmed brep? The surfaces are coplanar, and the smaller cutter resides within the larger surface to be cut. (There...

View Article

Rhino Crashing on trying to load a new image through Python Script

Hi im Jordan, I’m still somewhat new to coding so I would be very grateful for some help. I am trying to set up a UI window that displays an image that is corresponding to a selection in a ListBox. I...

View Article

Rhino7 GHPython Runtime Error: Unable to add line

I’m new to GHPython and getting the following error: Runtime error (PythonException): Unable to add line to document Traceback: line 482, in AddLine,...

View Article


Convert planar surface to solid hatch while retaining display colour

Hi, I’d like some pointers on how to convert large numbers of planar surfaces into hatches, while retaining the surfaces properties such as display colour etc of each surface/hatch. I need to do this...

View Article


ExportwithOrigin in RhinoScriptSyntax (Python)

How would I script ExportwithOrigin in rhinoscriptsyntax Command()? This won’t work: rs.Command('-_ExportWithOrigin (1,2,3) "c:/folder/filename.3dm" _EnterEnd') What am I doing wrong? Thanks all. 2...

View Article

Image may be NSFW.
Clik here to view.

Help understanding rs.Angle result between two points with plane provided

I think I am doing a straightforward angle calculation between two points which are -90 degrees apart on a plane, but I am getting -45 degrees from the rs.Angle result. I’m guessing there is something...

View Article

Image may be NSFW.
Clik here to view.

Rhino 7; SplitMeshWithCurve issue

Hello, I’m in the process of converting Rhino 5 scripts into Rhino 7 scripts, and I got weird results using SplitMeshWithCurve function. Here is the mesh I’m tring to split, with the splitting curve:...

View Article

Convert Non-planer Surfaces (or Ploy-surfaces looks like surface) to Planer ones

Hi, Is there a way to convert Non-planner Surfaces (or Ploy-surfaces looks like surface) to Planner ones? What I do is that I duplicate the edge of the surface and trim it from a planer surface after...

View Article


Quick covert the enclosed curve to planarSrf inside the block

I need to input dwg with lots of blocks in rhino. the block always consist of enclosed polyline, polyline and single line. is it possible to convert the enclosed polyline to plannar surface quickly? 1...

View Article

Image may be NSFW.
Clik here to view.

How to extract "Visible Index" in RhinoCommon HiddenLineDrawingSegments

Hi Does anyone know how to extract the "Visible Index " for each visible curve like the Make2D component , this for further branching retrieving in the “flatten” Make2DFlatten scripted make2D...

View Article


Image may be NSFW.
Clik here to view.

Sort Points by x or y in C#

Hello all! I am just beginning to learn the very basics of C#. I made an arbitrary curve and placed points on it at regular intervals, now I would like to sort these points and connect them with a...

View Article

Finding point coordinates / location

My code (“obj” is a valid Guid): bb = rs.BoundingBox(obj) result = rs.PointDivide(rs.PointAdd(bb[6], bb[0]), 2.0) According to the documentation this returns a point. rs.IsPoint(result) returns False...

View Article


Question about using DrRacket as a front end and Rhino as a backend with the...

Hello there, To Whom It May Concern: I am working along with a book titled “Programming for Architects”, it uses DrRacket as a frontend and Rhino or AutoCAD as a backend, right now I am on section 3.3...

View Article

How to get bottom surface of a closed extrusion geometry?

How can I get the bottom surface of a selected geometry? Thank you 4 posts - 3 participants Read full topic

View Article

How to create pipe using grasshopper python(tree growth truck thickness)

Hi all, I am trying to add thickness to the tree growth script i just developed, however I cannot figure out how to create a thickness(pipe) around the lines I created, I tried with the...

View Article
Browsing all 5793 articles
Browse latest View live