discuss@lists.openscad.org

OpenSCAD general discussion Mailing-list

View all threads

Re: Center of a 2d object

RW
Raymond West
Tue, Nov 12, 2024 1:54 PM

I have, in the past, generated a point (#circle(5), say, and moved it by
trial and error over the required location.

Here is a random design for a simple control panel cutout.

How, in text, would you define that the two fixing holes, and make them
horizontal? (once users are given an inch (or 25.4mm) they will want to
take a mile, at least.)

(I went down the rabbit hole of asking ChatGPT (I never defined it was
openscad) I just gave it the dxf file. It wrote me a python script,
which I'm not going to check, since it ends in a day of arguing.)

I asked - 'I want to rotate the large circle with the two small circles
90 degrees so that the two circles are horizontal. can you rewrite the
dxf file'

On 11/11/2024 22:44, Jordan Brown wrote:

On 11/11/2024 10:37 AM, Raymond West via Discuss wrote:

Without getting feedback from cursor position, I'm not sure how you
could define corners - 'top-left' wouldn't always work, for example.

I think for that most people would be happy with an "ordinary" view of
the coordinate system - in 2D, "top left" is minimum-X, maximum-Y.  Of
course, your observation is itself relative to the surrounding
coordinate system.

I have, in the past, generated a point (#circle(5), say, and moved it by trial and error over the required location. Here is a random design for a simple control panel cutout. How, in text, would you define that the two fixing holes, and make them horizontal? (once users are given an inch (or 25.4mm) they will want to take a mile, at least.) (I went down the rabbit hole of asking ChatGPT (I never defined it was openscad) I just gave it the dxf file. It wrote me a python script, which I'm not going to check, since it ends in a day of arguing.) I asked - 'I want to rotate the large circle with the two small circles 90 degrees so that the two circles are horizontal. can you rewrite the dxf file' On 11/11/2024 22:44, Jordan Brown wrote: > On 11/11/2024 10:37 AM, Raymond West via Discuss wrote: >> Without getting feedback from cursor position, I'm not sure how you >> could define corners - 'top-left' wouldn't always work, for example. > > I think for that most people would be happy with an "ordinary" view of > the coordinate system - in 2D, "top left" is minimum-X, maximum-Y.  Of > course, your observation is itself relative to the surrounding > coordinate system.