Commit Graph

735 Commits

Author SHA1 Message Date
Ian McInerney 1683e552f7 Add/fix some variable initializations 2022-09-25 00:48:38 +01:00
Alex bdf4cf51b8 Add a missing statement in segments reservation.
Also adds an assert in FinishItem.

Fixes https://gitlab.com/kicad/code/kicad/issues/12448
2022-09-19 02:36:21 +00:00
dsa-t bd8b737c44 GAL: Do better job at reserving vertices. 2022-09-14 16:07:47 +00:00
jean-pierre charras df35576cf9 fix my previous commit (c0661468) broken. 2022-09-09 19:00:47 +02:00
jean-pierre charras c06614689e OPENGL_GAL: disable bitmap image caching due to serious issues (memory leak)
It was re-enabled by commit cbc3bfbf.
The current code to handle cached bitmaps is no longer compatible with the
current code.
Many cached items are created because a lot of clones are used to manage bitmap images.
Cached items are never cleaned, so a lot of memory is never freed after
using these temporary clones
And caching items do not significantly speedup drawings.
2022-09-09 18:37:30 +02:00
jean-pierre charras c13b938a4b Free memory when unused, forgotten in my commit d4feb59e 2022-09-08 13:07:36 +02:00
jean-pierre charras d4feb59ed9 OPENGL_GAL, draw bitmap: Rebuild the bitmap cache if the bitmap itself was rotated.
Fixes #12378
https://gitlab.com/kicad/code/kicad/issues/12378
Fix also a Coverity warning.
2022-09-08 12:00:43 +02:00
Seth Hillbrand f1261e71d4 Replace boost::optional with std::optional 2022-08-25 15:50:47 -07:00
Marek Roszko fc99b3ba95 Don't link gdiplus everywhere anymore
Tested on msys2 which is the only place it would have been buggy
CMake seems to share the gdiplus linkage with the other dependencies automatically now
2022-08-23 23:51:35 -04:00
jean-pierre charras 4bfbf91369 3D viewer: Fix incorrect behavior when moving the scene
Fixes #12114
https://gitlab.com/kicad/code/kicad/issues/12114
2022-07-30 13:27:25 +02:00
Jeff Young 7386e64923 Attempt to work-around wxWidgets bug with Serbian & Russian locales.
Fixes https://gitlab.com/kicad/code/kicad/issues/12002

Fixes https://gitlab.com/kicad/code/kicad/issues/11963
2022-07-20 17:52:48 +01:00
Mike Williams 3669cb4673 PCB Editor: Add User Background Images 2022-07-14 11:23:23 +00:00
Mike Williams cbc3bfbf08 GAL: Re-enable OpenGL bitmap cache
Might still have issues, re-enabling for wider test.
2022-07-14 11:23:23 +00:00
Mike Williams 3e80963482 GAL: Delete no-effect target changes 2022-07-14 11:23:23 +00:00
Fabien Corona 976670e987 Move 3D controls to a new class 2022-06-21 23:38:22 +00:00
dsa-t 3a76435eda OpenGL: Use glGetProgramiv instead of the extension function. 2022-06-09 19:37:42 +00:00
Mike Williams 857990a883 Hierarchy: turn into a left side pane
Drop auto-closing option as well.
2022-06-02 21:56:17 +00:00
Marek Roszko 417f2f357c Cleanup naming of shader params/uniforms 2022-05-19 07:49:24 -04:00
Jeff Young 38e5faf21b Overhaul bitmap text for performance.
Also adjusts metrics to better match stroke font.

Also removes text-halo highlighting as it's too expensive to re-render
when the zoom changes.

Fixes https://gitlab.com/kicad/code/kicad/issues/11460
2022-05-14 20:09:54 +01:00
Marek Roszko 6d7835e742 Switch shader storage to char arrays 2022-05-14 11:39:46 -04:00
Marek Roszko 8288f24264 Move all the shaders to glsl files (and fix the processor more) 2022-05-12 23:37:44 -04:00
Marek Roszko 6188f632b9 Initial implementation of shader translation to cpp at build time 2022-05-12 23:37:44 -04:00
Marek Roszko abfe944299 Split gal cmake target to a subdirectory 2022-05-11 20:22:22 -04:00
jean-pierre charras 1d5be1adeb Cairo GAL: fix incorrect size and thickness of text drawn by GAL::BitmapText() 2022-04-08 18:40:26 +02:00
Jeff Young bf0f2aa4a8 Adjust bitmap text spacing a bit so it's closer to the stroke font.
This helps the text better match the highlighting when it gets small
enough that we switch to the bitmap font for performance.
2022-03-07 20:30:50 +00:00
Jeff Young a8d2dd8dc7 Bitmap text can't yet handle multi-line text. 2022-03-06 16:59:18 +00:00
Jeff Young a29968fa91 Make sure bitmap fallback is only used for non-cached text.
Also fixes backwards vertical justification for bitmap text.

Fixes https://gitlab.com/kicad/code/kicad/issues/10956
2022-02-24 18:16:45 +00:00
Marek Roszko 1f8d101b1d Fix color4d distance return type 2022-02-06 21:05:44 -05:00
Wayne Stambaugh 8426ffa238 Fix wxWidgets invalid string specifier assertion.
(cherry picked from commit ab184ba9f3)
2022-01-24 15:50:40 -05:00
Jeff Young c8a50d9b50 Remove unit-less angles from VECTOR2I/D APIs. 2022-01-20 23:58:20 +00:00
Jeff Young 4a05b36bc6 Prefer EDA_ANGLE to naked radians. 2022-01-20 21:10:04 +00:00
Jeff Young e84c574830 Some more EDA_ANGLE cleanup. 2022-01-16 19:16:18 +00:00
Marek Roszko 8fe16690b7 Add array deleter 2022-01-14 22:04:47 -05:00
Jeff Young 07013d00e1 More EDA_ANGLE. 2022-01-14 16:08:19 +00:00
Jeff Young 33338aa0f2 Formatting. 2022-01-11 14:34:16 +00:00
Jeff Young 8f7d2dd06a More VECTOR2D -> VECTOR2I and wxPoint cleanup. 2022-01-11 14:20:14 +00:00
Jeff Young 7d032f9c2f Outline font rendering for Cairo, plotter, printer and 3D viewer.
Fixes https://gitlab.com/kicad/code/kicad/issues/10319
2022-01-10 01:54:28 +00:00
Jeff Young 05cfdd3907 Supply a text size & thickness for GAL::StrokeText
Fixes https://gitlab.com/kicad/code/kicad/issues/10226
2022-01-08 16:47:45 +00:00
Jeff Young 04c76f10e9 Performance enhancements for fonts. 2022-01-08 16:47:45 +00:00
Ola Rinta-Koski 9b406c1da4 Outline font support. 2022-01-08 16:47:45 +00:00
Seth Hillbrand 26c0a78947 Plot pads in layer color
v6 pads are not allowed to be a different color from the rest of the
copper layer, so don't query the GAL layer for a color

Fixes https://gitlab.com/kicad/code/kicad/issues/10293

(cherry picked from commit bfca928900)
2022-01-07 08:56:22 -08:00
Jeff Young 8e4a4306c7 Go back to using inter-character spacing from the stroke font.
Fixes https://gitlab.com/kicad/code/kicad/issues/1078
2022-01-04 00:46:08 +00:00
Mike Williams 404659d275 Gerbview: Fix diff mode issues with OpenGL transparency
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/10121
2022-01-02 23:15:36 +00:00
Marek Roszko ec83537576 Fix missing win32 header 2022-01-02 13:07:56 -05:00
jean-pierre charras c4af66f6d3 Fix compil issues on Windows+msys2
Probably some fixes also on other platforms
2022-01-02 18:32:39 +01:00
Jeff Young 89c0f8e297 Move to new font engine. 2022-01-02 14:57:03 +00:00
Jeff Young 86cb57f4a7 Cherry-pick TEXT_ATTRIBUTES and EDA_ANGLE from rockola/kicad-strokefont 2021-12-28 22:15:20 +00:00
Seth Hillbrand 78ff9a857a Jerry-rig HTML-format alpha parsing
On wx3.0, the HTML format #RRGGBBAA cannot handle the alpha channel.
Instead, we route this through a COLOR4D routine when we need to use
these colors

Fixes https://gitlab.com/kicad/code/kicad/issues/9963
2021-12-13 16:04:40 -08:00
Jon Evans a205595404 PROF_COUNTER -> PROF_TIMER
I want to add an event counter, and this one is a timer
2021-12-05 14:25:37 -05:00
jean-pierre charras f24bdf4067 Fix minor Coverity warnings (not initialized vars). 2021-12-03 17:55:21 +01:00