Newest Articles

MegaCombs
Flash Media Player
XML Driven Pie Chart
Base Defender
Hangman Game
8 Ball Pool


Popular Articles

True Fullscreen Flash Mode
Image Slider
Mp3 Player with XML Playlist
FLV Player
Catapult Game
3d Rotating Image Cube


Random Articles

Page Flipper
XML Driven Pie Chart
Gilbert
Gravitas
Hangman Game
Infinitely Zooming Image


Links

Foundation-Flash
MickM
TutorialQuest
Tutorialsphere.com - Free Online Tutorials
Newgrounds
TWiT
Link to SwfSpot
Swf Spot



rss feed

3d Rotating Image Cube

3d Rotating Image Cube
AddThis Social Bookmark Button
Description: 6 images are grabbed through GET parameters and scaled to create a cube.
Author: John Bezanis
Added: April 5th 2008
Version: Flash 8

This script grabs 6 images and creates a 3d cube which rotates according to the mouse position. It accepts the images through GET parameters. With this form, the user can specify the flash applet height and width, as well as the size of the cube itself. If your website receives a substantial amount of hits, please host the swf file on your own server.
Cube Parameters
Image 1:
Image 2:
Image 3:
Image 4:
Image 5:
Image 6:
Flash Applet Width:
Flash Applet Height:
Cube Size:

Code to copy and paste on your website:


Download the files below:

Download Source File
Download the built 3d Cube
Comments
Damn thats awesome! Great job!
April 6th 2008 12:04PM   -   josh
Is it possible to get this with a different background colour? The white does not fit into my website.
April 9th 2008 05:04PM   -   James
Sure James. Just insert <param name="wmode" value="transparent"> right before </object> and it will make the background transparent. Example:
http://www.bezzmedia.com/stuff/transparent.htm
April 9th 2008 07:04PM   -   John
hi this is cool but how can i turn it into a swf. file with my pics and caption? can u be able to teach me. cuz i downloaded the source code in fla. but nothing comes out what is there for me to do in order to get pictures to come out?? thanks..
April 18th 2008 10:04PM   -   benny
i am looking to put the code above into the style below...is there a way to do that ?? just incase someone does not have a browser that supports flash ????

<script type="text/javascript">
// <![CDATA[
var fo = new FlashObject("http://www.bezzmedia.com/swfspot/resources/45-picturecube.swf?im0=http://www.bezzmedia.com/swfspot/resources/45-im0.jpg&amp;im1=http://www.bezzmedia.com/swfspot/resources/45-im1.jpg&amp;im2=http://www.bezzmedia.com/swfspot/resources/45-im2.jpg&amp;im3=http://www.bezzmedia.com/swfspot/resources/45-im3.jpg&amp;im4=http://www.bezzmedia.com/swfspot/resources/45-im4.jpg&amp;im5=http://www.bezzmedia.com/swfspot/resources/45-im5.jpg&amp;cubesize=100" width="250" height="150");
fo.write("flashcontent");
// ]]>
</script></td>
April 21st 2008 02:04PM   -   mike
I'm trying to reduce the speed of rotation but what I"m doing isn't effective. Any tips?
May 14th 2008 04:05PM   -   Donna
may be a daft question, but is there anyway to remove the shadow on the cube? thanks
May 21st 2008 05:05AM   -   John E
Nice! But if i want to place the cube to the right in the movie (now its allways centerd). How do i do that? And is it possible to change the code so it get a movieclip in stead of an jpg?
May 22nd 2008 11:05AM   -   Shine
Not bad, but how did you forget to utilize forceSmoothing???
May 24th 2008 09:05AM   -   Justin Guptell
Good suggestion Justin. There is however a big performance issue when using forceSmoothing.
May 24th 2008 11:05PM   -   John
Hi! I found the code for center cube, one problem solved.
Is it possible to change the code so it get a movieclip in stead of an jpg?
May 26th 2008 05:05AM   -   Shine
Hello friends ;
How can i call images from xml ?Thanks
May 27th 2008 08:05PM   -   James
I love this, thank you for sharing. :D

As a complete Flash noob, erm.. is there a way I can add links to the pix, please?

frivvy. XXXx
June 7th 2008 05:06AM   -   frivvy
I can't seem to download the "Download the built 3d Cube" file?
I'm just led to a blank screen.
Regardless of that - amazing work!
June 10th 2008 09:06AM   -   Bonzo
I downloaded the source code for this and as a newbie I can't seem to figure out how to get images to appear on the 3D cube. Can you please help a newbie out!!!
June 10th 2008 01:06PM   -   vomelaaw
Hi John. Great job! It seems I have the same problem as benny. I cant figure out where to insert the code above to get my own pictures to apear in the cube?
June 11th 2008 11:06AM   -   Kasper
Is it possible to call a image, simular to clicking on the image from an external javascript? I want to bring up the photo on a mouseover elsewhere in the page. Also on mouseoff resume the rotation
June 15th 2008 08:06AM   -   Maxwell Smart
It works perfectly !!
Thanks for your job.
June 23rd 2008 04:06AM   -   Alex
I cannot download the built 3D qube?
June 23rd 2008 05:06PM   -   Franklyn
Franklyn - right click -> save target as.
June 23rd 2008 05:06PM   -   John
Thanx John
June 24th 2008 02:06PM   -   Franklyn
Hi...how do I host this on my own server? I have the cube working but it relies on your server.
June 28th 2008 05:06AM   -   Franklyn
Hi...I am new to all this never done flash before and am grateful for your genius..I have put your cube on my site (see links page)
the next bit is how do I change your images into mine ?

ArunMChandran@aol.com
July 7th 2008 04:07PM   -   Arun Chandran
Hi John,
Well impressed but are you going to answer the question that almost everyone wants to know? that is of course how do we get our pics on the cube? I will of course host the swf file on my own server.
Thank you.
July 27th 2008 10:07AM   -   Angelo
superb, I soon realised why the white space, you just need to upload the generated swf (renamed below) to your own server ( save this guy's bandwidth ) and change the links to ie ..."http://www.yourdomain.com/cube.swf?im0=http://www.yourdomain.com/images/1.jpg....etc, nice work and cheers....
August 6th 2008 03:08PM   -   sam
Exactly what I was looking for... You are the shiz
August 18th 2008 02:08AM   -   T
Hi John

I think cube is wonderful. I know it's a give away, but please, please, tell me how can I remove the wording and link
"3D cube by SWF Spot" which is visible and accessible whenever I right click the cube? Please reply to this John, I just can't figure it out.

Regards

Craig
August 20th 2008 07:08AM   -   Craig Danta
Awesome, thanks for sharing
August 22nd 2008 12:08AM   -   Filas
can u try and make it opaque... like transparent to merge in our layout background or its really beautiful....
August 29th 2008 02:08PM   -   scorphees
hi john, your cube is great , it has an hypnotic effect . but i have problems to see the cube in IE 6 , it only shows a white box. How do i need in IE to see properly ?
Thanks! Great job!
September 4th 2008 03:09PM   -   Gustavo
How do I provide url to this cube.
September 10th 2008 12:09PM   -   Satish
HI there


this is such a great cube....!!!! great job!!!!

any way one can make the sides function as buttons to place as navigation in a flash site....that means to say that if I click on a side it goes to a frame label in my site? If so...how can i do that? Please help...

thanks a bunch
September 10th 2008 02:09PM   -   sumari van Dyk
I can get the cube to display properly (locally hosted, with my own pics) but I can not seem to get it to display in a frame (within my website). It will only display properly in a full window. Any ideas as to why this might be and how to fix it? Thanks.
September 10th 2008 09:09PM   -   jack
Hi john, your works is so exilent & i m also intrested to learn it bcz i m also a designer...

& plz tell me about - how to do it??
October 8th 2008 03:10AM   -   Sunny
Hi John,

Thank you for the great work you have done on this 3d rotating cube! I have been able to get this to work displaying pictures of my own choosing hosted from your server. Could you please provide some further instructions on how to host this on my own server? I downloaded the source file that you provided but am having some difficulty with this step.

Thanks so much!! :-)
October 15th 2008 12:10PM   -   Mike
I actually just figured it out. Does any one know if it is possible to have video links instead of pictures display? Great work!!!
October 16th 2008 02:10AM   -   Mike
wow ! amazing john ! thank you !
October 28th 2008 12:10PM   -   absolutebeginner66
Great code thanks.
But how do I get this thing to also work in any version of netscape?
November 13th 2008 01:11AM   -    Maxwell Smart
Could one alter this great design so it only rotates 4 faces on the Y axis, w/hyperlinks on each face?
November 23rd 2008 08:11PM   -   Brandon
I cannot get the swf file to host on my own server no matter what I try! I have downloaded it several times, have tried remaking it from the fla file, but the only way it will run is linked to the bezzmedia site. I can set it to use the images from my own site but not the swf. Any ideas from anyone?
November 24th 2008 05:11PM   -   Bill
Great,Can we control the speed
November 25th 2008 02:11AM   -   Rosemary
how indentify the side of cube user clicked? - i want to make this cube as 6 buttons navigator, so where i should place my scripts?
thanks,
not pro in flash scripting..
November 28th 2008 03:11AM   -   Arunas
thanks for this.

i don't want to add image for cube, i wish to add swf file or movie clip. have anyway for that ? if have then please let me know. i'm not pro. in flash.. so if need action script thing then post here please..

thanks again
December 9th 2008 12:12AM   -   pagol
To make work off your server, make sure you upload 6 pictures (John's or yours) as well as the .swf file. You can get all the files above. To get the .swf file, right click it and select "save As" from the menu and save it to your hard drive. You only need the .fla file if you want to modify the cube in a flash program. You will need an HTML page that loads everything (using the outline script above. Make sure you change the file locations and or names to match your design and it will work perfectly. If you have a problem, re-check you file names and verify that all files are present in the directory you have named in the HTML file. Works like a charm. Great work John and thanks
December 20th 2008 11:12PM   -   Michael
uhh...Jhon? you, uh, gonna answer anyones question anytime soon??
January 16th 2009 07:01AM   -   Raghib
I cant get My Personal Pictures to work on in the cube. Could i get some help
January 25th 2009 11:01AM   -   Mike
Is it possible to slow down the rotation of the cube when the user isn't mousing over? Right now it seems to rotate very quickly. Any help would be greatly appreciated. Thanks!
January 26th 2009 02:01PM   -   Sierra
Hello, do I have a problem of display under Internet to explore 6 how I must make???
January 27th 2009 11:01AM   -   Lylou
Although it doesn't seem as though there has been any response for this lately, I'll jump-

I'm trying to use the cube in a non-web environment (as a tool for showing drafts of my work, possibly in a presentation environment such as ppt, pdf or even flash presentation). I have CS3 Flash and a very basic knowledge of flash (I'm a graphic designer). I can't figure out where to insert code to link my pictures in the .fla to make them appear in the .swf in a non-web environment.
March 9th 2009 03:03PM   -   RCain
Oh, and it's a Killer Cube. Your Flash talent is only exceeded by your math genius:) Also, I understand if you've gone commercial and are now only selling your code/expertise, but I may have to ante up out of my own pocket for this one since it's been driving me mad for a week.
March 9th 2009 03:03PM   -   Rcain
great work...amazing
April 9th 2009 04:04PM   -   nv
I built this cube with my own pictures in l996 On Geocities when they offered it. Wish I could remember how I did it.
May 10th 2009 10:05PM   -   Janice
Nice Cube you got there.

So i have a problem, i have a rubiks cube in Flash and i want to upload my images on the sides like it's in this cube but i really don't know how to make it.

Could somebody help me?
May 12th 2009 07:05AM   -   Michael
Please, please, teach me how to make a http link when I click on one of the images.
June 2nd 2009 01:06PM   -   rico
Any idea how I can embed this into a SWiSHmax animation please?
June 9th 2009 07:06AM   -   Rob
Great Job!
June 9th 2009 10:06PM   -   Suliazanna
Hi,
The cube works fine in i.e 7 but not in any other browsers. Can anyone tell me how to make the cube cross-browser compliant?

Many THanks

Chaz
June 19th 2009 09:06AM   -   Sharon
how to drag and join two or more 3D boxes in flash AS3 pls give me the source file
July 2nd 2009 03:07AM   -   maxwell
Add a Comment
name:
website (optional):
captcha type the characters into the box
message (5000 characters or less):