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

Nonmanifold Merge - python scripting?

I’m trying to access the NonmanifoldMerge command in Rhinocommon or python, but can’t seem find any reference to it anywhere. The goal is to be able to use it on polysurfaces in a model (>130k...

View Article


Need help with getobjects custom_filter

I need to create a script where getobject can only select the closed curve to define the plane, and surface to define the plane. I have created a filter using custom_filter, but if it works...

View Article


Image may be NSFW.
Clik here to view.

Calculate the angle between adjacent line segments of a space mesh shell

I would like to ask for advice, I would like to calculate the angle of adjacent line segments of a space mesh shell, how do I do it? Is there any way to is to realize it? A.3dm (118.4 KB) 5 posts - 2...

View Article

Obtain objref for Rhino.Geometry.Brep?

If I have a rhino.geometry.brep stored in the memory in a python script, is there a way to access the object reference (Rhino.DocObjects.ObjRef)? Sc.doc.objects.Find, coerceobject or adding it to the...

View Article

Panel(Layers, properties, etc.) locations with Python

Hi all, Is there a way to get and set the location and extends of the panels(Layers, properties, named views, etc.) on screen through Python? The reason being is that I find myself moving them around...

View Article


Keyboard event handling

Hello, I want to make a script that continuously redraws objects based on parameters provided via a dialog box. I currently have this function which is showing the dialog box, collecting the...

View Article

Modifying the geometry of an object and maintain all other information

Hi, I’m trying to modify the underlying geometry of a referenced Rhino Geometry. In this case a polyline, where I want the points of the polyline to move to new location. I want to keep this simple,...

View Article

Bounding box

Buona sera a tutti, sono un autodidatta e sto iniziando solo ora a scrivere qualche macro che mi automatizzi un lavoro ripetitivo. dopo aver caricato un modello,devo creare un bounding box e poi...

View Article


Image may be NSFW.
Clik here to view.

Error in rs Help for RotateObject()

The Help for rs.RotateObject() and rs.RotateObjects() is wrong, it indicates you can supply a plane for the rotation axis, when in fact it wants a vector. Feeding it a plane in this case errors out. I...

View Article


Image may be NSFW.
Clik here to view.

Off-axis rotation producing unexpected results

I’d appreciate any assistance with the following issue: Goal As can be observed by running the following script, my goal is to have the upper surface(A) rotated, with center of rotation at the center...

View Article

Shifting Path in C#

Hi all, I have a DataTree in C# Scripting component and would like to reduce its path, for instance, {a;b;c} into {a;b} - same as the “Shift Path” component in Grasshopper. Does anyone know how?...

View Article

Rhino python how to get relative path of installation on both win&mac?

I would like to import 3rd party dll to rhino python and distribute plugin to others, how could I guarantee that the dll imported correctly on every user I send to? My attempt is write a bat file that...

View Article

Differences in GH c# Mac and Windows expression-bodied property

Hey guys i was wondering if I’m missing something here and also out of curiosity. I’m often switching between mac and windows. I’m currently working on a c# class. I stared on Mac and used this...

View Article


Rhino python how to get relative path of installation on both win&mac?

I would like to import 3rd party dll to rhino python and distribute plugin to others, how could I guarantee that the dll imported correctly on every user I send to? My attempt is write a bat file that...

View Article

Prevent UI from freezing during long running Python script - Windows

I was about to post this earlier today but found the solution some time later, so consider this a little public service announcement: Is there any way from preventing Rhino’s UI from locking up and...

View Article


Rhino viewport rotate/pan/zoom event in Grasshopper

Hi I got an eventlistener to work (based on other threads in here) that check if the active viewport is changed or modified: private void RunScript(ref object A) { A = "Test"; } // <Custom...

View Article

STEP import script: Object Name from filename

Hi everybody, ~Long time rhino user, first time scripter~ I am trying to find a python script to assign object names based on the filename of the .step file to be imported. Looks like there are plenty...

View Article


Image may be NSFW.
Clik here to view.

Texture Mapping out Geometry

hi i created script c# for set XYZ Size of Texture Material(and we can bake that object with Material in Rhino by siz) but output for bake only== Mesh ! and i need bake it for example Brep Surface...

View Article

Assigning Display Colors to Surfaces Based on a List of Numbers

Hello everyone, I’m currently working on a Grasshopper project where I have two lists of equal length. One list consists of numbers, such as [0, 1, 1, 2, 0, 1, 1, 3, 0, 1, 1, 0], and the other list...

View Article

Image may be NSFW.
Clik here to view.

Remote Sender/Receiver using GHPython

Hi All, just out of interest, can we build a remote component as such using basic Gh python? 1 post - 1 participant Read full topic

View Article
Browsing all 5938 articles
Browse latest View live