Grasshopper

algorithmic modeling for Rhino

Hi,

 

I am trying some simple exercises on vb.

If I code a circle it shows on Rhino but a rectangle doesn't.

 

My code is something like: 

Dim criarect As New Rectangle (0, 0, 10, 23)    rec = criarect

 

(rec is an output)

 

Why is it not displaying on rhino? 

I get the output x=0,y=0,Width=10,height=10 as an example, but the curve is not displayed.

 

 

Thank you.

 

Rhino 5 and Grasshopper 0.8.0007

Views: 337

Replies to This Discussion

You are actually creating a system.drawing.rectangle object. For the Rhinocommon object type:

Dim rect As New Rectangle3d(plane.WorldXY, 10, 23)

 

Nevertheless, if you connect the output (as a system.drawing.rectangle) to a rectangle parameter it converts it to a rhino rectangle.

Hey thanks a lot.It worked! :)

RSS

About

Translate

Search

Photos

  • Add Photos
  • View All

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service