Commit Graph

112 Commits

Author SHA1 Message Date
Phil Howard c4f70df1cf Pen1BitY: Correct RGB to dither lookup conversion. 2024-02-27 13:54:25 +00:00
Phil Howard ce42d814a7 Pico Graphics: Avoid unecessary and broken polygon scanline clip. 2023-10-16 09:56:40 +01:00
Mike Bell e908d5e53e Allow pen function for fast tile alpha blending 2023-09-08 23:48:16 +01:00
Phil Howard 4671607b3a PicoVector: Vector anti-aliasing support. 2023-08-22 09:32:28 +01:00
Phil Howard 9e430fd68c PicoVector: Better separation of concerns, add Alright Fonts support. 2023-08-22 09:32:28 +01:00
Phil Howard e8dba75aff PicoGraphics: Use std:: prefix, fix some type issues. 2023-08-22 09:32:28 +01:00
Phil Howard 09a58b269f PicoGraphics: Various compile warning fixes for Pretty Poly. 2023-08-22 09:32:28 +01:00
Phil Howard cc7219b44a PicoGraphics: Experimental Pretty Poly bring-up. 2023-08-22 09:32:28 +01:00
Phil Howard 1157e605a1 Picovision: Remove DV stick drivers to PV repo. 2023-08-21 14:04:49 +01:00
Mike Bell daf7232024 Limited support for palette and RGB888 modes 2023-08-14 12:40:15 +01:00
Mike Bell a7435c6a5e GPIO High and palette mode support 2023-08-14 12:40:15 +01:00
Mike Bell 5f8e7556f0 Begin DV Stick display driver 2023-08-14 12:40:15 +01:00
Phil Howard 004c8de8eb Bitmap Fonts: Add rotation support.
* Fix bug with word-wrap ignoring \n
* Fix bug with word-wrap miscalculating word size
2023-08-03 16:30:25 +01:00
Phil Howard fba7b53c36 PicoGraphics: Fixed-width bitmap font support. 2023-05-15 11:03:39 +01:00
Phil Howard 73f50e43ec Hershey Fonts: Replace map lookup to avoid std::string. 2023-03-16 13:25:19 +00:00
Phil Howard 375df60ff3 PicoGraphics: Switch to string_view.
MicroPython's GET_STR_DATA_LEN macro returns a const byte array and len, which std::string would copy into heap.

Using string_view lets us wrap the existing const values.
2023-03-16 13:25:19 +00:00
Phil Howard a8a8321405 PicoGraphics: (Try to) handle non-div-2 thickness. 2023-03-08 14:49:09 +00:00
Phil Howard 83f88c034d PicoGraphics: Enable thickness for all pens. Document. 2023-03-08 14:34:28 +00:00
Phil Howard cacb5749ae Inky Frame: Add thickness support for Hershey text. 2023-03-08 11:35:07 +00:00
Phil Howard 0c0a7b3bf6 PicoGraphics: Include dependencies if necessary.
Replaces #346

Co-authored-by: Charlie Birks <charlie@daft.games>
Co-authored-by: ThomasPDye <tompdye@googlemail.com>
2023-02-23 17:23:59 +00:00
Phil Howard bfb2f8d2ba Inky 7.3: Drop unpredictable taupe from dither palette. 2023-02-23 14:37:06 +00:00
Phil Howard bff2e79a56 Inky 5.7: Dithered drawing ported from 7.3. 2023-02-23 14:17:54 +00:00
Phil Howard a5b0633469 Inky 7.3: Dither pixel spans, move RGB flag out of RGB888. 2023-02-23 13:35:41 +00:00
Phil Howard 80fab77270 Inky 7.3: Remove side-effect from set_pixel_dither.
Do not change "color" when dithering the same colour across multiple pixels.
2023-02-23 13:12:07 +00:00
Phil Howard c9f6dfec4f PicoGraphics: from_hsv to RGB::from_hsv. 2023-02-23 12:59:19 +00:00
Phil Howard 3e0cd28876 Inky 7.3: Support dithering of arbitrary colours.
`create_pen` returns an int with the most significant byte set to indicate it is an RGB888 colour.

Pen values without the most significant byte set are treated as palette entries and handled normally.
2023-02-23 12:09:52 +00:00
Phil Howard bea90dfd60 JPEGDEC: Experimental 3bit/4bit palette no-dither. 2023-02-22 15:40:22 +00:00
Phil Howard f4b0434229 PicoGraphics: Add create_pen_hsv to p4, p8 and rgb332 pens. 2023-02-21 12:52:46 +00:00
Phil Howard bbeac41785 Cosmic Unicorn: Implement RGB888 frame convert. 2023-02-21 12:52:46 +00:00
Phil Howard 776383c111 Inky 7.3: Add ordered dither support. 2023-02-20 12:29:59 +00:00
AndrewCapon 0067b101a0 Inky 7.3: Direct pen & PSRAM update. 2023-02-20 12:29:52 +00:00
ZodiusInfuser 5a62a79a93 Renamed thick_line 2023-02-16 10:28:07 +00:00
Phil Howard c3ad87765d PicoGraphics: Extremely cursed thickness support for 1bit pens.
Experimental. There must be less cursed way to do this.
2023-02-10 22:15:07 +00:00
Philip Howard c4decc5003
PicoGraphics: HSV Pen (#665)
Co-authored-by: Gee Bartlett <122281230+ageeandakeyboard@users.noreply.github.com>
2023-02-09 16:13:37 +00:00
Gee Bartlett 104c819412
Hub75: Update to use Picographics (#601)
* have a basic pg working needs optimizing

* working well ported some examples from GU

* started on micropython module

* Fixes to get new Hub75 compiling in MP

* stripped down for faster compilling

* Update hub75.cmake

* added hub75 to galatic and eviro as it is needed for picographics

* Update picographics.c

* added hu75 update

* added _ModPicoGraphics_obj_t

* Update hub75.cpp

* update bindings

* some examples needs linting

* added other panel sizes and linted

* Update picographics.cpp

* Update picographics.c

* fixing gc memory allocation

* Update hub75.cpp

* Update interstate75_balls_demo.cpp

* review

* broke

* working with built in panel defs

* still borked

* not much change needs review

* Update hub75.cpp

* reverted alot of things

* adding i75 lib

* lots of updates ready to test compile mp

* Update picographics.h

* little tweaks

* an inability to count fixed!

* fixed some readme's

* lots of tiding

* fixed linting and removed experimental code

* Minor formatting

* Minor formatting and cmake tidy

* Removed unneeded parts of examples

* Final tidy

* tidy examples and adding more

* updated to new library

* documentation tweaks

* fixed inclusion of interstate75 module

* syncing some stuff

* fixed linting

Co-authored-by: ZodiusInfuser <christopher.parrott2@gmail.com>
2022-12-16 20:53:16 +00:00
ZodiusInfuser b35ed5d5ba Moved MP examples over to PicoGraphics 2022-10-13 13:26:57 +01:00
jon 63183d28be Lots of features added 2022-10-13 13:19:50 +01:00
Phil Howard fc3060b640 PicoGraphics: Simplify RGB565 frame convert.
Rewrite RGB565 frame convert to iterate over pixels by index, and transfer the buffer when it fills.

Avoid using a bitmask so BUF_LEN can be arbitrary.
2022-09-21 11:32:19 +01:00
Phil Howard bb9b5b69d3 PicoGraphics: Fix byte alignment bug in Pen P4.
Fix byte alignment to use the pixel index, rather than just the x-coordinate.

Prevent new rows from being erroneously byte-aligned in displays without an even width (eg: Pico Display portrait).
2022-09-21 11:26:58 +01:00
Mike Bell 7f330d1a04 Pico Graphics: Use fixed size buffer for frame conversion 2022-08-23 23:07:13 +01:00
Mike Bell f341c15fa7 Pico Graphics: Double buffer scanline conversion 2022-08-23 21:48:26 +01:00
jon 4a4c723c89 Fixed set_pen() 2022-07-26 05:10:07 +01:00
jon 2f5e3235e6 Add missing pen type enumeration value 2022-07-26 05:08:12 +01:00
jon 364994fc64 Added missing entry to cmake file 2022-07-26 05:06:06 +01:00
jon 6ab9c8b1c7 Added RGB88 pen type 2022-07-26 04:55:32 +01:00
Philip Howard 33b2c3908d
Merge pull request #441 from pimoroni/patch-picographics-docs
PicoGraphics: Update C++ docs.
2022-07-15 13:40:23 +01:00
Phil Howard f8e751ebff PicoGraphics: Fix 3Bit mode dithering for Inky Frame. 2022-07-13 14:30:14 +01:00
Phil Howard 9dfc8a065c PicoGraphics: Update C++ docs. 2022-07-11 15:56:15 +01:00
Pete Favelle 1b36899789 Missed one! 2022-07-09 16:57:35 +01:00
Pete Favelle cba2543d82 Corrected some confusing typos 2022-07-09 16:51:49 +01:00