HOME | DD

fence-post — GIMP Spinning Cube Script by-nc-sa

Published: 2008-01-08 16:05:47 +0000 UTC; Views: 20190; Favourites: 31; Downloads: 6360
Redirect to original
Description EDIT October 9, 2008: Updated script to work in GIMP 2.6 (the newest stable version.) If you have a previous version of this script, please delete it to avoid conflicts.

Let me know if you have any trouble with it.


This is something I've wanted to do for a LONG time and now that I understand scripting a bit more, was finally able to get this finished! I've taken the default GIMP Spinning Globe Script and modified it to map a single layer onto a rotating cube. I've added the option to set the speed and adjust the size of the cube, but the default cube size is pretty good. You can't go much higher in size than the default because if I allow you to make it too much larger, it won't fit in the current window size (I *could* implement an option to resize the frame to allow for a larger cube, but that's not planned for the time being.)

Click on the Download link to open the script.

Save it to your GIMP scripts folder (ie....Crogram FilesGIMP-2.Xsharegimp2.0scripts) and then go to Filters > Script-Fu > Refresh Scripts and it will appear in the main image window under Filters Menu > Animation > Spinning Cube... (Thanks to circledancer at gimptalk.com for testing this out in GIMP 2.2. It works fine, with no modifications.)

The script defaults to setting the x-angle to 30 degrees so the cube is tilted slightly towards the viewer. Later, I will add an option to allow the user to change this setting....easy enough to do, but I was just being lazy!

NOTE: Depending on your computer, this script may take awhile to run. My home computer generated the animation with 10 frames in about 5 minutes....but it took about 20 minutes on another machine that is much newer and has more memory. So, I recommend you try this out with just a few frames at first to see how your machine responds. Maybe this is why the script was never written before!

Future goals:

Allow for "predictable", simultaneous rotation on all 3 axis. Right now, I can't figure this out.
Allow for mapping different images to each face.

Let me know how it works for you or if you have any problems with it. Suggestions for improvement are always welcome!

Art
Related content
Comments: 24

adnegel [2012-01-20 20:55:10 +0000 UTC]

se podria aser el cubo con diferentes imagenes a los lados?

👍: 0 ⏩: 0

ilomo [2011-07-01 15:18:19 +0000 UTC]

thx

👍: 0 ⏩: 0

ilomo [2011-07-01 15:18:12 +0000 UTC]

thx

👍: 0 ⏩: 0

Neopong13 [2009-12-18 23:11:07 +0000 UTC]

Sorry but when i click download all it gives me is the HTML.
What do i do?

👍: 0 ⏩: 0

nevit [2009-11-30 16:05:53 +0000 UTC]

Nice script. It would be nice to increase the max possible frame count to more than 20 for a smoother animation. I guess it is in the line SF-ADJUSTMENT "Frames" '(10 3 20 1 10 0 1) but do not know how to modify it

👍: 0 ⏩: 1

fence-post In reply to nevit [2009-11-30 16:14:14 +0000 UTC]

You are correct about the SF-ADJUSTMENT line and it's an easy fix. See the value of "20"? Replace 20 with any number you wish. Save the change and refresh your scripts and it will give you that option.

I'll send you some scripting tutorial information tonight when I get home.

Art

👍: 0 ⏩: 1

nevit In reply to fence-post [2009-11-30 19:17:44 +0000 UTC]

Thank you... it worked...

👍: 0 ⏩: 0

Horsemad1996 [2008-07-13 15:16:17 +0000 UTC]

O.K feeling stupid again but how do you put those into gimp, I know how to download brushes but it just throws up a load of text? What do I do?

Thanks

👍: 0 ⏩: 1

fence-post In reply to Horsemad1996 [2008-08-03 19:30:55 +0000 UTC]

The instructions are in the deviation description. The text that appears IS the script.

Art

👍: 0 ⏩: 0

geminigriffin [2008-06-13 10:39:05 +0000 UTC]

I see you took my box out of the water and made it spin. Cool! I want to try this. I have a picture manipulation that has a box like that. I thought it was funny. But I know you just used GIMP after all it is a box and if you use simular colors it is going to look like any other box. hee,hee. Well Can't wait to try this. I just started to use my GIMP more lately so I will be trying this out.

Take Care

👍: 0 ⏩: 2

geminigriffin In reply to geminigriffin [2008-06-17 10:08:32 +0000 UTC]

Well I downloaded the script and put it away and it worked but it took 3 hours for my box to render. I guess something needs adjusting in the script but since I don't write scripts I wouldn't know what. But it is a good one just takes too long for my computer. But it was fun. If you ever get that fluke fixed where it runs slow on some computers let me know I want that script. I now have a spinning snowflake box in my gallery. But thanks for the script. I love the results.

Take Care

👍: 0 ⏩: 1

geminigriffin In reply to geminigriffin [2008-06-18 10:05:25 +0000 UTC]

It kept saying my file size was too large when I put this in. I made it small so that isn't it. What else can I do to cut the file size down in this. Or is that just weird.

Take Care

👍: 0 ⏩: 0

fence-post In reply to geminigriffin [2008-06-16 23:42:35 +0000 UTC]

Cool! Let me know if you run into any snags!

Art

👍: 0 ⏩: 0

barn9 [2008-01-13 04:44:21 +0000 UTC]

Thanks Art! One question, is it possible to slow down the spin rate?

👍: 0 ⏩: 1

fence-post In reply to barn9 [2008-01-15 02:17:35 +0000 UTC]

Sure...it's pretty simple. If you're wanting to do it when you first run the script, you can set the speed there. Just increase the number there.

If you're wanting to do it on an animation you've already created you can double click on the layer name and increase the number next to "ms". That's the number of milliseconds that a particular layer is shown before moving on to the next one. I believe in this version of GIMP, you have to hit the Enter key to get it to stay like that.

If you don't want to do it manually, download this script ([link] ) and let it do it for you. The script can be found under the Animations Menu (just like the cube script) and is simply called "Settings..." I think you'll only need to increase the number.

Let me know if you need additional help.

Art

👍: 0 ⏩: 1

barn9 In reply to fence-post [2008-01-15 02:35:32 +0000 UTC]

OK, thanks again Art, you are a wealth of info for us rookies, and I for one am really glad you are always willing to help!

👍: 0 ⏩: 1

fence-post In reply to barn9 [2008-01-15 13:54:44 +0000 UTC]

Not a problem. Glad to be of help!

Art

👍: 0 ⏩: 0

a2j3 [2008-01-08 21:47:15 +0000 UTC]

Looks awesome fence. Will post my results.


Jo

👍: 0 ⏩: 1

fence-post In reply to a2j3 [2008-02-13 18:40:18 +0000 UTC]

Thanks, Jo!

👍: 0 ⏩: 0

ChainLightningStrike [2008-01-08 20:58:53 +0000 UTC]

Tis Brill Art
I gave it a run for a bit of fun, The results it produces are great
Still it *did* take a while on my machine, but thats nothing new for me, mines a slow old beast.
Cheers for another brilliant script

Dave

👍: 0 ⏩: 1

fence-post In reply to ChainLightningStrike [2008-02-13 18:40:30 +0000 UTC]

Glad you like it! Thanks!

Art

👍: 0 ⏩: 0

gatogirl12345 [2008-01-08 18:17:03 +0000 UTC]

I should try this out!

👍: 0 ⏩: 1

fence-post In reply to gatogirl12345 [2008-02-13 18:41:05 +0000 UTC]

Let me know if you have any trouble with it!

Art

👍: 0 ⏩: 1

gatogirl12345 In reply to fence-post [2008-02-13 18:56:33 +0000 UTC]

No prob!

👍: 0 ⏩: 0