How to RunScript in Headless Doc - Python
Hi, I’m trying to use RunScript in a headless doc. I can’t figure out why this doesn’t work I get this error Unknown Command: /Users/johanpedersen/Desktop/test.3dm doc = RhinoDoc.CreateHeadless(None)...
View ArticleLaunch a script stored in my phone?
I do want to launch a Rhino script that I do stored in my phone and I can see-it from Windows Explorer, I copied the path to clipboard and created a button in Rhino to launch the script using that...
View ArticleZebra Stripes in Grasshopper with C#
Hello, I’m trying to make a quick C# component that does a Zebra Stripes preview of a brep. Nothing I do with DisplayPipeline or DrawZebraPreview works at all. Surely it should be something like:...
View ArticlePlug-in creation tutorial?
I have a couple of dozen Python scripts that I currently hand out to a small group of colleagues, and I thought it’s probably time that I put them together into a plug-in… I have avoided this in the...
View ArticleRotate Text in Python
Hi All, I’m trying to write a function that inserts text on a drawing, with an optional rotation value. The problem is that there doesn’t seem to be an argument for rotation in the ‘AddText’ method,...
View ArticleBug in Common? Project curve to plane adds points
Hi guys, please take a look at this. I am altering curve editpoints and need to make a 2d version of the curve and then locate that versions editpoints, but if I coerce the curve (some curves only!)...
View ArticleAdd multiple objects from python to Rhino in one step?
Hi In Rhino8 Script Editor python 3: from an excel file : I’m reading point coordinates, creating vertices, creating triangular surfaces. I have around 30,000 triangles...
View ArticleTextEntity.Style has no effect?
Hi All, I’m trying to add some text to a document, and specify a text style upon creation, but for some reason, the style doesn’t seem to have any effect. Here’s my code: def InsertText( doc, Layer:...
View ArticlePython 3 Loading DLL File
Hi everyone, I am trying to load dll file using python3 in Grasshopper, and not sure why it is not regconized. File name and directory are both correct. Can anyone help me to look at this issue?...
View ArticlePlacing text onto pageview (layout) from Python
I am having a hard time navigating the nuances between viewports and pageviews. It seems that I cannot genereate text onto a layout unless it is the active view port. Is that the case ? I have been...
View ArticleETO TabControl Click event not registering
Hi all, I am trying to use a nonmodal dialog with tabcontrols in cpython Rhino 8. So far so good, but I would like tot use the forms.TabPage Click event. For some reason the event it is not...
View ArticleDo ETO forms work in Python?
Eto forms and Python: Does it work? 7 posts - 3 participants Read full topic
View ArticleOrientation and normal direction of BREPs
Hi! So I started scripting a couple of months back now with a class about computational architecture and python scripting, our latest assignment consists of making a script to do half-lap joints on...
View ArticleNormal vector on a closed polysurface
Using python, what is the best way of getting the normal vector of a closed polysurface on a specific point (on that polysurface)? Rhinoscriptsyntax has SurfaceNormal but it doesn’t work on...
View ArticleGrasshopper Debugging Python in VSCode
I just got into Rhino and Grasshopper for some Python programming work. I created the following “environment” (what’s the proper term here?): Which uses this Python 3 script: import os from random...
View ArticlePickling Rhino Geometry Objects Fails In Python 3 (Works in IronPython)
I have created my own classes, that contain Rhino geometries as attributes (mostly points, lines, NurbsCurves). I then perform many operations such as offsets, trims and joins. Objects rely on...
View ArticleBetter approach / faster processing for point inside solid
Hi there! Long time lurker, first time posting. I currently have a IronPython script in Rhino that given a CSV file which includes three columns of XYZ coordinates along with other data, it checks...
View ArticleRhinoscript ProgressMeter not updating in Rhino 8.7.24113.23001
When running the following python script in Rhino 7 I can see the progress bar update but not In Rhino 8? Can anyone confirm? import rhinoscriptsyntax as rs rs.StatusBarProgressMeterShow("Progress",...
View ArticleGetBoundingBox() plane-oriented but world coordinates
Two overloads here: If I just use obj.GetBoundingBox(plane), it uses the second overload, and I get the box output in plane coordinates. I would like the first, the plane-oriented bounding box, but in...
View ArticleHow to... rounded rectangle?
What would be the simplest way in constrcucting accurate rounded rectangle using ghpython? I have this as the base (C# Rectangle3d (rounded) - Grasshopper) , what I modified from @PeterFotiadis. I...
View Article