Author Topic: [Engraving] - Gaz (Joe Bar Team)  (Read 40699 times)

Offline dh42

  • Administrator
  • CNC Jedi
  • *****
  • Posts: 7564
    • View Profile
    • Cambam V1.0 French Doc
Re: [Engraving] - Gaz (Joe Bar Team)
« Reply #15 on: June 16, 2015, 15:28:30 pm »
@Eddy: Maybe you forgot the accent ;)

Couche = Layer
Couché = Lying down

Quote
It's a great plugin that CBubble   ::)

sure  ;D

Ok, I just wrote a little script to select CW or CCW and after remove the one or the other I obtain a nice file without other job to do  ;D .. (but spline to polyline is very long)

after this first cleaning, I use dave's plugin to remove open/closed poly <= 4mm perimeter.

before converting spline to poly, is set the tolerance (option) to 0.1mm .. that give a very nice result
   
Code: [Select]
' select CW/CCW polylines
' dh42 06/2015

sub main

'ask for CW/CCW

dim rep as string
dim p as polyline

CamBamConfig.Defaults.ReloadTreeAfterScript = false

rep = inputbox("1 - Select CW " & vbnewline & "2 - Select CCW ",, 1)

if rep <> 1 and rep <> 2 then exit sub

dim newselection as ArrayList = new ArrayList()

if view.SelectedEntities.Length > 0 then


for each ent as Entity in view.SelectedEntities

if typeof ent is Polyline

p = ent

if p.closed = true 'only if closed polyline
select case rep

case 1 'CW

if p.direction = -1 then
newselection.add(ent)
end if

case 2 'CCW

if p.direction = 1 then
newselection.add(ent)
end if

end select

end if

end if

next ent

view.Select(newselection)

view.RefreshView()

end if

end sub

++
David

Offline dh42

  • Administrator
  • CNC Jedi
  • *****
  • Posts: 7564
    • View Profile
    • Cambam V1.0 French Doc
Re: [Engraving] - Gaz (Joe Bar Team)
« Reply #16 on: June 16, 2015, 15:31:56 pm »
re

And just another little script to count how many drawing objects are selected  ;D

++
David

Code: [Select]
' count selected

sub main

dim ct as long
Dim ent As Entity

    For Each ent In view.SelectedEntities
            ct = ct+1
        Next

app.log(ct & " Objets sélectionnés")


end sub

Offline dave benson

  • CNC Jedi
  • *****
  • Posts: 1889
    • View Profile
Re: [Engraving] - Gaz (Joe Bar Team)
« Reply #17 on: June 18, 2015, 13:14:26 pm »
HI David
I've been playing around with Inkscape and have found a to produce a file with no splines just lines which
are quick to work with. I have started from a jpeg and imported it into Inkscape processed it and then exported
it and loaded it up in CB ran the polyline doctor over it and then generated a engraving file and simulated
I was surprised at how quick this was to produce perhaps 5 seconds for a file of 1meg.It's late now so in the morning I'll do the same thing with the image file you posted and see if that works fast to.
Dave.

Offline dh42

  • Administrator
  • CNC Jedi
  • *****
  • Posts: 7564
    • View Profile
    • Cambam V1.0 French Doc
Re: [Engraving] - Gaz (Joe Bar Team)
« Reply #18 on: June 18, 2015, 13:57:39 pm »
Hello Dave,

I wonder what's taking so long to convert a spline to a polyline.

I wrote a little script that count the points in a spline. (and creates a point list).

for a spline that contain 433 points, the conversion to polyline takes 15s !! (the test spline + vbs are in attachment)

++
David

Offline dh42

  • Administrator
  • CNC Jedi
  • *****
  • Posts: 7564
    • View Profile
    • Cambam V1.0 French Doc
Re: [Engraving] - Gaz (Joe Bar Team)
« Reply #19 on: June 20, 2015, 18:58:31 pm »
hello,

2 new conversions



Use a V-cutter with a flat tip = 0.3/0.4mm

the results with CV





If you want to cut it with a smaller size (approx 200x200mm), use an engraving operation instead of a pocket operation.

DXF and CB file in attachment.

++
David

Offline klystron

  • Ewok
  • *
  • Posts: 36
    • View Profile
Re: [Engraving] - Gaz (Joe Bar Team)
« Reply #20 on: June 21, 2015, 14:12:08 pm »
salut !
conversion de fichier en ligne :

http://www.autotracer.org/

a+
« Last Edit: June 21, 2015, 14:16:20 pm by klystron »

Offline dave benson

  • CNC Jedi
  • *****
  • Posts: 1889
    • View Profile
Re: [Engraving] - Gaz (Joe Bar Team)
« Reply #21 on: June 21, 2015, 23:40:42 pm »
I went and had a look at the web site klystron and they also have a stl converter as well but I noted that the file size was limited to 1mb could be handy.
Davis I think the splines and associated functions are just dealing with more data and having to convert between types is adding to the time taken.
Dave