Closed kb-elmo closed 2 years ago
I suspect that your outline is not continuous and you have small gaps between the arc. PcbDraw expects a continuous outline. This is somewhat addressed in the upcoming v1 release.
I think if the outline wasn't continuous it wouldn't get rendered properly in the KiCAD rendered either and throw an error instead.
But it works perfectly fine in there.
KiCAD renderer tolerates discontinuations up to 0.1mm. This is not what we do; we expect a perfectly continuous outline at the moment. If you want to check for outline continuations, run it through KiKit – it will exactly tell you where the discontinuation is.
Like I said there doesn't seem to be any discontinuation in the outline.
I added the example file to my original post btw so you can check it yourself if you don't believe me.
Thank you, having the file will help me to trace the bug (I confirm it is there).
Just my 2 cents: the edge polygon is OK, because I use PcbDraw to compose a fast print of the PCB in KiBot and I get:
I'm extracting the masks from the file generated by PcbDraw and then composing the result to be similar to what you get from KiCad (using print options).
Hello :)
I also have been having some similar issues when the corners are not square. Below is an image of two very similar, but different boards. In an attempt to troubleshoot I copy-pasted the edge-cuts layer from the good board on the right into the bad board the left using pcb_new
, but the odd behavior persisted.
My system is: KiCad 6.0.6 on Ubuntu 22.04
Below is a zip file with two nearly identical minimal boards, as seen above. One of them draws fine and the other has that big weird triangle. Perhaps it can be used as a troubleshooting aid. I was using KiBot when I ran into the issue, and I left some convenience Make and yaml files in there.
Thanks and all the best.
Hi @JordanAceto !
I found the problem and will be fixed in the PcbDraw that I include with KiBot. The problem is just about the tolerance in the code that joins segments, it was 5 nm and now is 1 µm. The failing case is a 52 nm error in the KiCad SVG generation (rounding issues). PcbDraw is changing a lot and I'm not sure if I'll be able to use the current git code soon.
The patch is here: https://github.com/INTI-CMNB/PcbDraw/commit/e18d42c725f691f751cef78804e9142e12e13911
Hi @set-soft, what you wrote makes perfect sense. I confirm that when I apply your patch the left board from my image above prints correctly. Thank you!
Hi @JordanAceto and @kb-elmo ! I added a new release to my fork: https://github.com/INTI-CMNB/PcbDraw/releases/tag/v0.9.0-2 including this patch. Is also uploaded it to the KiBot Debian/Ubuntu repo: https://set-soft.github.io/debian/
The change was applied in 2f50ead
Thanks! 😄
@yaqwsx would it be possible to include this fix in a new release of kikit docker? I would like to have this fix in my github actions automated workflow.
Note that v1 was released, which includes proper edges reconstruction. Also, the KiKit docker image already contains this new version.
When trying to render a PCB that is not a simple square and instead has multiple different angled sides PCBdraw renders most of the PCB as a transparent area.
Example:
Rendered file:
test_pcb.zip