RSS/Atom feed Twitter
Site is read-only, email is disabled

The Frosty Logo Script and the Sparkle Plug-in are Back in Action

This discussion is connected to the gimp-developer-list.gnome.org mailing list which is provided by the GIMP developers and not related to gimpusers.com.

This is a read-only list on gimpusers.com so this discussion thread is read-only, too.

1 of 1 message available
Toggle history

Please log in to manage your subscriptions.

The Frosty Logo Script and the Sparkle Plug-in are Back in Action Shlomi Fish 08 Jan 09:46
Shlomi Fish
2005-01-08 09:46:12 UTC (over 19 years ago)

The Frosty Logo Script and the Sparkle Plug-in are Back in Action

This bug:

http://bugzilla.gnome.org/show_bug.cgi?id=132145

Was present in the Bugzilla for a long time now. It was reported because the Frosty Logo script did not render correctly. Kevin Cozens discovered it was due to the Sparkle Plug-in. Eventually, I decided to resolve it. I did that by comparing the code (portion by portion and line by line) to the code in GIMP 1.2. As a result of this process, I found four regression bugs[1] that were fixed in this patch:

http://bugzilla.gnome.org/attachment.cgi?id=35345&action=view

However, there were still problems apparent. I temporarily hacked the code to settle both plug-ins on the same identical pseudo-random number generator, with the same seed, and compared the results. They were very different.

So I decided to add traces in the code to see where they were different. As I went to add some traces, I discovered another regression bug, very similar to another one I discovered previously, which I fixed. This seems to have corrected the problem altogether, but the results were still not identical.

I added more traces, enough to cause both dumps to become a 1.5 GB (no typo here) file, and then I discovered that a parameter passed to a function was different in the plug-ins. I found out that it was a bug, because the 4th byte (possibly alpha) of a color was not initialized. This bug was still present in gimp 1.2.x. I fixed this bug too, and afterwards the results were identical.

The patch with both of the newer fixes is this:

http://bugzilla.gnome.org/attachment.cgi?id=35501&action=view

In any case, I still noticed a problem. In the upper part of the image, the shadows had completely horizontal edges. I noticed that this problem still existed in GIMP 1.0.x (!), but it was still disturbing. After a lot of investigation, and trying to reduce the script to a minimum that still exhibits this problem, I found out the problem was because:

<<< I discovered that the problem with the shadow was due to the fact that the shadow was generated within the image boundaries and then the shadow layer was moved (= translated) by an offset which caused it to have horizontal edges at the top of the resultant image.

I prepared a patch to fix it. Sven told me to commit it to the CVS, which I did. I forgot to commit it to the GIMP 2.2 branch, which Sven was gracious enough to do late last night.

So now the sparkle plug-in is hopefully fully bug-free, and the Frosty logo is back in action. Happy sparkling!

Regards,

Shlomi Fish

[1] - Well, one of them was just a swapped order for fetching two consecutive random numbers from the random number generator, but that was revised too.

--------------------------------------------------------------------- Shlomi Fish shlomif@iglu.org.il Homepage: http://www.shlomifish.org/

Knuth is not God! It took him two days to build the Roman Empire.