Thread Rating:
  • 1 Vote(s) - 4 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Falling snow animated Scheme Script for Gimp
#1
Hello,  Smile

I'm a french guy, newly registered on the website.
I have finished today a Scheme script to make a 25 frames animation with falling snow effect :

The Falling snow script in a Zip file

[Image: FallingSnowWindow.jpg]

Exemple with the default parameters below:

[Image: snowDefaultParameters.gif]

With flakes Opacity on 70/100 :

[Image: snowOpacity70.gif]

Another exemple with first flakes size 1 and 7 layers of flakes :

[Image: snow7layers.gif]

With difference size between two layers set on level 2 instead of 1 in previous exemples :

[Image: snowDifferenceLevel2.gif]

With Wind force = 1 :

[Image: snowWindSmall.gif]

With Wind force = 2 :

[Image: snowWindMedium.gif]

With Wind force = 3 :

[Image: snowWindStrong.gif]

Wind force can be set in the other direction using -1 -2 and -3 values.

Falling snow effect can also be applied on selected parts, and you can use special lightning effects using layers mode and opacity.
Animation display automatically open in the end of script to show what it looks.

Tell me what you think about this script, and if i can better it.

Good test.  Wink
@+++
Reply
#2
Very nice, especially when the snow falls down slow.
Reply
#3
(04-03-2020, 02:12 PM)dinasset Wrote: Very nice, especially when the snow falls down slow.

Thanks.

Delay for all frames can be set from 40 to 100 ms.

Best regards. Smile
@+++
Reply
#4
Hello, Smile

Now a new version of the Falling snow script, with a lot of new features :

Download the file : falling-snow-animV2.zip

Parameters allow to choose :
- frames number in the animation : 5 to 50
- delay between two frames : 40 to 100 ms
- number of flakes layers : 1 to 10
- first size of snow flakes : 1 to 10
- size difference between two layers : 1 or 2
- brush rotation : left or no or right
- direction and force of wind : -3 to 3
- blur level applied on snow layer : 0 to 5
- rainy blur effect level : 0 to 20
- opacity of snow flakes : 1 to 100
- snow flakes layer display mode : 28 modes

To create a windy rain using 5 frames, or peacefull falling snow on 50 frames, have fun with all the combinations proposed.

Enjoy. Wink
@+++
Reply
#5
Hello, Smile

After cleaning-up the code, here is the last version of Falling snow script

Download the file : falling-snow-animV3.zip

Good game. Wink
@+++
Reply
#6
Hello, Smile

Download the File : falling-snow-animV4.zip

A lot of work last days on the script to propose you more features :

- frames number in the animation : 5 to 50
- delay between two frames : 40 to 100 ms
- number of flakes layers : 1 to 15
- first size of snow flakes : 1 to 15
- size difference between two layers : 1 or 2
- brush name : Enter name text
- brush color : Color box
- brush rotation : left...no...right
- direction and force of wind : -3 to 3
- blur level applied on snow layer : 0 to 5
- rainy blur effect level : 0 to 30
- rainy blur effect angle : -90...vertical...90
- opacity of snow flakes : 1 to 100
- snow flakes layer display mode : 28 modes
- harden the layers of flakes : TRUE or FALSE
- check animation window open at end : TRUE or FALSE

Yes... now you can choose if the animation window open at end :

[Image: FallingSnowWindow.jpg]

And the color of what is falling :

[Image: fallingLeaves.gif]

As the script use the brush tool to draw, you can also play with the dynamics setting in tool...
"Perpective" is used in the previous animation.

The rainy blur is longer than previous and you can adapt the angle of blur.
For example :
- wind force 1 set 45°... or -45° for wind -1
- wind force 2 set 63°... or -63° for wind -2
- wind force 3 set 71° ... or -71° for wind -3

The little bug called "I don't want to be saved like that" is now fixed strongly... Wink

Good game. Wink
@+++
Reply
#7
(04-07-2020, 11:20 AM)JimmyMarco Wrote: Hello, Smile

Download the File : falling-snow-animV4.zip

A lot of work last days on the script to propose you more features :

- frames number in the animation : 5 to 50
- delay between two frames : 40 to 100 ms
- number of flakes layers : 1 to 15
- first size of snow flakes : 1 to 15
- size difference between two layers : 1 or 2
- brush name : Enter name text
- brush color : Color box
- brush rotation : left...no...right
- direction and force of wind : -3 to 3
- blur level applied on snow layer : 0 to 5
- rainy blur effect level : 0 to 30
- rainy blur effect angle : -90...vertical...90
- opacity of snow flakes : 1 to 100
- snow flakes layer display mode : 28 modes
- harden the layers of flakes : TRUE or FALSE
- check animation window open at end : TRUE or FALSE

Yes... now you can choose if the animation window open at end :

[Image: FallingSnowWindow.jpg]

And the color of what is falling :

[Image: fallingLeaves.gif]

As the script use the brush tool to draw, you can also play with the dynamics setting in tool...
"Perpective" is used in the previous animation.

The rainy blur is longer than previous and you can adapt the angle of blur.
For example :
- wind force 1 set 45°... or -45° for wind -1
- wind force 2 set 63°... or -63° for wind -2
- wind force 3 set 71° ... or -71° for wind -3

The little bug called "I don't want to be saved like that" is now fixed strongly... Wink

Good game. Wink
@+++




Very nice script. I was using FencePost animated scrip, but this one look a little more realistic. Thank you for sharing, JimmyMarco!
Reply
#8
Hello, Smile

I worked hard last days to provide the final version of the script.

Objectives :
- add the selection of brush angle, from -180 to 180
- speed up the drawing
- fixe all bugs... yes there were many bugs

Very difficult and ... mission complete now...

Download the file : falling-snow-animV5.zip

[Image: FallingSnowWindow.jpg]

Left angle 27° combine with left wind -2 and No rotation brush :

[Image: Wilber01.gif]

Left angle 60° combine with left wind -2 and left rotation :

[Image: Wilber02.gif]

What do you think about my next idea... translate this script is a Python Plugin ?
Is it difficult to program in Python after Scheme ?
Should it be faster in Python ?
How can i do that ?

I'm waiting your good advices. Smile
@+++
Reply
#9
Is it difficult to program in Python after Scheme ?

No. In general Python is considered easier to use than Script-fu. It is taught as a first programing languages in many places(*). You also get the whole power of Python (Script-fu is not really a full Scheme environment...)

Should it be faster in Python ?

If you are talking about the execution speed, likely not. Script-fu or Python are just glue been Gimp function calls that do all the grunt work. But writing the code in Python is likely going to be faster.

How can i do that ?

With a decent programmer's editor. If you need examples, see here. I you have questions ask here.


(*) In France, in Math Sup/Math Spé. Conversely, at the Paris University, they teach Scheme during the first year, and it is considered a form of hazing.
Reply
#10
Hello, Smile

I thought the previous version of script was the final... and nooo...
There was a big bad bug hidden in the lines and i had to chase it.

Now, i'm sure, it's the final fantasy Falling snow (or other brush) script Mark VI.

Download the file : falling-snow-animV6.zip

Thanks for your reply Ofnuts... your answers and links are very useful.

I'll try just to see what Python Plugin looks like and how it's faster than Scheme.

Have fun Smile
@+++
Reply


Forum Jump: