|
1 | | -import bumpy, chroma, flatty/binny, os, pixie/common, pixie/contexts, |
2 | | - pixie/fileformats/bmp, pixie/fileformats/gif, pixie/fileformats/jpeg, |
3 | | - pixie/fileformats/png, pixie/fileformats/ppm, pixie/fileformats/qoi, |
4 | | - pixie/fileformats/svg, pixie/fonts, pixie/images, pixie/internal, |
5 | | - pixie/paints, pixie/paths, strutils, vmath |
| 1 | +import |
| 2 | + std/[os, strutils], |
| 3 | + bumpy, chroma, flatty/binny, vmath, |
| 4 | + pixie/[common, contexts, fonts, imagebase64, images, internal, paints, paths], |
| 5 | + pixie/fileformats/[bmp, gif, jpeg, png, ppm, qoi, svg] |
6 | 6 |
|
7 | | -export bumpy, chroma, common, contexts, fonts, images, paints, paths, vmath |
| 7 | +export bumpy, chroma, common, contexts, fonts, imagebase64, images, paints, |
| 8 | + paths, vmath |
8 | 9 |
|
9 | 10 | type |
10 | 11 | FileFormat* = enum |
@@ -85,7 +86,9 @@ proc readImage*(filePath: string): Image {.inline, raises: [PixieError].} = |
85 | 86 | except IOError as e: |
86 | 87 | raise newException(PixieError, e.msg, e) |
87 | 88 |
|
88 | | -proc encodeImage*(image: Image, fileFormat: FileFormat): string {.raises: [PixieError].} = |
| 89 | +proc encodeImage*( |
| 90 | + image: Image, fileFormat: FileFormat |
| 91 | +): string {.raises: [PixieError].} = |
89 | 92 | ## Encodes an image into memory. |
90 | 93 | case fileFormat: |
91 | 94 | of PngFormat: |
|
0 commit comments