]> git.imager.perl.org - imager.git/blob - TODO
more to do
[imager.git] / TODO
1                          *** TODO ***
2
3 Release Plans (subject to change)
4 -------------
5
6 brown-bag bugs may add intermediate releases.  The dates are goals,
7 not commitments.
8
9 0.46: (September 2005)
10
11 - check remaining memory allocation calls for integer overflows
12   http://rt.cpan.org/NoAuth/Bug.html?id=8213
13    - check *alloc() calls
14    - check llist_push() calls
15
16 - fix Imager::Color warning when $ENV{HOME} isn't set from
17   _get_gimp_color() (done)
18   http://rt.cpan.org/NoAuth/Bug.html?id=13143
19
20 - module version numbers (done)
21   http://rt.cpan.org/NoAuth/Bug.html?id=13047 
22
23 - allow limits to be set on the size of an image read from a file.  This is
24   to prevent an attacker supplying huge images that consume all of 
25   memory causing a denial of service attack. (done)
26
27 - implement gsamp()/gsampf()/plin() etc methods for those low level image
28   interfaces which don't yet have methods. (done)
29    - code (done)
30    - test (done)
31    - document (done)
32
33 - add Imager::Tutorial (see Tk::UserGuide for a structure) (done)
34   don't cover installation - belongs in README or INSTALL
35   it doesn't need to cover everything - read/write/create/simple drawing
36   and simple text - other stuff belongs in the cookbook or in sample code
37
38 - rename lib/Imager/Cookbook.pm to lib/Imager/Cookbook.pod (done)
39
40 - add 5 more recipes to Imager::Cookbook
41
42 - implement i_incomplete for png and gif files.
43
44 - documentation audit, check:
45   - every method has at least one example, but if the method is complex
46     (like transform2, to_paletted, string() for example) it should include 
47     a range of examples
48   - check each method description to ensure it's reasonably clear.
49   - check POD sections (SEE ALSO in particular)
50   - multiple examples for writing GIF images.
51   - name arguments and use those names in the documentation
52     http://nntp.perl.org/group/perl.perl5.porters/102434
53   (#1521, #5608, #8231, #11429, #13058)
54
55 - have $img->read() act like ($img) = Imager->read_multi() on GIFs
56
57 - figure out what the nearest_color filter does, and document it
58
59 - remove image.h dependency on t1lib.h (done)
60
61 - make sure dynfilt/Makefile.PL gets the same includes that
62   Makefile.PL does.
63
64 0.47:
65
66 - rework handling of antialiasing and other transparency against
67   transparent images
68
69   Places to check:
70    - text AA rendering
71    - AA line drawing
72    - anything that uses combine (fills in particular)
73    - image scaling? and matrix_transform()'s interpolation
74   http://rt.cpan.org/NoAuth/Bug.html?id=11972
75
76 0.48:
77
78 - fill out handling of large sample (16/double per sample) images
79   - filters
80   - rendering:
81     - lines
82     - text
83     - boxes
84     - polygons
85   - engines
86     - matrix transform
87     - transform()
88     - transform2()
89   - files:
90     - png
91     - tiff
92     - pnm
93
94 Speculation
95 -----------
96
97 Some of what's listed below has been implemented.
98
99 - should i_incomplete be optional?  ie. reading a short image results in
100   an error unless the user requests incomplete images.
101
102 Iolayer:
103 - Add scalar/mmap to iolayer
104 - Add close() code to iolayer for fakeseek sources.
105 - Merge callback interface into iolayer
106 - and raw
107 - Implment the maxread threshold (Indicates how much can
108   be read from a source before it stops reading from its
109   underlying source.  For making sure only the relevant
110   data is read from a socket for example. 
111
112 Enhanched internal structure:
113
114 MultiImage & metadata support:
115 - Figure what interface should be between C and perl?
116 - How to store data in the C interface for tags/metadata?
117   Support tiff's madness, i.e. tags and options.
118 - Error handling, make a general i_errstr object and arrange
119   such that each image has an i_errstr object to hold its
120   local errors?
121 - SEE design/represent.txt for proposed new structure and
122   interface design that takes these factors into account.
123 - define common i_* tags for specifying attribute common among images
124   like spatial resolution (implement for other image types, especially 
125   TIFF)  (Spatial resolution is supported for all types that support 
126   it - are there any other common properties we can add?)
127 - implement the i_incomplete tag for other formats  
128
129 New Features:
130 - Add mng support, pcx and aalib support.
131   - Windows icon files (.ico)
132   - ILBM (Amiga) images
133   - photoshop files (I think I've seen docs)
134   - XBM
135   - FITS
136   - WMF (extract bitmap data on read)
137   - gzip or bzip2 compressed raw
138   - postscript for output
139   - PAM file support (man pam in recent PNM tools)
140
141 - Transforms, interpolated multidimensional lookup tables.
142   Usefull for CMYK <-> RGB table lookup.
143
144 - advanced font layout (spacing, kerning, alignment) (Artur?)
145
146 - ways to check if characters are present in a font, eg. checking if
147   ligatures are present (done for FreeType2)
148
149 - font synthesis - synthesize a bold or slanted font from a normal font
150   (or even from an existing bold or slanted font)
151
152 - utf8 support for text output
153   (available for FT1, freetype2, should be easy for Win32)
154
155 - easy interfaces for text output:
156   - align text around point, including:
157     - left, center, right horizontal alignment
158     - top, center, baseline, bottom alignment
159     - choose whether to base alignment upon character cells or font 
160       metrics to avoid spacing problems between lines
161   - fill a box from text, with newline handling
162     - an option to just return the information that would be used to 
163       output the text, so it can be used for sizing calculations
164     - how much text fit in the box/how much space is left in the box
165   - fill a box with rich text (size and font changes)
166     - as above
167     - wrapping around boxes/images
168   - pod2Imager :)
169
170 - tools to get more information about fonts/characters:
171   - name of font "Arial Bold Italic" vs "arialbi.ttf"
172   - ABC widths for characters (currently the only way to get the C width 
173     for a character is to get the width with a following space and without
174     and then compare)
175   - character names
176
177 - encodings for text output (maybe using the Encode module to work 
178   between encodings)
179
180 - image rotation, 3 ways of doing rotation:
181   - rotation by shearing, which produces makes lengths in the image larger,
182     but could be useful
183   (2 of the 3 have been done)
184
185 - read_multi() needs to handle other multi-image types,
186    (handles TIFF and GIF)
187
188 - write_multi() to save other multi-image types, (handles TIFF and GIF)
189   - pnm binary formats support multiple images per file
190
191 - compose channels - build a new image based on channels from several
192   images
193
194 - arc outlines
195
196 - complex lines/curves:
197   - thick lines:
198     - dotted/dashed lines
199     - doubled lines?
200     - end-point controls (butt-end, square-end, round-end, pointy, arrows)
201   - brush-lines (as with the Gimp, or Photoshop)
202     - more complex with multiple strokes and various randomness as with
203       Fractal Design Painter (or later versions of Corel Photo Paint)
204   - complex line shapes:
205     - lines
206     - general curves (cubic or bezier, whichever is more general)
207     - easy access to general curves:
208       - points to make a nice curve from
209       - various circular curves (centre, radii, start/end angles, 
210         direction)
211   - Complex thick lines are probably more useful than brush-lines for 
212     the things I expect Imager to be used for.
213   - http://www.develop-help.com/imager/strokes.png (.jpg for smaller version)
214
215 - have Imager::Color{::Float}? use Graphics::ColorNames if present.
216
217 Clean up:
218 - Make sure everything is doable with the OO interface
219   i_flood_fill() for example.
220   - include low-level functions like gsamp() and so on
221
222 - Compile with memory debugging enabled and fix all leaks
223
224 - Add mycalloc() memory allocation wrappers.
225
226 - should we overload <=> or cmp for Imager::Color objects?
227   too many worms, leave it out
228
229 - should the interlace option for reading raw images have 
230   symbolic names in the OO interface?
231
232 - improve consistency in the interfaces, both in trying to use named
233   parameters where possible but also in using consistent names, eg.
234   (tx, ty) vs (left, top) in rubthrough() vs paste().  Do we want a (simple)
235   standard for this (suggested names)?  Remember to preserve the old 
236   interface where possible.
237
238 - try to clean up the inconsistencies between font types:
239   - utf8 (even if we just treat characters over 0xFF as missing for T1)
240     (done for FT2, FT1, T1)
241   - transformations (done for FT2)
242   - has_char() method (done for FT2, FT1, T1)
243
244 Format specific issues:
245 - provide patches for libgif and libungif that fix their bugs
246   and give a useful extension interface.  Probe for the 
247   installation of the patches in Makefile.PL to let gif.c
248   know what features it can use.
249
250 - Add options for pnm writer to save in any of the p1..P6
251   formats.  Even if the input has 1 channel, write 3 and such
252   cases.  Also allow ascii mode.  Need to be able to write 
253   pbm images which needs ties to the quantization code.
254
255 - save paletted images as paletted where that's supported.  Done
256   for gif/tga/bmp/tiff.  Not done for png yet.
257
258 - read other format paletted images as paletted images.  This has 
259   been done for gif/tga/bmp/tiff formats but not for png.
260
261 - read/write 16-bit/sample images as such for tiff
262
263 - read more metadata from images, esp tiff tags, EXIF format information 
264   from TIFF and JPEG.
265
266 - handle 16-bit/sample pgm/ppm files
267
268 - "jpeg lossless rotation" - directly manipulates the JPEG
269   representation to rotate, scale or in some limited cases, crop an
270   image.
271
272 Documentation:
273 - Add to the documentation
274 - Write a tutorial?
275 - sample code and Imager/Samples.pod describing them
276 - Imager/Cookbook.pod
277 - Write a guide to installing the helper libraries
278 - Go through the entire project and add comments in pod
279   so doco.perl can be used to read them.
280 - see the IRC log in design/doclayout.txt
281 - method index?
282 - concept index?
283
284 Build/configure:
285 - use prompt() (from ExtUtils::MakeMaker) for questions in Makefile.PL
286 - use the library's mechanism's to find the library if needed, for
287   example, freetype-config for FT2
288 - the freetype2 library is built as "freetype.lib" on Win32 and needs
289   to be renamed to be found by the configuration process and included
290   with -lfreetype.  Try to work around that.
291 - freetype2 and freetype1 tend to be installed in /usr/include/freetype2
292   and /usr/include/freetype directories, or similarly named (somedir/freetype
293   for example), instead of putting these directly into the search path
294   search for the freetype{2}?/someheader and then add the subdirectory if
295   we find the file in that directory.
296 - switch to Test::More
297 - change headers to use more unique re-include protection macros
298
299 Old release checklists
300 ----------------------
301
302 0.44: (december 2004)
303 - set i_format for every file type on read and test for it:
304   - bmp - done
305   - jpeg - done
306   - tiff - done
307   - tga - done
308   - rgb - no read function anyway
309   - png - done
310   - gif - done
311   - pnm - done
312   - raw - done
313 - check each file reader for possible integer overflows
314   - bmp - done
315   - tiff
316   - tga
317   - rgb
318   - png
319   - gif
320   - pnm
321 - check bmp code uses image data offset correctly - done
322 - check quant code for integer overflows - done
323 - check for old URLs (umich and imager.perl.org/~addi/...) - done
324
325 0.45: (march 2005?)
326 - resolve fills test failure under 5.8.6/darwin
327   http://www.nntp.perl.org/group/perl.cpan.testers/202802
328   add tests to check if the same problem occurs with other ?: operators
329 - stop tga_header_verify() from spewing junk to stdout (done)
330 - fix i_setcolors_p bug (done)
331 - audit pnm.c (done)
332 - audit tga.c (done)
333 - audit rgb.c and add tests
334 - add META.yml (bypass EU::MM's limited mechanism) (done)
335 - implement i_incomplete for bmp files
336 - check if freetype 2 is faster/slower than freetype 1 with Imager's glyph
337   caching.  If FT1 is faster, add caching as a TODO for FT2.
338 - add XS for i_tags_get_string() and test it.  It has an apparent problem
339   in C<< sprintf(value, "%d", entry->data); >> since data is a pointer
340   (done)
341 - test and fix problem with fallback value for 
342   Imager::Font::BBox->advance_width. (done)
343 - check handling of string() method align parameter. (done, fixed)
344 - i_tt_bbox_inst in font.c uses variable i without ever setting it. (fixed)
345 - add sample CGI that handles an uploaded image (done)
346 - examples for fountain filter in Imager::Filters (done)
347 - allow Imager::Fountain to take color descriptions (eg. blue, FF000)
348   instead of color objects for c0 and c1 (done)
349 - support newer GIMP gradient files with the Name line (done)
350 - provide access to right-side bearing information from the bounding box
351   function (done for all drivers)
352 - capture TIFF read warnings (i_warnings tag?) (done)
353 - Imager::Matrix2d rotate method only applies offset if both x and y
354   are non-zero, it should do it if either is non-zero (done)
355 - add Imager::Cookbook with at least 5 recipes (done)
356 - store floating point tags in an appropriate precision (done)
357 - allow image creation to fail on malloc() failure for the image data
358   rather than aborting.  The current behaviour could be a denial of
359   service attack.  This has limited utility because of the way memory
360   over commitment works on Linux (done but reverted)
361 - eliminate unused variable warning (especially the RETVAL ones in Imager.xs)
362   (done)
363 - handle probing for libraries better (use pkg-config or I<library>-config
364   where possible (freetype2 and libpng)) (done)
365 - add concept index to Imager.pm pod (done, still working it)
366 - replace testimg/penguin-base.ppm with a smaller image (done)
367 - add a sample CGI HTML and image generation scripts that work together,
368   with appropriate security management (done)
369