JCSG icon indicating copy to clipboard operation
JCSG copied to clipboard

How to make a csg from complicated svg?

Open giloh728 opened this issue 6 years ago • 6 comments

I really appreciate your effort.

I am going to try to make a 3D viewport with CSG function.

It is very important to me about extrusion from DXF section or SVG such as complicated shape.

May I ask why fail to extrude these svg files?

2D section.zip

giloh728 avatar Jul 05 '18 05:07 giloh728

What exactly doesn't work? Is the result unexpected? It's easier to find bugs if you send a minimal working example that demonstrates the bug.

miho avatar Jul 05 '18 08:07 miho

If you are just looking for functions that load a complex SVG to a CSG (including hole detection and auto differencing), check out https://github.com/NeuronRobotics/JCSG/blob/development/src/main/java/eu/mihosoft/vrl/v3d/svg/ My fork includes SVG loading and export through a GPU accelerated slicing engine.

madhephaestus avatar Jul 05 '18 17:07 madhephaestus

Thanks for reply all.

@miho https://github.com/giloh728/CSGExample/blob/master/src/main/java/kr/co/giloh/example/SVGExtrudeExample.java

This is the simple example.

@madhephaestus thanks a lot for suggestion. My project refered to [ JavaCad(compile group: 'com.neuronrobotics', name: 'JavaCad', version: '0.15.0') ]. But It couldn't work to me.

giloh728 avatar Jul 06 '18 04:07 giloh728

It looks like you are using a JCSG fork. @madhephaestus might be able to help you out. JCSG only provides limited SVG functionality via https://github.com/miho/JCSG-PathExtensions. If you encounter problems with that please open an issue there and reference this issue.

miho avatar Jul 06 '18 09:07 miho

@giloh728 The Imports for my fork are different, I forked before they all changed in the mainline. Ill get it harmonized one of these days...

In the mean time, you can just erase the import statements and let the IDE find the new imports.

madhephaestus avatar Jul 06 '18 18:07 madhephaestus

I understood!!

I didn't know about fork function.

I will try test using a JCSG fork(JCSG-PathExtensions).

I really appreciated helpers.

giloh728 avatar Jul 09 '18 01:07 giloh728