Abstract
With the refactoring spirit of Inkscape 0.47 in mind, I'd like to work on delegating Inkscape's math needs to lib2geom. The special goal is to convert Inkscape's internal representation of paths to a lib2geom type.
The integration of lib2geom is a big task, therefore I propose a team effort.
Name
Johan Engelen
Project title
Lib2geom integration
Benefits to Inkscape:
I think it would be beneficial for Inkscape to use lib2geom (2geom), because it makes the math code better maintainable. Already LPEs profit hugely from the ease and power of using lib2geom.
Deliverables
1. internal representation of paths as a 2geom type 2. conversion methods between current path type and new 2geom type, to use by methods that have not been converted to 2geom calls 3. implementation of test methods to ascertain and to prohibit regressions 4. Team work to move as much as possible of Inkscape to 2geom calls.
Project details
I think it is not possible to completely change all math to lib2geom within one GSoC project. I will try to get as far as I can, but I do have one specific goal: the internal representation of paths should become a 2geom type. This way, all path operations can be transformed to 2geom. First, 'perfect' conversion methods between the current representation and 2geom type will be made. Then, step by step, all path operations can easily be recoded to use this conversion methods first, then later on transformed completely to solely use 2geom calls. The perfect-ness of the conversion method will be proven by making test functions. More test functions will have to be written for large non-trivial functions that are converted, to decrease the possibility of regressions.
I propose to use 2geom's std::vectorGeom::Path as the new path representation type. I think this type already contains all functionality that the current type has; missing functionality must be implemented in 2geom. There already exist tried and proven 2geom methods that convert SVG pathstring to std::vectorGeom::Path and via versa (LPE use them already).
Apart from converting the internal representation, I also want to work on refactoring other parts of Inkscape to only use 2geom calls for math. E.g. snapping, tools, and transformations. (this largely means converting the over 4k occurances of NR::Point and NR::Matrix combined to their 2geom equivalents.)
I want to emphasize that I'd like to work on integrating lib2geom as a team. The internal representation is my personal goal, the other student(s) that might work on integration as well may have his/her own goal; but I think the motivation that comes from seeing more and more parts of Inkscape using 2geom really helps conquer the big heap of work that awaits us. Especially I want to mention Michael Sloan of lib2geom, who has shown great abilities by implementing boolean ops in 2geom (almost complete). I think we can really use his expertise in creating 2geom functionality that is still missing, and I think he can benefit from my knowledge of Inkscape for his project goals. Although not explicitly called that way, I already did some small teamwork with Diederik on snapping and grids; which was highly motivating and resulted imho into something good. I feel integrating lib2geom is a great opportunity for me to try a large teamed effort in improving Inkscape.
About me
I am 24 years old and live in The Netherlands. I am an electrical engineering PhD student at the University of Twente (Netherlands). I've been programming for so long I forgot when I started; I've programmed in C++, C, Pascal, x86 assembly, PHP, Java and other languages. I'm mostly self-taught in these languages.
Inkscape is my first (and only) open-source experience, before that programming experience has been a private hobby (once together with a friend). A friend showed Inkscape to me as his drawing application and I was sold immediately. Coding for Inkscape started after two weeks with adding the "Save-a-copy" functionality, then, apart from many bug fixes, for as far as I can remember: new extension parameter types, on-canvas gradient editing, new grid framework and 3D axonometric grid, angled guidelines, on-canvas mask and clippath editing, and of course Live Path Effects (GSoC2007). See http://wiki.inkscape.org/wiki/index.php/GSOC2007_Live_path_effects_in_Inksca....
Work schedule
Being a PhD student in the Netherlands means I have to work during office hours and have no long summer vacation. Therefore I propose to work the same schedule as I did in last GSoC. As soon as I am accepted I will start working on my project, to compensate for the less than nominal available time during the 'official' working 2 month period of GSoC2008. I think my result of last year's GSoC project shows this works very well for me.
Other GSoC applications
I have not applied for any other GSoC project. I have no motivation to apply to other projects other than Inkscape's.
--------------------------------------------------
Thank you very much for reading the long text. Any comments, especially critique, are very welcome.
Kind regards, Johan