SectionPlane bound's bounding box corners are all the same values

I have a PickHelper tool that can draw outlines of entities. There isn’t too much data that can be obtained from the Sketchup::SectionPlane API description (the plane method’s data is useful). Section planes inherit a “bounds” method from DrawingElement, but currently a section plane’s bounding box object has its corner method returning the same point for all 8 corners. Is this documented anywhere?

Perhaps it is related to GitHub issue tracker:

Does the container containing the Section Plane have anything else (with valid size) within it ?
(Per the logged issue, a Section Plane inherits the size of it’s parent container.)

Yes, it was at the main model level with other drawing elements. I Should have mentioned that.

Given a model with some drawing elements, add a section plane (that will make it the last entity):

ents = Sketchup.active_model.entities.to_a
sp_bbox = ents.last.bounds
for index in 0..7 do
  puts "  Corner(#{index}): #{sp_bbox.corner(index)}"

Yes I do believe it is related to the issue referenced. (And no it is not documented.)
Basically the methods inherited by Drawingelement do not “play well” within the Section Plane class.

Ie, the bounds for a Section Plane are currently problematic and need work.
The workaround is likely to use it’s parent’s bounds.

Section Planes doesn’t have a size per se. They are infinite planes and they are just drawn finite in the UI for convenience.

The plane method for the object returns the coefficients for the infinite plane, but it would be nice to have access to the 4 finite corners when a developer wants to outline them somehow with their own tool. I do put a rectangle on one, but it sounds like the way it behaves is not a bug, but a feature.

DrawingElement#bounds is not intended to return the four corners of the visual representation of the section plane.

But I can see the use for having access to them in some form. Care to log a feature request? Issues · SketchUp/api-issue-tracker (

In the API issue I opened that Bruce already mentioned in the opening post, I noted …

What Bruce has found in addition to what I found, shows that the SectionPlane class did not inherit functionality well at all.

I would say add comments to the issue I opened that Bruce already mentioned in the opening post.

In that I also mentioned …

A note in the API docs could be added to this effect until the class instance methods get fixed or enhanced.

I would say not yet.

1 Like

I update the comments at the referenced issue (574) to include a request that, if a bounding box is provided, that it include the section plane’s 4 corners.


Just wondering … does the plane’s produce a valid point ?

I put a section plane on the overall model of something I was working on (not in a grouped object). It produces a valid Point3d that is somewhere within the bounds of the model, but not what appears to be the center of the section plane.

My work around for determining the section plane’s bounds center is to obtain the associated model or grouped object center point that the section plane is in (and part of) and project it onto the section plane.

1 Like

Yeah, that is what I was thinking. To use the projection (distance from the parent’s bottom bounds) as a transform to adjust the parent containers lower bounds corner points so that they are the section plane’s corners.