Prototype: SectionPlane (ClippingPlane Enhancements)

Hi all,

I wanted to share with you a new set of test commands that is meant to enhance the ClippingPlane functionality. This work is still under development and there are many parts still missing. Your feedback is essential to iron out the workflow and functionality and to make it useful in the context of your work. Please give it a try and let us know your thoughts.

I apologize for a lengthy post, but I thought it is best to put all the information in one place.

Notes:

  • Please test with the V6 build 9/9 or later.
  • All of the commands are test commands, which means that you will have to type the whole command name in full in order to run it (no auto complete).

This is what the new set of commands support:

  1. Improved UI to create one or array of section plane(s).
  2. Use the section plane(s) to clip, align the view and align to the active construction plane.
  3. Extract sections for a selected set of objects. Extracted geometry include curves, caps and hatches. Attributes can be set per-sectioned objects or current layer.
  4. Extract slices with thickness set by the user.
  5. The ability to clear (un-clip) section plane(s) from one or all views with option to delete extracted sections and slices.
  6. Edit extracted sections and their options.
  7. Edit extracted slices and their options.
  8. Provide and elementary way to set layers’ hatch data.
  9. Blocks are supported and should section properly.
  10. Extracted sections update when dragging and transforming the clip section(s).

Still to come:

  1. Section plane(s) properties.
  2. A way to generate the layout and nest extracted sections. (orient to XY-Plane or align in Layouts).
  3. SectionPlaneArray enhancements: Load array of distances (for the SectionPlaneArray) from file. Support other ways to create arrays (along curves for example)
  4. Create summary reports of extracted sections.
  5. Figure out the workflow to view and edit extracted sections in Layout and Details.
  6. Add support to “Positive/Solid” vs “Negative/Void” objects.
  7. Sections manager. Allow access to sections properties without having to select the corresponding section plane(s) on the model.
  8. Create extrusion slices when the object to slice is extrusion object, and the normal direction of the section plane is parallel to extrusion direction.

Here is what will NOT supported soon:

  1. Per object clipping. You can extract per-object geometry, but right now all geometry is clipped in display. This feature might not be coming within the V6 timeframe.
  2. Hatch, linetype & line thickness as an object property for surfaces & polysurfaces. Also linetype and line-thickness for surfaces. There is however a workaround to set layers’ hatch properties that is explained below.
  3. Linetype and line-thickness is also set per-layer for now. Jagged or non-planar clipping planes. This feature is not implemented yet.
  4. History does not automatically update when changing object attributes in V6 therefore changing object color for example, does not update the color of extracted sections unless call “HistoryUpdate” or move the SectionPlane.

The Commands:

1) SectionPlane
Creates a clipping plane and option to clip one or all views

Command Flow:
1- Run SectionPlane command.
2- First and second points.
3- Visible-side point.
4- Optional: select view(s) to clip.

Options:
1- 3Points: set the SectionPlane so it goes through 3 points. This helps define a plane in any direction using 3 points.
2- Clip: option to clip one or more views. Clip=No will create the clipping plane, but does not clip any view. There is a command to clip or orient to view below.
3- Name: assign name to the SectionPlane.
4- If “Clip”, there is “All” option to clip all views.

2) SectionPlaneArray
Creates an array of clipping planes.

Command Flow:
1- Run SectionPlaneArray command.
2- First and second points.
3- Visible-side point.
4- Optional new placement point.

Option:
1- 3Points: set the initial SectionPlane so it goes through 3 points.
2- Name: assign name to SectionPlanes.
3- Group: To group all SectionPlanes.
4- Number: number of SectionPlanes.
5- Distance: distance between SectionPlanes.
6- BothSides: create SectionPlanes on both sides.
6- Flip: flip the visible side of the SectionPlanes.

3) ViewSections
Clip, set view and set construction plane to any given SectionPlanes (or ClippingPlanes).

Command Flow:
1- Run ViewSections command.
2- Select SectionPlanes.
3- Select a Viewport.

Option:
1- Clip: clip the view.
2- SetView: align the view to the SectionPlane.
3- SetCPlane: Align the construction plane to SectionPlane.

4) SetLayerHatchData
Set the hatch pattern, rotation and scale for the specified layer. This information is added to the layer as a UserData.

Command Flow:
1- Run SetLayerHatchData command.
2- Set option.

Option:
1- Layer: set the layer by name.
2- Pattern: hatch pattern.
3- Rotation: hatch rotation.
4- Scale: hatch scale.

5) ExtractSections
Extract curves, caps and hatches of the SectionPlanes and specified objects.

Command Flow:
1- Run ExtractSections command.
2- Select SectionPlanes (or ClippingPlanes).
3- Select objects. Press Enter to select all visible objects.

Option:
1- Crvs: extract intersecting curves.
2- Caps: extract caps when the sectioned object is solid.
3- Hatches: extract hatches per layer (need to set layer hatch pattern using SetLayerHatchData command).
4- Attributes: either by clipped object or by current layer.

6) ExtractSlices
Extract slices from specified objects.

Command Flow:
1- Run ExtractSlices command.
2- Select SectionPlane(s)
3- Select objects. Press Enter to select all visible objects.

Option:
1- Thickness: slice thickness.
2- Attributes: either by clipped object or by current layer.

7) ClearSections
Unclips viewports for the selected ClippingPlanes with an option to delete extracted sections, if any.

Command Flow:
1- Run ClearSections command.
2- Select ClippingPlanes.
3- Select a Viewport. press Enter if none

Option:
1- DeleteSections: delete extracted sections, if any.
2- All: unclip all views.

8) EditSections
Edit the SectionPlane object list and extracted sections’ options.

Command Flow:
1- Run EditSections command.
2- Select SectionsPlanes (or ClippingPlanes).
3- Select objects.
4- Set options.

Option:
1- UpdateOptions: set to Yes if need to update extracted data options.
Following option show only when UpdateOptions=Yes:
2- Crvs: extract intersecting curves.
3- Caps: extract caps when the sectioned object is solid.
4- Hatches: extract hatches per layer (need to set layer hatch pattern using SetLayerHatchData command).
5- Attributes: either by clipped object or by current layer.
6- All: use same options for all subsequent SectionPlanes.

9) EditSlices
Edit the ClippingSlices object list and data options.

Command Flow:
1- Run EditSlices command.
2- Select SectionPlanes (or ClippingPlanes.)
3- Select objects.
4- Set options.

Option:
1- UpdateOptions: set to Yes if need to update extracted data options.
Following option show only when UpdateOptions=Yes:
2- Thickness: slice thickness.
3- Attributes: either by clipped object or by current layer.
4- All: use same options for all subsequent SectionPlanes.

7 Likes

very nice!

I cannot wait to try this out with the octane render engine…

best

Andreas

Looks excellent, thanks Rajaa!
Before I try it, I see something I think I’ll miss, more creation options, particularly one that would use the current CPlane.

@Rajaa - it might be good to be able to use the V6 IPlane tool to set a section plane.

-Pascal

Rajaa? Can you confirm that sections will render as such in Octane?

Does plain old ClippingPlane work with Octane? If so, I imagine SctionPlane would as well.

-Pascal

Hasn’t worked for me but I remember Paul K saying that it should be possible but I’m not sure he was ever able to implement that. Something that I (and other Octane users I’ sure) have longed for. Octane (for Rhino) has its own clipping plane but it is always in plane with the camera. Paul?

@jodyc111 As Pascal mentioned, if it works for ClippingPlanes, then it will work for the SectionPlane.
@Marc will look into the CPlane and IPlane tools to set the SectionPlane.

1 Like

@Rajaa, I think, if possible, in SectionPlane, at the prompt for the ‘First point’, the user should be able to type IPlane and select a plane that way - at least, that is how IPlane is working so far- it is not an explicit command line option, but can be invoked any time Rhino can use a plane.

-Pascal

@pascal The current way to set the plane is similar to how “section” command works and (SectionTools). It basically creates a section perpendicular to the active CPlane using the 2 point the user selects on the plane. I think this is the more common and intuitive way to set the section plane. Will look into supporting the IPlane as well.

Yep, it’s fine as is, I was just trying to see where IPlane could be invoked in the workflow.

-Pascal

Pascal, I downloaded the latest version of the WIP since getting involved with this thread this morning to see if the clipping plane would work with Octane for Rhino. I found I was unable to load Octane for Rhino in the WIP so unless Walther is doing something I’m not I think he is as he said ‘looking forward’ to using Rhino clipping planes in Octane.

 Here is the message I get when trying to load OctaneRender for Rhino5

Version of Rhino to plug-in was built for does not match
this version of Rhino.
RhinoCommon SDK version = 6.0.0.1
Plug-In built for version = 5.1.30000.15\nDrag and drop unable to load plug-in C:\Program Files\Otoy\OctaneRender for Rhino5\OctaneRenderForRhino.rhp

Hi Jody- Right- V5 plug-ins will not load in V6 …

-Pascal

Maybe Paul K will see this and change that!

As far as I know he will not be able to do anything until the V6 SDK is finalized and locked in - that’s the moment plug-in developers are waiting for…

-Pascal

1 Like

Thanks Pascal. I’m sure PK will be on it when the time comes. He has done a great job with the plugin. As much as I liked the standalone, the plugin has spoiled me and I can’t imagine going back.

Hi there, just to put it straight:

I know that V6 does not currently work with the octane plugin. I was referring to the day we have a finished V6 with a matching octane plugin.
Nevertheless It might be a good thing to pay attention too, especially if this might cause that octane for v5 could work with a future version of the section plane tool for v5…

best

Andreas

New functionality will be in new versions only. There is no retroactivism here :smile:

[quote=“jodyc111, post:12, topic:24619”]
I found I was unable to load Octane for Rhino in the WIP
[/quote]If you email me at paul@physicalc-software.com, I will send you a Rhino6 version of the plugin.

@jodyc111 As Pascal mentioned, if it works for ClippingPlanes, then it will work for the SectionPlane.

I spent some time trying to implement clipping planes in the Octane plugin, but hit a couple of issues, and couldn’t elicit a response from the Rhino devs as to the solution. Render Support for Clipping Planes - #21 by paulphysicalc

Paul

@rajaa where can I download a version of this plugin for RH6 WIP?