AM
Adrian Mariano
Sun, Jun 1, 2025 9:52 PM
I have 2025.04.29 and noticed that if I generate a png file like this:
openscad -o test.png test.scad
then CGAL runs, which is evident because it fails with errors. If I run
the stable 2021.01 version then CGAL does NOT run. Is this an intentional
change? How do I prevent CGAL from running with the dev version?
I have 2025.04.29 and noticed that if I generate a png file like this:
openscad -o test.png test.scad
then CGAL runs, which is evident because it fails with errors. If I run
the stable 2021.01 version then CGAL does NOT run. Is this an intentional
change? How do I prevent CGAL from running with the dev version?
MK
Marius Kintel
Sun, Jun 1, 2025 11:06 PM
You cannot completely disable all CGAL code paths, as certain features (like minkowski) still requires CGAL.
..but this should get you one step closer:
openscad -o test.png test.scad --backend=manifold
-Marius
On Jun 1, 2025, at 17:52, Adrian Mariano via Discuss discuss@lists.openscad.org wrote:
I have 2025.04.29 and noticed that if I generate a png file like this:
openscad -o test.png test.scad
then CGAL runs, which is evident because it fails with errors. If I run the stable 2021.01 version then CGAL does NOT run. Is this an intentional change? How do I prevent CGAL from running with the dev version?
OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org
You cannot completely disable all CGAL code paths, as certain features (like minkowski) still requires CGAL.
..but this should get you one step closer:
openscad -o test.png test.scad --backend=manifold
-Marius
> On Jun 1, 2025, at 17:52, Adrian Mariano via Discuss <discuss@lists.openscad.org> wrote:
>
> I have 2025.04.29 and noticed that if I generate a png file like this:
>
> openscad -o test.png test.scad
>
> then CGAL runs, which is evident because it fails with errors. If I run the stable 2021.01 version then CGAL does NOT run. Is this an intentional change? How do I prevent CGAL from running with the dev version?
> _______________________________________________
> OpenSCAD mailing list
> To unsubscribe send an email to discuss-leave@lists.openscad.org
AM
Adrian Mariano
Sun, Jun 1, 2025 11:21 PM
The model in question works interactively if I preview it and fails if I
render with CGAL. It succeeds if I render with manifold. However, working
around this case, e.g. by enabling manifold, isn't really a solution. I
need to be able to preview non-manifold models and write out their PNG
image. I also need it to be as fast as possible. This is the code base
that generates all the hundreds of example images in the BOSL2 wiki, which
apparently works for Revar using the 2022.08.22 build. But I don't have
that build. And apparently the code uses some options that don't exist in
2021.01, so I can't use that version.
Hmmm. Actually I just realized that it works in CGAL in 2021.01. It only
fails CGAL in 2025.04.29. And the failure is odd. It's an assertion
failure, and then it produces the geometry anyway:
ERROR: CGAL error in CGALUtils::applyUnion3D: CGAL ERROR: assertion
violation!
Expr: itl != it->second.end()
File:
/build/openscad-nightly/stage/usr/include/CGAL/Nef_3/SNC_external_structure.h
Line: 1078
On Sun, Jun 1, 2025 at 7:07 PM Marius Kintel via Discuss <
discuss@lists.openscad.org> wrote:
You cannot completely disable all CGAL code paths, as certain features
(like minkowski) still requires CGAL.
..but this should get you one step closer:
openscad -o test.png test.scad --backend=manifold
-Marius
On Jun 1, 2025, at 17:52, Adrian Mariano via Discuss <
I have 2025.04.29 and noticed that if I generate a png file like this:
openscad -o test.png test.scad
then CGAL runs, which is evident because it fails with errors. If I run
the stable 2021.01 version then CGAL does NOT run. Is this an intentional
change? How do I prevent CGAL from running with the dev version?
The model in question works interactively if I preview it and fails if I
render with CGAL. It succeeds if I render with manifold. However, working
around this case, e.g. by enabling manifold, isn't really a solution. I
need to be able to preview non-manifold models and write out their PNG
image. I also need it to be as fast as possible. This is the code base
that generates all the hundreds of example images in the BOSL2 wiki, which
apparently works for Revar using the 2022.08.22 build. But I don't have
that build. And apparently the code uses some options that don't exist in
2021.01, so I can't use that version.
Hmmm. Actually I just realized that it works in CGAL in 2021.01. It only
fails CGAL in 2025.04.29. And the failure is odd. It's an assertion
failure, and then it produces the geometry anyway:
ERROR: CGAL error in CGALUtils::applyUnion3D: CGAL ERROR: assertion
violation!
Expr: itl != it->second.end()
File:
/build/openscad-nightly/stage/usr/include/CGAL/Nef_3/SNC_external_structure.h
Line: 1078
On Sun, Jun 1, 2025 at 7:07 PM Marius Kintel via Discuss <
discuss@lists.openscad.org> wrote:
> You cannot completely disable all CGAL code paths, as certain features
> (like minkowski) still requires CGAL.
>
> ..but this should get you one step closer:
>
> openscad -o test.png test.scad --backend=manifold
>
> -Marius
>
>
> > On Jun 1, 2025, at 17:52, Adrian Mariano via Discuss <
> discuss@lists.openscad.org> wrote:
> >
> > I have 2025.04.29 and noticed that if I generate a png file like this:
> >
> > openscad -o test.png test.scad
> >
> > then CGAL runs, which is evident because it fails with errors. If I run
> the stable 2021.01 version then CGAL does NOT run. Is this an intentional
> change? How do I prevent CGAL from running with the dev version?
> > _______________________________________________
> > OpenSCAD mailing list
> > To unsubscribe send an email to discuss-leave@lists.openscad.org
> _______________________________________________
> OpenSCAD mailing list
> To unsubscribe send an email to discuss-leave@lists.openscad.org
>
MK
Marius Kintel
Sun, Jun 1, 2025 11:44 PM
Why is previewing with manifold not an option? That’s soon going to be the default preview mechanism.
The CGAL regression is worth looking into though.
Do you have a minimal example or two that demonstrates the issues in question?
- Why --backend=manifold isn’t viable
- Highlights the CGAL regression
-Marius
On Jun 1, 2025, at 19:21, Adrian Mariano via Discuss discuss@lists.openscad.org wrote:
The model in question works interactively if I preview it and fails if I render with CGAL. It succeeds if I render with manifold. However, working around this case, e.g. by enabling manifold, isn't really a solution. I need to be able to preview non-manifold models and write out their PNG image. I also need it to be as fast as possible. This is the code base that generates all the hundreds of example images in the BOSL2 wiki, which apparently works for Revar using the 2022.08.22 build. But I don't have that build. And apparently the code uses some options that don't exist in 2021.01, so I can't use that version.
Hmmm. Actually I just realized that it works in CGAL in 2021.01. It only fails CGAL in 2025.04.29. And the failure is odd. It's an assertion failure, and then it produces the geometry anyway:
ERROR: CGAL error in CGALUtils::applyUnion3D: CGAL ERROR: assertion violation!
Expr: itl != it->second.end()
File: /build/openscad-nightly/stage/usr/include/CGAL/Nef_3/SNC_external_structure.h
Line: 1078
Why is previewing with manifold not an option? That’s soon going to be the default preview mechanism.
The CGAL regression is worth looking into though.
Do you have a minimal example or two that demonstrates the issues in question?
1. Why --backend=manifold isn’t viable
2. Highlights the CGAL regression
-Marius
> On Jun 1, 2025, at 19:21, Adrian Mariano via Discuss <discuss@lists.openscad.org> wrote:
>
> The model in question works interactively if I preview it and fails if I render with CGAL. It succeeds if I render with manifold. However, working around this case, e.g. by enabling manifold, isn't really a solution. I need to be able to preview non-manifold models and write out their PNG image. I also need it to be as fast as possible. This is the code base that generates all the hundreds of example images in the BOSL2 wiki, which apparently works for Revar using the 2022.08.22 build. But I don't have that build. And apparently the code uses some options that don't exist in 2021.01, so I can't use that version.
>
> Hmmm. Actually I just realized that it works in CGAL in 2021.01. It only fails CGAL in 2025.04.29. And the failure is odd. It's an assertion failure, and then it produces the geometry anyway:
>
> ERROR: CGAL error in CGALUtils::applyUnion3D: CGAL ERROR: assertion violation!
> Expr: itl != it->second.end()
> File: /build/openscad-nightly/stage/usr/include/CGAL/Nef_3/SNC_external_structure.h
> Line: 1078
>
>
>
AM
Adrian Mariano
Sun, Jun 1, 2025 11:57 PM
This is my current example:
include<BOSL2/std.scad>
cuboid([30,40,50], rounding=8, teardrop=true);
As long as you can still preview---presumably without errors---things which
are not valid manifolds then --backend=manifold is likely OK, though if
it's even a little bit slower that's unfortunate.
On Sun, Jun 1, 2025 at 7:45 PM Marius Kintel marius@kintel.net wrote:
Why is previewing with manifold not an option? That’s soon going to be the
default preview mechanism.
The CGAL regression is worth looking into though.
Do you have a minimal example or two that demonstrates the issues in
question?
- Why --backend=manifold isn’t viable
- Highlights the CGAL regression
-Marius
On Jun 1, 2025, at 19:21, Adrian Mariano via Discuss <
discuss@lists.openscad.org> wrote:
The model in question works interactively if I preview it and fails if I
render with CGAL. It succeeds if I render with manifold. However, working
around this case, e.g. by enabling manifold, isn't really a solution. I
need to be able to preview non-manifold models and write out their PNG
image. I also need it to be as fast as possible. This is the code base
that generates all the hundreds of example images in the BOSL2 wiki, which
apparently works for Revar using the 2022.08.22 build. But I don't have
that build. And apparently the code uses some options that don't exist in
2021.01, so I can't use that version.
Hmmm. Actually I just realized that it works in CGAL in 2021.01. It only
fails CGAL in 2025.04.29. And the failure is odd. It's an assertion
failure, and then it produces the geometry anyway:
ERROR: CGAL error in CGALUtils::applyUnion3D: CGAL ERROR: assertion
violation!
Expr: itl != it->second.end()
File:
/build/openscad-nightly/stage/usr/include/CGAL/Nef_3/SNC_external_structure.h
Line: 1078
This is my current example:
include<BOSL2/std.scad>
cuboid([30,40,50], rounding=8, teardrop=true);
As long as you can still preview---presumably without errors---things which
are not valid manifolds then --backend=manifold is likely OK, though if
it's even a little bit slower that's unfortunate.
On Sun, Jun 1, 2025 at 7:45 PM Marius Kintel <marius@kintel.net> wrote:
> Why is previewing with manifold not an option? That’s soon going to be the
> default preview mechanism.
>
> The CGAL regression is worth looking into though.
>
> Do you have a minimal example or two that demonstrates the issues in
> question?
> 1. Why --backend=manifold isn’t viable
> 2. Highlights the CGAL regression
>
> -Marius
>
> On Jun 1, 2025, at 19:21, Adrian Mariano via Discuss <
> discuss@lists.openscad.org> wrote:
>
> The model in question works interactively if I preview it and fails if I
> render with CGAL. It succeeds if I render with manifold. However, working
> around this case, e.g. by enabling manifold, isn't really a solution. I
> need to be able to preview non-manifold models and write out their PNG
> image. I also need it to be as fast as possible. This is the code base
> that generates all the hundreds of example images in the BOSL2 wiki, which
> apparently works for Revar using the 2022.08.22 build. But I don't have
> that build. And apparently the code uses some options that don't exist in
> 2021.01, so I can't use that version.
>
> Hmmm. Actually I just realized that it works in CGAL in 2021.01. It only
> fails CGAL in 2025.04.29. And the failure is odd. It's an assertion
> failure, and then it produces the geometry anyway:
>
> ERROR: CGAL error in CGALUtils::applyUnion3D: CGAL ERROR: assertion
> violation!
> Expr: itl != it->second.end()
> File:
> /build/openscad-nightly/stage/usr/include/CGAL/Nef_3/SNC_external_structure.h
> Line: 1078
>
>
>
>
>
MK
Marius Kintel
Mon, Jun 2, 2025 12:47 AM
As long as you can still preview---presumably without errors---things which are not valid manifolds then --backend=manifold is likely OK, though if it's even a little bit slower that's unfortunate.
Yeah, --backend=manifold only specifies using the Manifold library instead of CGAL. It doesn’t impose any additional limit on what geometry can be previewed.
In terms of performance, this is a casual test on the examples you posted:
- 2021.01: 5.2 sec
- 2025.05.16 CGAL mode: 16.3 sec
- 2025.05.16 Manifold mode: 1.85 sec
I’ll put the CGAL performance regression on my list, but I feel that the manifold option will be vastly superior :)
-Marius
>
> As long as you can still preview---presumably without errors---things which are not valid manifolds then --backend=manifold is likely OK, though if it's even a little bit slower that's unfortunate.
>
Yeah, --backend=manifold only specifies using the Manifold library instead of CGAL. It doesn’t impose any additional limit on what geometry can be previewed.
In terms of performance, this is a casual test on the examples you posted:
* 2021.01: 5.2 sec
* 2025.05.16 CGAL mode: 16.3 sec
* 2025.05.16 Manifold mode: 1.85 sec
I’ll put the CGAL performance regression on my list, but I feel that the manifold option will be vastly superior :)
-Marius
AM
Adrian Mariano
Mon, Jun 2, 2025 2:13 AM
My results are a little different than what you posted.
2021.01 reports 0.050 seconds
2025.04.29 CGAL reports 9.6 seconds
2025.04.29 Manifold reports 1.2 seconds
Your result for 2021.01 is very odd. How can it take 5.2 seconds to
preview this simple model?
We have 2973 files to process to produce the BOSL2 docs. If the processing
time rises by one second per file that adds 50 minutes to the time it takes
to generate the docs which is currently something like 35 minutes.
On Sun, Jun 1, 2025 at 8:48 PM Marius Kintel marius@kintel.net wrote:
As long as you can still preview---presumably without errors---things
which are not valid manifolds then --backend=manifold is likely OK, though
if it's even a little bit slower that's unfortunate.
Yeah, --backend=manifold only specifies using the Manifold library instead
of CGAL. It doesn’t impose any additional limit on what geometry can be
previewed.
In terms of performance, this is a casual test on the examples you posted:
- 2021.01: 5.2 sec
- 2025.05.16 CGAL mode: 16.3 sec
- 2025.05.16 Manifold mode: 1.85 sec
I’ll put the CGAL performance regression on my list, but I feel that the
manifold option will be vastly superior :)
-Marius
My results are a little different than what you posted.
2021.01 reports 0.050 seconds
2025.04.29 CGAL reports 9.6 seconds
2025.04.29 Manifold reports 1.2 seconds
Your result for 2021.01 is very odd. How can it take 5.2 seconds to
preview this simple model?
We have 2973 files to process to produce the BOSL2 docs. If the processing
time rises by one second per file that adds 50 minutes to the time it takes
to generate the docs which is currently something like 35 minutes.
On Sun, Jun 1, 2025 at 8:48 PM Marius Kintel <marius@kintel.net> wrote:
> >
> > As long as you can still preview---presumably without errors---things
> which are not valid manifolds then --backend=manifold is likely OK, though
> if it's even a little bit slower that's unfortunate.
> >
>
> Yeah, --backend=manifold only specifies using the Manifold library instead
> of CGAL. It doesn’t impose any additional limit on what geometry can be
> previewed.
>
> In terms of performance, this is a casual test on the examples you posted:
> * 2021.01: 5.2 sec
> * 2025.05.16 CGAL mode: 16.3 sec
> * 2025.05.16 Manifold mode: 1.85 sec
>
> I’ll put the CGAL performance regression on my list, but I feel that the
> manifold option will be vastly superior :)
>
> -Marius
>
>
MK
Marius Kintel
Mon, Jun 2, 2025 4:05 AM
Oh, I was running it on a CPU emulator as I don’t an Intel CPU and that build is Intel-only on macOS :/
I’ll re-test and have deeper look. Thanks for your numbers.
-Marius
On Jun 1, 2025, at 22:13, Adrian Mariano avm4@cornell.edu wrote:
My results are a little different than what you posted.
2021.01 reports 0.050 seconds
2025.04.29 CGAL reports 9.6 seconds
2025.04.29 Manifold reports 1.2 seconds
Your result for 2021.01 is very odd. How can it take 5.2 seconds to preview this simple model?
We have 2973 files to process to produce the BOSL2 docs. If the processing time rises by one second per file that adds 50 minutes to the time it takes to generate the docs which is currently something like 35 minutes.
On Sun, Jun 1, 2025 at 8:48 PM Marius Kintel <marius@kintel.net mailto:marius@kintel.net> wrote:
As long as you can still preview---presumably without errors---things which are not valid manifolds then --backend=manifold is likely OK, though if it's even a little bit slower that's unfortunate.
Yeah, --backend=manifold only specifies using the Manifold library instead of CGAL. It doesn’t impose any additional limit on what geometry can be previewed.
In terms of performance, this is a casual test on the examples you posted:
- 2021.01: 5.2 sec
- 2025.05.16 CGAL mode: 16.3 sec
- 2025.05.16 Manifold mode: 1.85 sec
I’ll put the CGAL performance regression on my list, but I feel that the manifold option will be vastly superior :)
-Marius
Oh, I was running it on a CPU emulator as I don’t an Intel CPU and that build is Intel-only on macOS :/
I’ll re-test and have deeper look. Thanks for your numbers.
-Marius
> On Jun 1, 2025, at 22:13, Adrian Mariano <avm4@cornell.edu> wrote:
>
> My results are a little different than what you posted.
>
> 2021.01 reports 0.050 seconds
> 2025.04.29 CGAL reports 9.6 seconds
> 2025.04.29 Manifold reports 1.2 seconds
>
> Your result for 2021.01 is very odd. How can it take 5.2 seconds to preview this simple model?
>
> We have 2973 files to process to produce the BOSL2 docs. If the processing time rises by one second per file that adds 50 minutes to the time it takes to generate the docs which is currently something like 35 minutes.
>
> On Sun, Jun 1, 2025 at 8:48 PM Marius Kintel <marius@kintel.net <mailto:marius@kintel.net>> wrote:
>> >
>> > As long as you can still preview---presumably without errors---things which are not valid manifolds then --backend=manifold is likely OK, though if it's even a little bit slower that's unfortunate.
>> >
>>
>> Yeah, --backend=manifold only specifies using the Manifold library instead of CGAL. It doesn’t impose any additional limit on what geometry can be previewed.
>>
>> In terms of performance, this is a casual test on the examples you posted:
>> * 2021.01: 5.2 sec
>> * 2025.05.16 CGAL mode: 16.3 sec
>> * 2025.05.16 Manifold mode: 1.85 sec
>>
>> I’ll put the CGAL performance regression on my list, but I feel that the manifold option will be vastly superior :)
>>
>> -Marius
>>
RW
Rogier Wolff
Mon, Jun 2, 2025 6:15 AM
On Sun, Jun 01, 2025 at 10:13:33PM -0400, Adrian Mariano via Discuss wrote:
My results are a little different than what you posted.
2021.01 reports 0.050 seconds
2025.04.29 CGAL reports 9.6 seconds
2025.04.29 Manifold reports 1.2 seconds
Your result for 2021.01 is very odd. How can it take 5.2 seconds to
preview this simple model?
Hi, You state 2021.01 REPORTS ...
I've seen a render take several seconds (like say 5 seconds) and then
OpenScad would report absurdly small numbers like 0.05 seconds.
The version x.y reports are not accurate....
Roger.
--
** R.E.Wolff@BitWizard.nl ** https://www.BitWizard.nl/ ** +31-15-2049110 **
** Verl. Spiegelmakerstraat 37 2645 LZ Delfgauw, The Netherlands.
** KVK: 27239233 **
f equals m times a. When your f is steady, and your m is going down
your a** is going up. -- Chris Hadfield about flying up the space shuttle.
** 'a' for accelleration.
On Sun, Jun 01, 2025 at 10:13:33PM -0400, Adrian Mariano via Discuss wrote:
> My results are a little different than what you posted.
>
> 2021.01 reports 0.050 seconds
> 2025.04.29 CGAL reports 9.6 seconds
> 2025.04.29 Manifold reports 1.2 seconds
>
> Your result for 2021.01 is very odd. How can it take 5.2 seconds to
> preview this simple model?
Hi, You state 2021.01 *REPORTS* ...
I've seen a render take several seconds (like say 5 seconds) and then
OpenScad would report absurdly small numbers like 0.05 seconds.
The version x.y reports are not accurate....
Roger.
--
** R.E.Wolff@BitWizard.nl ** https://www.BitWizard.nl/ ** +31-15-2049110 **
** Verl. Spiegelmakerstraat 37 2645 LZ Delfgauw, The Netherlands.
** KVK: 27239233 **
f equals m times a. When your f is steady, and your m is going down
your a** is going up. -- Chris Hadfield about flying up the space shuttle.
** 'a' for accelleration.
JB
Jordan Brown
Mon, Jun 2, 2025 5:58 PM
On 6/1/2025 4:06 PM, Marius Kintel via Discuss wrote:
You cannot completely disable all CGAL code paths, as certain features (like minkowski) still requires CGAL.
..but this should get you one step closer:
openscad -o test.png test.scad --backend=manifold
But what's triggering using CGAL?
Generating a PNG should be a preview operation, not a render, and so
(except for a few operations) avoid CGAL entirely.
Offhand, these should trigger CGAL: render(), rescale(), projection(),
minkowski(), hull().
On 6/1/2025 4:06 PM, Marius Kintel via Discuss wrote:
> You cannot completely disable all CGAL code paths, as certain features (like minkowski) still requires CGAL.
>
> ..but this should get you one step closer:
>
> openscad -o test.png test.scad --backend=manifold
But what's triggering using CGAL?
Generating a PNG should be a preview operation, not a render, and so
(except for a few operations) avoid CGAL entirely.
Offhand, these should trigger CGAL: render(), rescale(), projection(),
minkowski(), hull().