Commit graph

57 commits

Author SHA1 Message Date
Caleb Connolly
1a6bb17cb1
drm: make optional
Make DRM configurable at build time to avoid increasing the size of
pbsplash. DRM support is not yet suitable to be enabled by default, but
it's nice to have it merged in so the code doesn't bitrot.

Signed-off-by: Caleb Connolly <caleb.connolly@linaro.org>
2023-11-26 10:37:00 +01:00
Caleb Connolly
96d181885e
font fixes for iosevka
The font handling was somewhat hardcoded for OpenSans, make some
adjustments for iosevka.

Signed-off-by: Caleb Connolly <caleb.connolly@linaro.org>
2023-11-26 10:02:08 +01:00
Caleb Connolly
0b0de8faf4
nanosvg: font fixes
Signed-off-by: Caleb Connolly <caleb.connolly@linaro.org>
2023-11-21 05:36:49 +00:00
Caleb Connolly
42f442d08c
drm: make master
Signed-off-by: Caleb Connolly <caleb.connolly@linaro.org>
2023-11-21 05:35:42 +00:00
Caleb Connolly
458926088e
fonts: add customised Iosevka fonts
Iosevka-Term is a monospaced sans-serif font, Aile is a non-monospaced
variant. Iosevka fonts are open source and the versions here are from

https://github.com/be5invis/Iosevka/tree/v28.0.0-alpha.1

The TTF font files were downloaded and converted to SVG with fontforge,
then all non-ascii glyphs were removed for space saving.

Signed-off-by: Caleb Connolly <caleb.connolly@linaro.org>
2023-11-21 05:33:26 +00:00
Caleb Connolly
26b0fe1b22
nanosvg: move to C file
no need to keep this in a header.

Signed-off-by: Caleb Connolly <caleb.connolly@linaro.org>
2023-11-21 04:16:13 +00:00
Caleb Connolly
3a71d0437b
drm working
Signed-off-by: Caleb Connolly <caleb.connolly@linaro.org>
2023-11-21 02:49:38 +00:00
Caleb Connolly
01af13950c
WIP: vendor tfblib + clang-format
We only need a subset of it, to iterate faster and integrate features
like in-line rotation let's vendor it for now.

Signed-off-by: Caleb Connolly <caleb@connolly.tech>
2023-07-28 20:15:06 +01:00
Caleb Connolly
760ad79c92
remove some old debug logs
Signed-off-by: Caleb Connolly <caleb@connolly.tech>
2023-07-28 18:04:05 +01:00
Caleb Connolly
080fcf60ca
line split mid-word instead of hanging
The line splitting implementation would look behind to find a space to
split on. This does not work if the line is one long word (like a URL),
and this implementation would hang as a result.

Add support for splitting mid-word in this case and prevent pbsplash
from hanging.
2023-03-06 01:12:31 +00:00
Caleb Connolly
52cb0ae649
nanosvgrast: small cleanup 2023-03-06 00:28:35 +00:00
Caleb Connolly
706888caf4
last few cleanups 2023-02-20 02:31:55 +00:00
Caleb Connolly
3c96de11dd
add timespec lib, decouple animation from frambuffer rate 2023-02-20 02:25:27 +00:00
Caleb Connolly
4a98f0a0cf
finish refactor, zero allocs to make valgrind happy 2023-02-20 01:25:37 +00:00
Caleb Connolly
7b714e433e
factor out message printing, use const where possible 2023-02-19 16:54:25 +00:00
Caleb Connolly
d7e9eca325
filled circles, factor out physical size calculations, slightly adjust bottom text 2023-02-19 16:32:31 +00:00
Caleb Connolly
22f07eb624
increase logo size slightly, fix text getting cut off 2023-02-06 17:17:19 +00:00
Caleb Connolly
83ab7e731d
limit logo to 25mm, move text to lower 2022-08-07 14:49:21 +01:00
Caleb Connolly
9d9633e1f3
terrible logo scaling hacks
Probably breaks landscape devices?
2022-08-06 20:08:26 +01:00
Caleb Connolly
cc37eea120
text: half space char width 2022-08-06 19:35:04 +01:00
Oliver Smith
85fc1c0a41
Add argument to disable animation
For displaying error messages, let's not show the loading animation.
2022-08-06 19:31:45 +01:00
Caleb Connolly
1ab85c2a33
TEST: animate: thicker circle outline 2022-08-06 19:30:23 +01:00
Caleb Connolly
435f8a7977
adjust sizes/positions 2022-08-06 19:30:11 +01:00
Oliver Smith
e2366e9d4f
Support message line at the bottom 2022-08-06 18:50:59 +01:00
Oliver Smith
a1df67dfce
nsvgGetTextShapes: fix uninitialized values
Use calloc to zero ret, because ret[i] does not get written if
NSVG_FLAGS_VISIBLE is unset. Found with valgrind.
2022-08-06 18:45:51 +01:00
Oliver Smith
fc5f065269
nanosvg: build implementation in extra c file
Speed up development iterations by building the nanosvg implementation
only once. Especially on the PinePhone it takes a bit.
2022-08-06 18:45:22 +01:00
Oliver Smith
36b0e6780b
include: add missing declarations
Add nsvgGetTextShapes() and nsvgRasterizeText() declarations outside of
the _IMPLEMENTATION areas, so the headerfiles can be used without
having _IMPLEMENTATION set.
2022-08-06 18:44:53 +01:00
Oliver Smith
2d79d8ad6a
Tweak the animation and placement
* Move the animation between the logo and the text
* Move text further below
* Change circles to 3 (like ...) and increase speed to 5
* Change circles radius, distance, amplitude
* Draw empty circles instead of full circles, to be used with a logo
  that also has an outline
2022-08-06 18:44:29 +01:00
Oliver Smith
817f988022
animate: fix fill_rect height 2022-08-06 18:44:29 +01:00
Oliver Smith
f94f3269da
getopt: make logo_size_max configurable with -q 2022-08-06 18:44:27 +01:00
Oliver Smith
67c9a10db4
usage: fix argument line
Add missing arguments, order them the same as listed below.
2022-08-06 18:36:45 +01:00
Oliver Smith
99ce784c28
getopt: remove unneeded check for -d
Remove the extra check for a value after specifying -d, as getopt() is
already taking care of it:

  pbsplash: option requires an argument: d
2022-08-06 18:36:04 +01:00
Oliver Smith
883ce77d1e
getopt: fix error msg for invalid dpi 2022-08-06 18:35:57 +01:00
Caleb Connolly
9c05d2c7f3
gitignore: ignore more stuff 2022-08-06 18:35:43 +01:00
Caleb Connolly
3c25e1ba44
support newlines + automatic line splitting 2022-08-06 18:34:10 +01:00
Caleb Connolly
5780f60199
render static logo on exit 2022-07-24 16:48:14 +01:00
Caleb Connolly
86b7c8f1c3
clang-format 2022-07-05 15:00:53 +01:00
Caleb Connolly
4410f12762
animate: fix centering on circles 2022-07-05 14:08:26 +01:00
Caleb Connolly
a5af6e1a50
nanosvg: fix some dodgy checks 2022-07-05 14:07:33 +01:00
Caleb Connolly
0e626c1812
pbsplash: offset text slightly below the logo 2022-07-05 14:07:16 +01:00
Martijn Braam
b6625648c9
DPI scaling for the dots 2022-07-05 13:22:08 +01:00
Caleb Connolly
e5f4c50b18
fix help, don't debug by default 2022-07-05 13:21:22 +01:00
Caleb Connolly
6d899d9971
it's ready?! 2022-03-12 23:23:23 +00:00
Caleb Connolly
ec1bfbd2fd
lots of fixes, add animations! 2022-03-11 02:26:04 +00:00
Caleb Connolly
5f6f3726bb
pbsplash: more fixing up, scaling issues, cleanup 2022-03-10 00:43:35 +00:00
Caleb Connolly
31a5ad48e4
more scaling stuff for PC 2022-02-28 00:49:26 +00:00
Caleb Connolly
4c90c076eb
dont forget to link math on gkib 2022-02-28 00:35:59 +00:00
Caleb Connolly
2e07eceb15
pbsplash: some updates / fixes 2022-02-27 23:33:16 +00:00
Caleb Connolly
768aefef93
functional implementation 🥳 2022-02-23 01:20:05 +00:00
Caleb Connolly
8f09ee1628
fix fb behaviour for splash 2022-01-23 23:54:01 +00:00