[Digikam-devel] Re: how to properly store a curve in XML

Gilles Caulier caulier.gilles at gmail.com
Wed Nov 10 16:40:54 GMT 2010


2010/11/10 Johannes Wienke <jwienke at techfak.uni-bielefeld.de>:
> On 11/10/2010 03:42 PM, Marcel Wiesweg wrote:
>> when a curves filter is applied, we need to store the curves in the
>> FilterAction written to metadata.
>> Now, the problem is that the CurvesFilter has five polygon each holding
>> potentially 65536 values - this is not very suitable for writing to XML.
>>
>> I see two other places where a curve is saved:
>> - CurvesWidget::saveCurve
>> - ImageCurves::saveCurvesToGimpCurvesFile.
>>
>> Are digikam curves Bezier curves?

The curves can be designed dot by dot or with a Beziers curve, using
approximation.

>Then we could encode them in SVG style:
>> http://apike.ca/prog_svg_paths.html
>>
>> Which would be the best way to store curves efficiently and correctly?
>

Yes, it's a good solution. but in Beziers mode, only 16 dots are used
to draw curve. Why not to use these values as well ?

Gilles



More information about the Digikam-devel mailing list