# Bounding box for planeGeometry and latheGeometry is wrong

I can’t get there correct bounding box for planeGeometry and latheGeometry. For boxGeometry and cylinderGeometry bounding box works well, but for latheGeometry bounding box coordinates is 0. I can’t find any idea how to fix it.

``````var geo = new LatheGeometry( points, 10 );
geo.computeBoundingBox();
console.log ( geo.boundingBox )
``````

version 140

it’s a bit of an obvious question but the only one that may be relative to the resulting bounding box being 0,0,0… your `points` is an array of `vector2`’s right? any chance you can share how you’re creating that array?

also, in the documentation it’s stated that

points — Array of Vector2s. The x-coordinate of each point must be greater than zero.

although it also goes on to say…

Default is an array with (0,-0.5), (0.5,0) and (0,0.5) which creates a simple diamond shape.

which is contradictory to the previous statement…

1 Like

I create array of points with Shape

``````var p = new Shape();
p.moveTo ( 0.001, 0 );
p.lineTo ( 40, 0 );
p.lineTo ( 40, 10 );
p.lineTo ( 50, 10 );
p.lineTo ( 50, 0 );
var points = p.getPoints();
var geo = new LatheGeometry( points, 10 );
geo.computeBoundingBox();
console.log ( geo.boundingBox )
``````

After changing first point from 0 to 0.001 a have a different result, but still wrong. The min values calculated right, but max values the same of min. A similar result can be obtained for PlaneGeometry

Unfortunately, I cannot reproduce your result. Using the same code, I get different `min` and `max`. Could you try to make an online demo (on CodePen or other system)?

Here is what I get:

Which version of ThreeJS are you using?

This is what I have

Tried with r140 and r150. Both work fine.

1 Like

I found the problem. I’m using three.min.js, but after changing to three.js bounding box was calculate correctly. Thank you for help

1 Like

so the issue is with rollup/terser then? maybe @Mugen87 knows why or where to report it