Graphic Circle on F.Mask Not Appearing in Gerbers

Hi, I’m working on a project that has several graphic circles on the F.Mask layer as part of the user interface (it’s meant to show up as a silver ring for visual effect).

When I plot the gerber files and check them in gerbview the graphic circles do not show up on the F.Mask layer. They are 0.5mm line thickness with a variety of diameters.

My board is pretty complex and contains a lot of detail on the silkscreen and soldermask layer. It has trouble rendering in the 3-D viewer of PCBnew.

I’m wondering if this is just a rendering error in gerbview, or if I’ve done something incorrect with my export settings which is causing the graphic circles to be left out. Can anyone advise on this?

Here is what the the board looks like in PCBnew:

Here is what the board looks like in gerbview (notice F.Mask rings are gone):

Have you tried other viewers? There are online options or the GEDA viewer.

I have some vague memories with problems with circles somewhere in KiCad.
I also seem to remember something about a bug and fixed a long time ago.
Are you using the current KiCad V5.1.5 ?

Maybe this helps:
https://forum.kicad.info/search?q=gerber%20circle

Also, as hermit suggested, using another Gerber viewer (possibly online) may help.

I’m using 5.1.2, haven’t had a reason to update to 5.15 and don’t necessarily want to do that in the middle of a complex project. Seems like this issue is from back in 2015 so it seems like it would have been solved by now but maybe not?

So the um… F.Mask file is too large for online gerb viewers :face_with_hand_over_mouth:. This is kind of an art project so that layer contains a bunch of graphics information. Kind of pushing the limits of the software here, but that’s part of the fun.

When I export the circles by themselves in a separate layer they show up in the online viewers.

When I open this project in gerbview I get the following error messages:


Which seems to suggest rendering is being challenged by the size of the file.

And the following:


Which seems to suggest that the gerber viewer is having trouble with certain parts of the files it’s reading.

Seems likely that it’s just a rendering error because the file is so huge?

I suggest that you raise this as a bug report.
Gerbview should either handle the complex file or give a clear and accurate warning on why it cannot

Why don’t you just give the files (KiCad project) here as an attachement, or if it’s too large, in some file share service? Somebody here could test it. The bug report would now inevitably be inaccurate because you have two problems: circles not showing and out of (graphics hardware) memory. They may be unrelated.

That seems like a great idea. Here is a download link for the gerber files:

https://drive.google.com/file/d/1SNIYgssybFXoatufEDDcWStIeSJO59Gv/view?usp=sharing

1 Like

Can you share the actual KiCad project? It would be much easier to experiment.

1 Like

I tried to open the F.Mask gerber with v5.99 and gerbview crashed.

I’ll report this as a bug. Let’s see afterwards how it will be fixed and if the circle problem persists.

EDIT: please keep the file in gdrive. It’s too large to attach to a gitlab bug report.

I opened mask layer with gerbv (long time). I see circles:

1 Like

I could open
Using v5.1.6-pre I was able to open al layers except for the mask layer, GerbView just closed while trying to open it.

using gerbv v2.6.1 however worked just fine:



Application: KiCad
Version: (5.1.5-133-g9cb60dcdf)-1, release build
Libraries:
    wxWidgets 3.0.4
    libcurl/7.66.0 OpenSSL/1.1.1d (Schannel) zlib/1.2.11 brotli/1.0.7 libidn2/2.2.0 libpsl/0.21.0 (+libidn2/2.1.1) nghttp2/1.39.2
Platform: Windows 8 (build 9200), 64-bit edition, 64 bit, Little endian, wxMSW
Build Info:
    wxWidgets: 3.0.4 (wchar_t,wx containers,compatible with 2.8)
    Boost: 1.71.0
    OpenCASCADE Community Edition: 6.9.1
    Curl: 7.66.0
    Compiler: GCC 9.2.0 with C++ ABI 1013

Build settings:
    USE_WX_GRAPHICS_CONTEXT=OFF
    USE_WX_OVERLAY=OFF
    KICAD_SCRIPTING=ON
    KICAD_SCRIPTING_MODULES=ON
    KICAD_SCRIPTING_PYTHON3=OFF
    KICAD_SCRIPTING_WXPYTHON=ON
    KICAD_SCRIPTING_WXPYTHON_PHOENIX=OFF
    KICAD_SCRIPTING_ACTION_MENU=ON
    BUILD_GITHUB_PLUGIN=ON
    KICAD_USE_OCE=ON
    KICAD_USE_OCC=OFF
    KICAD_SPICE=ON

I do not give myself much hope with opening a 301 MiB Gerber file.
Just out of curiosity (and against better judgement) I did try to open it in GerbView. Which resulted in me resetting my PC 23 minutes later.

I have a 12 year old Dualcore with a measely 4GB of ram.

Opening the file in Geany (my text editor) is a nice stress test, and I can even scroll though the 15 million lines of text without effort.

Files of this size often are badly formed, for example with excessive small unviewable details or even blunt file errors. I do not know if this is true in this case, but I do see repetition of coordinates for example:

image

lines 815910 and 815911 are the same, and I see this throughout the file.
The 2nd block (starting at line 815907) is a square with the end point the same as the beginning, but i’m not sure what the repetition of the coordinates on those other lines signify.

After that, I took the first 5000 lines of F.Mask, put it in a separate file and opened it in GerbView. I see 9 concentric circles and some small stuff in the lower right corner.

This handfull of pixels is 100kiB of the file.
Each pixel seems to be a square polygon which quite confirmes my suspicions of an extremely inefficient way of doing things.

There must be much better ways to import the same artwork with higher quality and less filesize into Pcbnew?
How repetitive is your border pattern?
If it’s highly repetitive, then re-tracing a bit of it in a vector format and making an array out of it seems like a good idea.

How did you make the artwork? What tools did you use to convert?
Are you aware of svg2shenzhen?

Dumping big bitmaps into a vector program is almost a recipe for a disaster waiting to happen. Even if you manage to make it with KiCad, I would not be surprised if a PCB manufacturer refuses to try to make it.

In one of my other experiment with this file I took the first part and the last part of F_Mask, (Edited with a text editor)
Now I have a gerber file of less than 3kiB that crashes Gerbview when I try to open it. The file itself may be ill formed, but Gerbview crashes with the message:

Segmentation fault (core dumped)

That reeks of something that should not happen.
Is a (possibly or likely) ill formed file valuable for a crash report if it (reliably?) crashes Gerbview?

The file in question is:
Ouroboros_2020-05-05_134_Lines.gbr (2.8 KB)

Application: KiCad
Version: 5.1.5-52549c5~86~ubuntu18.04.1, release build
Libraries:
wxWidgets 3.0.4
libcurl/7.58.0 OpenSSL/1.1.1 zlib/1.2.11 libidn2/2.0.4 libpsl/0.19.1 (+libidn2/2.0.4) nghttp2/1.30.0 librtmp/2.3
Platform: Linux 5.3.0-51-generic x86_64, 64 bit, Little endian, wxGTK
Build Info:
wxWidgets: 3.0.4 (wchar_t,wx containers,compatible with 2.8) GTK+ 3.22
Boost: 1.65.1
OpenCASCADE Community Edition: 6.9.1
Curl: 7.58.0
Compiler: GCC 7.5.0 with C++ ABI 1011

Build settings:
USE_WX_GRAPHICS_CONTEXT=OFF
USE_WX_OVERLAY=ON
KICAD_SCRIPTING=ON
KICAD_SCRIPTING_MODULES=ON
KICAD_SCRIPTING_PYTHON3=ON
KICAD_SCRIPTING_WXPYTHON=ON
KICAD_SCRIPTING_WXPYTHON_PHOENIX=ON
KICAD_SCRIPTING_ACTION_MENU=ON
BUILD_GITHUB_PLUGIN=ON
KICAD_USE_OCE=ON
KICAD_USE_OCC=OFF
KICAD_SPICE=ON

1 Like

There is a bug report here
https://gitlab.com/kicad/code/kicad/-/issues/4337

Yes, it should be possible to at least open the gerber file with the next nightly build (5.99). I’ll check then how the circles look like.

Leaving a crash unfixed in 5.1.6rc is odd, but the deeper issue is why is the Gerber so big. I don’t think anyone will make it

Damn svg to shenzen looks great, I’m def going to check out using that for future designs. Thanks for the tip.

Been using img2mod by wayneandlayne, which just renders pixels as squares on the graphics layer, which I know is a pretty inefficient way of doing it, but this is just an experiment for an artistic project, so its mostly worked well enough.

elecrow will make, I’m sure many other fab houses will too.

In

Application: KiCad
Version: 5.1.5-52549c5~84~ubuntu19.10.1, release build
Libraries:
    wxWidgets 3.0.4
    libcurl/7.65.3 OpenSSL/1.1.1c zlib/1.2.11 libidn2/2.2.0 libpsl/0.20.2 (+libidn2/2.0.5) libssh/0.9.0/openssl/zlib nghttp2/1.39.2 librtmp/2.3
Platform: Linux 5.3.0-52-generic x86_64, 64 bit, Little endian, wxGTK
Build Info:
    wxWidgets: 3.0.4 (wchar_t,wx containers,compatible with 2.8) GTK+ 3.24
    Boost: 1.67.0
    OpenCASCADE Community Edition: 6.9.1
    Curl: 7.65.3
    Compiler: GCC 9.2.1 with C++ ABI 1013
Build settings:
    USE_WX_GRAPHICS_CONTEXT=OFF
    USE_WX_OVERLAY=ON
    KICAD_SCRIPTING=ON
    KICAD_SCRIPTING_MODULES=ON
    KICAD_SCRIPTING_PYTHON3=ON
    KICAD_SCRIPTING_WXPYTHON=ON
    KICAD_SCRIPTING_WXPYTHON_PHOENIX=ON
    KICAD_SCRIPTING_ACTION_MENU=ON
    BUILD_GITHUB_PLUGIN=ON
    KICAD_USE_OCE=ON
    KICAD_USE_OCC=OFF
    KICAD_SPICE=ON

opens normally.


Computer: i7, 24G RAM, Nvidia GTX 9950M 4G RAM