# Brep offset C#

**URL:** <https://discourse.mcneel.com/t/brep-offset-c/53980>\
**Category:** Rhino Developer\
**Created:** [January 26, 2018, 8:20pm UTC](https://discourse.mcneel.com/t/brep-offset-c/53980 "2018-01-26T20:20:11Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Petras\_Vestartas](https://sea3.discourse-cdn.com/mcneel/user_avatar/discourse.mcneel.com/petras_vestartas/32/480531_2.png) [@Petras\_Vestartas](https://discourse.mcneel.com/u/Petras_Vestartas)\
**Post date:** [January 26, 2018, 8:20pm UTC](https://discourse.mcneel.com/t/brep-offset-c/53980/1 "2018-01-26T20:20:11Z")

</div>

Hi,

I would like to ask if it is a bug for Brep.Offset method or I am doing something wrong?  
I am running Brep.Offset method from C# custom component in grasshopper and I get this type of offset for some of values.

` Brep offset = Brep.CreateOffsetBrep(x, y, true, true, Rhino.RhinoDoc.ActiveDoc.ModelAbsoluteTolerance, out blends, out walls);

Shape is quite simple:

 ![o2](https://global.discourse-cdn.com/mcneel/uploads/default/original/3X/0/d/0d12d7bed23c53b51cfc9ffec0e5923c95a93eb0.jpg)  
 ![o1](https://global.discourse-cdn.com/mcneel/uploads/default/original/3X/c/3/c3ac110df3a1b927d555c8d00b5c75a053cdc7d9.jpg)  
 ![Canvas at 21;19;31](https://global.discourse-cdn.com/mcneel/uploads/default/original/3X/a/6/a6fe4c5ae49d56fcaf61df52823e96304b557d1e.png)  
[BrepOffset.gh](https://global.discourse-cdn.com/mcneel/uploads/default/original/3X/b/7/b7501cc0e01677603b31680a3ee01170bd065de6.gh) (13.2 KB)

---

<div class="post-metadata">

**Author:** ![dale](https://sea3.discourse-cdn.com/mcneel/user_avatar/discourse.mcneel.com/dale/32/685184_2.png) [@dale](https://discourse.mcneel.com/u/dale)\
**Post date:** [January 30, 2018, 11:09pm UTC](https://discourse.mcneel.com/t/brep-offset-c/53980/2 "2018-01-30T23:09:42Z")

</div>

Hi @Petras_Vestartas,

I’ve reported this.

[https://mcneel.myjetbrains.com/youtrack/issue/RH-43874](https://mcneel.myjetbrains.com/youtrack/issue/RH-43874)

– Dale

---

<div class="post-metadata">

**Author:** ![architect.civil5](https://sea3.discourse-cdn.com/mcneel/user_avatar/discourse.mcneel.com/architect.civil5/32/500786_2.png) [@architect.civil5](https://discourse.mcneel.com/u/architect.civil5)\
**Post date:** [August 7, 2019, 8:12am UTC](https://discourse.mcneel.com/t/brep-offset-c/53980/3 "2019-08-07T08:12:07Z")

</div>

hi i need add (bothside side) and( solid ) and (corner)option to this code please help me thanks  
 ![673](https://global.discourse-cdn.com/mcneel/uploads/default/original/3X/f/7/f74d0f7297631d5e49828824c4b95995cc601a68.jpeg)

---

<div class="post-metadata">

**Author:** ![dale](https://sea3.discourse-cdn.com/mcneel/user_avatar/discourse.mcneel.com/dale/32/685184_2.png) [@dale](https://discourse.mcneel.com/u/dale)\
**Post date:** [August 7, 2019, 3:31pm UTC](https://discourse.mcneel.com/t/brep-offset-c/53980/4 "2019-08-07T15:31:06Z")

</div>

Hi @architect.civil5,

[Brep.CreateOffsetBrep](https://developer.rhino3d.com/api/RhinoCommon/html/M_Rhino_Geometry_Brep_CreateOffsetBrep.htm) is the method to use. To Corners=Sharp/Round is controlled by the `extend` parameter. Note, the function does not have a `BothSides` options. To do this, just transform or offset the surface first.

– Dale
