Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added new small font, default to small font when in pixel doubled mode #27

Merged
merged 1 commit into from
Oct 20, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
101 changes: 101 additions & 0 deletions libraries/assets.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,106 @@ namespace picosystem {
};

#ifndef NO_FONT
#ifdef PIXEL_DOUBLE
const uint8_t _default_font[96][9] = {
{0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00},
{1, 0x80, 0x80, 0x80, 0x00, 0x80, 0x00, 0x00, 0x00},
{3, 0xa0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00},
{3, 0xa0, 0xe0, 0xa0, 0xe0, 0xa0, 0x00, 0x00, 0x00},
{3, 0x40, 0xe0, 0xc0, 0x60, 0xe0, 0x40, 0x00, 0x00},
{3, 0xa0, 0x20, 0x40, 0x80, 0xa0, 0x00, 0x00, 0x00},
{3, 0x60, 0x80, 0xe0, 0xc0, 0x60, 0x00, 0x00, 0x00},
{2, 0x40, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00},
{2, 0x40, 0x80, 0x80, 0x80, 0x40, 0x00, 0x00, 0x00},
{2, 0x80, 0x40, 0x40, 0x40, 0x80, 0x00, 0x00, 0x00},
{3, 0x40, 0xe0, 0x40, 0xa0, 0x00, 0x00, 0x00, 0x00},
{3, 0x00, 0x40, 0xe0, 0x40, 0x00, 0x00, 0x00, 0x00},
{1, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x80, 0x00},
{3, 0x00, 0x00, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00},
{1, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00},
{3, 0x20, 0x20, 0x40, 0x80, 0x80, 0x00, 0x00, 0x00},
{3, 0x60, 0xa0, 0xa0, 0xa0, 0xc0, 0x00, 0x00, 0x00},
{3, 0x40, 0xc0, 0x40, 0x40, 0xe0, 0x00, 0x00, 0x00},
{3, 0xc0, 0x20, 0xe0, 0x80, 0xe0, 0x00, 0x00, 0x00},
{3, 0xc0, 0x20, 0x60, 0x20, 0xe0, 0x00, 0x00, 0x00},
{3, 0x80, 0xa0, 0xe0, 0x20, 0x20, 0x00, 0x00, 0x00},
{3, 0xe0, 0x80, 0xe0, 0x20, 0xc0, 0x00, 0x00, 0x00},
{3, 0x60, 0x80, 0xe0, 0xa0, 0xc0, 0x00, 0x00, 0x00},
{3, 0xe0, 0x20, 0x40, 0x40, 0x40, 0x00, 0x00, 0x00},
{3, 0x60, 0xa0, 0xe0, 0xa0, 0xc0, 0x00, 0x00, 0x00},
{3, 0x60, 0xa0, 0xe0, 0x20, 0xc0, 0x00, 0x00, 0x00},
{1, 0x00, 0x80, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00},
{1, 0x00, 0x80, 0x00, 0x80, 0x80, 0x00, 0x00, 0x00},
{2, 0x00, 0x40, 0x80, 0x40, 0x00, 0x00, 0x00, 0x00},
{3, 0x00, 0xe0, 0x00, 0xe0, 0x00, 0x00, 0x00, 0x00},
{2, 0x00, 0x80, 0x40, 0x80, 0x00, 0x00, 0x00, 0x00},
{3, 0xe0, 0x20, 0x40, 0x00, 0x40, 0x00, 0x00, 0x00},
{3, 0x60, 0xe0, 0xe0, 0x80, 0x60, 0x00, 0x00, 0x00},
{3, 0x60, 0xa0, 0xe0, 0xa0, 0xa0, 0x00, 0x00, 0x00},
{3, 0xc0, 0xa0, 0xe0, 0xa0, 0xe0, 0x00, 0x00, 0x00},
{3, 0x60, 0x80, 0x80, 0x80, 0x60, 0x00, 0x00, 0x00},
{3, 0xc0, 0xa0, 0xa0, 0xa0, 0xe0, 0x00, 0x00, 0x00},
{3, 0x60, 0x80, 0xc0, 0x80, 0xe0, 0x00, 0x00, 0x00},
{3, 0x60, 0x80, 0xe0, 0x80, 0x80, 0x00, 0x00, 0x00},
{3, 0x60, 0x80, 0x80, 0xa0, 0xe0, 0x00, 0x00, 0x00},
{3, 0xa0, 0xa0, 0xe0, 0xa0, 0xa0, 0x00, 0x00, 0x00},
{3, 0xe0, 0x40, 0x40, 0x40, 0xe0, 0x00, 0x00, 0x00},
{3, 0x60, 0x20, 0x20, 0x20, 0xc0, 0x00, 0x00, 0x00},
{3, 0xa0, 0xa0, 0xc0, 0xa0, 0xa0, 0x00, 0x00, 0x00},
{3, 0x80, 0x80, 0x80, 0x80, 0xe0, 0x00, 0x00, 0x00},
{3, 0xe0, 0xe0, 0xa0, 0xa0, 0xa0, 0x00, 0x00, 0x00},
{3, 0xc0, 0xa0, 0xa0, 0xa0, 0xa0, 0x00, 0x00, 0x00},
{3, 0x60, 0xa0, 0xa0, 0xa0, 0xc0, 0x00, 0x00, 0x00},
{3, 0xc0, 0xa0, 0xe0, 0x80, 0x80, 0x00, 0x00, 0x00},
{3, 0x60, 0xa0, 0xa0, 0xc0, 0x60, 0x00, 0x00, 0x00},
{3, 0xc0, 0xa0, 0xc0, 0xa0, 0xa0, 0x00, 0x00, 0x00},
{3, 0x60, 0x80, 0x40, 0x20, 0xc0, 0x00, 0x00, 0x00},
{3, 0xe0, 0x40, 0x40, 0x40, 0x40, 0x00, 0x00, 0x00},
{3, 0xa0, 0xa0, 0xa0, 0xa0, 0xc0, 0x00, 0x00, 0x00},
{3, 0xa0, 0xa0, 0xa0, 0xa0, 0x40, 0x00, 0x00, 0x00},
{3, 0xa0, 0xa0, 0xa0, 0xe0, 0xe0, 0x00, 0x00, 0x00},
{3, 0xa0, 0xa0, 0x40, 0xa0, 0xa0, 0x00, 0x00, 0x00},
{3, 0xa0, 0xa0, 0x40, 0x40, 0x40, 0x00, 0x00, 0x00},
{3, 0xe0, 0x20, 0x40, 0x80, 0xe0, 0x00, 0x00, 0x00},
{2, 0xc0, 0x80, 0x80, 0x80, 0xc0, 0x00, 0x00, 0x00},
{3, 0x80, 0x80, 0x40, 0x20, 0x20, 0x00, 0x00, 0x00},
{2, 0xc0, 0x40, 0x40, 0x40, 0xc0, 0x00, 0x00, 0x00},
{3, 0x00, 0x40, 0xa0, 0x00, 0x00, 0x00, 0x00, 0x00},
{3, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x00},
{2, 0x00, 0x80, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00},
{3, 0x00, 0x60, 0xa0, 0xa0, 0x60, 0x00, 0x00, 0x00},
{3, 0x80, 0xc0, 0xa0, 0xa0, 0xc0, 0x00, 0x00, 0x00},
{3, 0x00, 0x60, 0x80, 0x80, 0x60, 0x00, 0x00, 0x00},
{3, 0x20, 0x60, 0xa0, 0xa0, 0x60, 0x00, 0x00, 0x00},
{3, 0x00, 0x60, 0xa0, 0xc0, 0x60, 0x00, 0x00, 0x00},
{2, 0x40, 0x80, 0xc0, 0x80, 0x80, 0x00, 0x00, 0x00},
{3, 0x00, 0x60, 0xa0, 0xa0, 0x60, 0x20, 0x40, 0x00},
{3, 0x80, 0xc0, 0xa0, 0xa0, 0xa0, 0x00, 0x00, 0x00},
{1, 0x80, 0x00, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00},
{2, 0x40, 0x00, 0x40, 0x40, 0x80, 0x00, 0x00, 0x00},
{3, 0x80, 0xa0, 0xc0, 0xa0, 0xa0, 0x00, 0x00, 0x00},
{2, 0x80, 0x80, 0x80, 0x80, 0x40, 0x00, 0x00, 0x00},
{3, 0x00, 0xe0, 0xe0, 0xa0, 0xa0, 0x00, 0x00, 0x00},
{3, 0x00, 0xc0, 0xa0, 0xa0, 0xa0, 0x00, 0x00, 0x00},
{3, 0x00, 0x60, 0xa0, 0xa0, 0xc0, 0x00, 0x00, 0x00},
{3, 0x00, 0xc0, 0xa0, 0xa0, 0xc0, 0x80, 0x80, 0x00},
{3, 0x00, 0x60, 0xa0, 0xa0, 0x60, 0x20, 0x20, 0x00},
{2, 0x00, 0x40, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00},
{3, 0x00, 0x60, 0x80, 0x20, 0xc0, 0x00, 0x00, 0x00},
{2, 0x80, 0xc0, 0x80, 0x80, 0x40, 0x00, 0x00, 0x00},
{3, 0x00, 0xa0, 0xa0, 0xa0, 0xc0, 0x00, 0x00, 0x00},
{3, 0x00, 0xa0, 0xa0, 0xa0, 0x40, 0x00, 0x00, 0x00},
{3, 0x00, 0xa0, 0xa0, 0xe0, 0xe0, 0x00, 0x00, 0x00},
{3, 0x00, 0xa0, 0x40, 0xa0, 0xa0, 0x00, 0x00, 0x00},
{3, 0x00, 0xa0, 0xa0, 0xa0, 0x60, 0x20, 0x40, 0x00},
{3, 0x00, 0xe0, 0x20, 0x80, 0xe0, 0x00, 0x00, 0x00},
{3, 0x60, 0x40, 0xc0, 0x40, 0x60, 0x00, 0x00, 0x00},
{1, 0x80, 0x80, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00},
{3, 0xc0, 0x40, 0x60, 0x40, 0xc0, 0x00, 0x00, 0x00},
{3, 0x00, 0x20, 0xe0, 0x80, 0x00, 0x00, 0x00, 0x00},
{0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00},
};
#else
const uint8_t _default_font[96][9] = {
{1, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00},
{1, 0x80, 0x80, 0x80, 0x80, 0x80, 0x00, 0x80, 0x00},
Expand Down Expand Up @@ -141,6 +241,7 @@ namespace picosystem {
{0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00},
};
#endif
#endif

// https://github.com/32blit/32blit-sdk/blob/master/assets/s4m_ur4i-dingbads.png
// A collection of handy icons and graphics created for us by @s4m_ur4i
Expand Down