Skip to content

Tag: apple

PictSharp Updated

Get it from Github

I recently returned to a project I first started in 2017, PictSharp.

PictSharp is a C# native library for encoding bitmap images to to Apple's legacy PICT Format. I originally started it for the GopherServer project, as I wanted a way to convert modern images for old Macs which did not depend on external applications (both on the server and the client).

I revisted it to add support for .NET Core, but in the process ended up implementing support for 1-8bpp support, non-power of two image sizes, support for ImageSharp, as well as learning how GitHub actions work and publishing my first (public) nuget package!

While I suspect the number of people who want to create PICT images in 2022 is fairly small, it may assist those who want to learn about legacy formats or need to support older systems and formats (eg RTF which supports MacPict as one of the original v1 image formats).


  • Implemented entirely in C# code. No native dependencies.
  • Supports .NET Framework 4.6.1+, .NET Core 3.1 and runtimes compatible with .NET Standard 2.0
  • Writes PICT 2.0 Images (so should work on a Mac II onwards with Color QuickDraw)
  • Supports 1bpp, 2bpp, 4bpp, 8bpp and 32bpp image encoding, with PackBits compression
  • Extensions available for ImageSharp and System.Drawing.Bitmap

What's still to be done?

Really just 16bpp support, but it'll probably be another 5 years until I get around to it. 16bpp is supported in PICT, but uses a different compression method to PackBits. Instead of working on individual bytes, 16bpp images are compressed by word (2 byte values).

  • More compression options (disabling compression, JPEG, etc)
  • A decoder
Leave a Comment