3D view
The board in 3D from its stack-up, with component models, section cuts and presets.
Alt+3 or KiCad: 3D view. The board is extruded from its stack-up (copper, mask, silk, finish);
component models come from kicad-cli pcb export glb of the current text, cached by content, so they
appear after a few seconds the first time and instantly afterwards. Electronics Designer: Refresh 3D Model re-exports
after edits. The 3D tab has view presets, render options, model visibility per footprint, a section
cut and a screenshot button. Clicking a part selects its footprint in both views.
Every copper layer of the stack-up sits at its height with its thickness, and plated holes have barrels (blind and buried vias span only their layers). Dielectric opacity (X-ray) in the 3D tab makes the substrate translucent so the inner copper and the barrels show through; the line under it counts the copper layers, dielectrics and barrels (and says when the board has no stack-up and a default one is used).
Realistic view#
The Realistic section of the 3D tab switches the view from Standard to a physically based preset: copper
finish, solder mask, silkscreen and the FR4 core get metal/roughness materials, an image-based environment lights them
(a procedural HDR-like scene prefiltered with three.js PMREMGenerator), the key light casts soft shadows (components
on the board, the fillets) and the frame is tone mapped with ACES filmic at the chosen exposure. Standard is the view as
before; the Colours, Copper finish and Lighting rows apply to it only.
- Finish: Stack-up (the board’s
(copper_finish …)), ENIG, HASL or Bare Cu, on every exposed pad and the barrels. - Mask colour: from the stack-up, or green, red, blue, black, white, purple. The mask has two colours, as in pcb2blender: a darker one over bare FR4 and a lighter one where copper is under it, so traces and planes show through.
- Mask gloss (0–100 %): 50 % keeps the colour’s own roughness; higher values lower it and add a clear coat (IOR 1.5), lower values give a satin mask.
- Mask translucency (0–100 %, default 17 % = 1 − KiCad’s mask alpha 0.83): how much the copper tints the mask over it (and the metallic sheen through it) and how much of the FR4 shows through the rest.
- Silkscreen: from the stack-up, white or black ink (matte).
- Environment: Studio (dark room, overhead softbox, two strip lights) or Overcast (sky dome).
- Exposure (0.25–3, ACES filmic), Shadows, Fibre texture (a glass-weave normal map on the FR4 core and faintly through the mask) and Pad fillets (a solder dome on each SMD pad with a paste aperture, a meniscus around each plated through hole).
The settings are part of the 3D options (view3d.render, view3d.realistic), so they work the same from the 3D view
shown as its own pane, persist with the other 3D options and apply to Screenshot. Headless renders take them too:
edsnx render png board.kicad_pcb --realistic --out board-3d.png renders the 3D view with the preset, and
--view3d '{"realistic":{"finish":"enig","mask":"black"}}' (or the same view3d argument of the render.png command)
picks its options.
Values and where they come from:
| Parameter | Value adopted | Source |
|---|---|---|
| ENIG finish | colour #efdfbb, metalness 1, roughness 0.1 | pcb2blender Surface Finish BSDF ENIG [1]; Remoticon workshop: gold pads metallic 0.7–0.9, roughness 0.1–0.3 [5] |
| HASL finish | colour #eaeae5, metalness 1, roughness 0.15 | pcb2blender Surface Finish BSDF HASL [1] |
| Bare Cu finish (also copper under the mask, inner layers) | colour #e1bbac, metalness 1, roughness 0.1 | pcb2blender Surface Finish BSDF NONE [1] |
| Green mask | over copper #43a142, over FR4 #22521f, roughness 0.45 | pcb2blender MASK_COLOR_MAP / DEFAULT_MASK_ROUGHNESS [1] |
| Red mask | over copper #de544c, over FR4 #733a38, roughness 0.45 | pcb2blender MASK_COLOR_MAP [1] |
| Blue mask | over copper #3b69aa, over FR4 #1c3659, roughness 0.45 | pcb2blender MASK_COLOR_MAP [1] |
| Black mask | over copper #10100f, over FR4 #000000, roughness 0.45 (stack-up “Matte black”: #191919, 0.8) | pcb2blender MASK_COLOR_MAP, MASK_ROUGHNESS_MAP [1] |
| White mask | over copper #d3cfc9, over FR4 #e1dddc, roughness 0.4 | pcb2blender MASK_COLOR_MAP, MASK_ROUGHNESS_MAP [1] |
| Purple mask | over copper #7448aa, over FR4 #3b2359, roughness 0.45 | pcb2blender MASK_COLOR_MAP [1] |
| Custom stack-up mask colour #rrggbb | over copper = the colour, over FR4 = 0.2 × it | pcb2blender CUSTOM mask [1] |
| Mask translucency default | 0.17 | KiCad VRML export mask alpha 0.83 [3] |
| Mask gloss | roughness from the colour’s value (50 %) to 0.06 (100 %), clear coat 0–0.5, IOR 1.5 | KiCad ray tracer mask shininess 108.8–512 → GGX α = √(2 / (n + 2)) = 0.135–0.06 [4][7] |
| Copper sheen through the mask | metalness 0.6 × translucency | pcb2blender Solder Mask BSDF Metallic 0.6 [1] |
| White silkscreen | colour #f3f1f0, roughness 0.41 | colour pcb2blender Silkscreen BSDF [1]; roughness KiCad ray tracer silk shininess 10 → α 0.41 [4][7] |
| Black silkscreen | colour #100f0f, roughness 0.41 | colour pcb2blender Silkscreen BSDF [1]; roughness as white [4][7] |
| FR4 core | colour #a4a858, roughness 0.6, metalness 0 | mat4cad pcb_yellow [2] and pcb2blender Board Edge BSDF roughness 0.6 [1] |
| FR4 opacity | 0.83 (kept opaque; the mask translucency shows it) | KiCad VRML “FR4 natural” alpha [3] |
| Glass weave | 0.4 mm bundle pitch, normal strength 0.35 (0.04 through the mask) | pcb2blender mask Voronoi scale 3000 / m (0.33 mm cells) and bump strength −0.012…0.044 [1] |
| Solder (fillets, paste) | colour #aaaaa6, metalness 1, roughness 0.25 | pcb2blender Solder BSDF [1] |
| Fillet heights | SMD dome 0.07 mm (8 % inside the paste aperture), THT meniscus 0.35 mm to 1.15 × the hole radius | proportions of pcb2blender’s solder joints [1] |
| Tone mapping, exposure | ACES filmic, 1.0 | three.js ACESFilmicToneMapping [6] |
| Environment | PMREM of a procedural scene: Studio (room 0.6, ceiling diffuser 0.9, key softbox 9, strips 6 and 5); Overcast (zenith 1.1, horizon 0.75, ground 0.18) | three.js PMREMGenerator.fromScene [6]; intensities ours |
| Shadows | key light (2.2 Studio, 0.9 Overcast), 2048² PCF soft shadow map, radius 4 | three.js PCFSoftShadowMap [6] |
[1] pcb2blender, pcb2blender_importer/materials.py (commit 2a2ac82): https://github.com/30350n/pcb2blender/blob/main/pcb2blender_importer/materials.py
[2] mat4cad, colors.py: https://github.com/30350n/mat4cad/blob/main/colors.py
[3] KiCad, pcbnew/exporters/exporter_vrml.cpp (initStaticColorList, toVRMLColor): https://docs.kicad.org/doxygen/exporter__vrml_8cpp_source.html
[4] KiCad, 3d-viewer/3d_rendering/raytracing/create_scene.cpp (setupMaterials): https://docs.kicad.org/doxygen/raytracing_2create__scene_8cpp_source.html
[5] “Remoticon: KiCad to Blender”, PCB renders log: https://hackaday.io/project/175077/logs
[6] three.js renderer constants and PMREMGenerator: https://threejs.org/docs/#api/en/constants/Renderer, https://threejs.org/docs/#api/en/extras/PMREMGenerator
[7] Blinn-Phong exponent to GGX roughness, α = √(2 / (n + 2)): B. Karis, “Specular BRDF Reference”: https://graphicrants.blogspot.com/2013/08/specular-brdf-reference.html
The table is checked against the code (src/webview/scene3dUtil.ts REAL_*) by test/realistic3d.test.ts.
Performance: the shadow map is redrawn only when the scene changes (not while orbiting). On the sample board, orbiting
the 3D view (776 × 691 canvas) takes a median 16.9 ms a frame (59 fps, p90 25 ms) with the Realistic preset (Studio)
and 18.7 ms (53 fps) with Overcast on an Intel UHD integrated GPU (Raptor Lake-S, Mesa), against 10.4 ms in Standard;
on an RTX 4060 Laptop GPU 9.7 ms (103 fps) against 6.6 ms.