Winter's tale in your Android'e

    “Often the Snow Queen flies through the city streets at night and looks through the windows, that's why they are covered with frosty patterns, like flowers.”

    So begins the famous winter fairy tale, which I recently read, wrapped in a warm blanket, exactly the Catholic Christmas Eve. The idea that later visited me, as it turned out, was already somehow realized by someone. And still I wanted to do something that could please the child for the New 2013th, since the fireworks at the end of the world were ordered to live long.

    Therefore, I present to your attention Frosty Touch:

    From a developmental point of view, everything here would seem to be simple. There are 2 canvases on which the picture of the original is drawn and the second with the effect. The effect, on the other hand, is a few layer pictures that are necessary to create a more beautiful wipe than the one that we get in a dull way by changing the alpha channel value. So, at first I thought that drawing at once in three layers, changing the alpha of each to varying degrees would be difficult, because java android can not behave too jocularly. Nevertheless, after proper optimization, I was able to achieve not only a continuous line, but also “circle” drawing, as many “competitors” do, and a good speed. If you have questions, I will be happy to answer, write!

    I hope the applicationit will please even those who are in the south, and who have no snow right now, but a sleet of ice :)

    With the Coming, and for someone with the Coming, dear Habr!

    Also popular now: