Flash vs Silverlight: Water Effect Flash vs Silverlight: Simple Drawing
Sep 08

3D Space is back! My first post 3D Text Space received a lot of comments and I decided to apply the logic on images. The effect is much more groovy than the original one!  No 3D Library is needed.

You may now vote for your favorite sample!

Comparison

Flash implementation: 1 hour  
Silverlight implementation: 40 minutes 
What’s the difference?

  • Scaling: scaleX, scaleY [AS3] vs ScaleTransform [C#]

Source codes

Flash

Silverlight

Scaling: scaleX, scaleY [AS3] vs ScaleTransform [C#]

Scaling in both AS3 and C# look similar. However, you can only scale up a object in AS3 from the perspective point (0, 0). That means, the object will only be extended to the bottom right corner. There are many workarounds for solving this, like putting the image in to a Sprite.

// AS3
// Scaling must be based on the perspective 0, 0
image.scaleX = scale;
image.scaleY = scale;

// Using different perspective
var sprite:Sprite = new Sprite();
image.x = -image.width/2;
image.y = -image.width/2;
sprite.addChild(image);
sprite.scaleX = scale;
sprite.scaleY = scale;

In Silverlight, you can scale up the image using different perspective easily. May be we can consider it’s a strength comparing with Flash.

// C#
// Scale up the image using different
ScaleTransform scaleTransform = new ScaleTransform();
scaleTransform.ScaleX = scale;
scaleTransform.ScaleY = scale;
scaleTransform.CenterX = image.Width/2;
scaleTransform.CenterY = image.Height/2;
image.RenderTransform = scaleTransform;

Shares and Enjoy~

Did you like this post?

Subscribe here:  

79 Responses to “Flash vs Silverlight: 3D Image Space”

  1. Justin Van Patten Says:

    You could simplify the C# code a bit by using a C# 3.0 language feature called object initializers:

    var scaleTransform = new ScaleTransform() {
    ScaleX = scale,
    ScaleY = scale,
    CenterX = image.Width,
    CenterY = image.Height
    };
    image.RenderTransform = scaleTransform;

    or just:

    image.RenderTransform = new ScaleTransform() {
    ScaleX = scale,
    ScaleY = scale,
    CenterX = image.Width,
    CenterY = image.Height
    };

  2. admin Says:

    Thanks Justin, it’s a very helpful feature!

  3. unruledboy Says:

    hello, very charming effect. but the cpu is 100%, sl is still not good at animation.

    I was impressed by a flash 3d engine, I hope sl will accomplish it someday.

    http://temp.roxik.com/datas/max2007/index.html

  4. admin Says:

    unruledboy, the demo is really amazing. Thanks for your sharing. Yes, I think to implememnt 3D space, Flash has more readily available libaray and things can be done easier.

  5. Tom Says:

    Interesting how there’s quite a bit more flicker on the edges of the images in Silverlight compared to Flash. Is it a weakness of how Silverlight scales images? Or its subpixel rendering?

    Keep up the great work! You’re really on to something with this series.

  6. BigDubb Says:

    I’m runnign this and am not getting any cpu utilization worth acknowledging…

    Here is a great site for comparision between DHTML, JS, Flex and SL.

    IMHO, I get the best CPU utilization with SL 2b2 vs. Flex (peaked at 97% cpu utlization) only reaching 63% cup utilization.

    Great work, keep the posts coming. As soon as I figure a way to implement these types of features in a business level application I’m all over it.

  7. admin Says:

    Hi Tom, like what Big Dubb said, Silverlight actual has a higher CPU utilization which showed that Silverlight is performing better. (May be it is due to the reason that I have set the smoothing property of AS3 Image to true which greatly increased the CPU time)

    DigDubb, thanks for your complimentary, I will keep working!

  8. Jose Fajardo Says:

    For those that comment on CPU performance could you maybe also include your browser and OS. It makes a big difference!

    Im getting better CPU thruput from SL but again it’s higher than I’d want from an application like this.

    btw. great site and keep up the great demo’s!

  9. From Flash to Silverlight… - Rudi Grobler Says:

    [...] Flash vs Silverlight- 3D Image Space [...]

  10. uwvhf cbruvwi Says:

    pijtkfbz qiylmzp mxlsgua gvzcdqli xispayb hekst aepkqrnjy

  11. Silverlight Cream for September 17, 2008 -- #370 Says:

    [...] the category of “Sleep … the 8 best hours of the week” … good stuff on bookmarks, Mike, thanks! Flash vs Silverlight: 3D Image Space Now I know that alert readers will notice I’m early today… and because I am, I can pull up an oler [...]

  12. Tribute | Before I forget Says:

    [...] site care merita vizitat este si http://www.shinedraw.com. aici am gasit un exemplu care m-a ajutat sa fac posibila aceasta [...]

  13. Kala White Says:

    I have completed this exercise and replaced the images with my own. I was wondering, if there a way to convert this into a movie that plays for 5-10 seconds without having mouse interaction. I just wanted to use this as a portion of a movie I am doing. Any suggestions?

  14. Gallery Example & Tutorials at Programming with Silverlight, WPF & .NET Says:

    [...] 3D Image Space [...]

  15. Tiago Andrade e Silva Says:

    Hi!
    Thanks for sharing your code :)

    I changed the solution so that it shows Text on the 3D world and not images.
    Here it is http://www.fullsix.pt/tas/TextSpace3D.zip

  16. admin Says:

    Tiago, thx a lot.

    I also got an similar post at http://www.shinedraw.com/text-effect/silverlight-2-upgrade-3d-text-space/

    You may go to have a look~

  17. twisted Says:

    When I make font size smaller (CTRL+Mouse Scroll in FireFox) flash animation adjusted according to smaller size but silverlight it is not.
    And They both have same image quality.

  18. fairymgc0328 Says:

    I really like this forum it’s pretty cool so cudos! What I am trying to do is make a main movie clip which is already built in as2 along with all the other pages… I know as3 is a lot easier to work with but do not have a choice on this build.

    Anyways, as you probably already know I am having trouble calling this gallery into my main movie clip because it breaks since it’s built using as3 I am not the greatest at flash but can usually figure things out… anyway, is there an as2 version or any hacks that I could use?

  19. admin Says:

    Hi fairymgc0328,

    Glad to know that you love my sample. However, there is no as2 version and I don’t have plan to make it as well.

    AS3 is more systematic and structured than as2, you may consider to take this chance to explore about as3 as well.

  20. AC26 Says:

    Guys is there anyway to add hyperlinks to the example so once you click on an image it will take you to another web page/site maybe using a Parent within the addImages function but without losing animation?

    By the way, congratulations for the site and the examples, very impressive!

  21. Kiril Says:

    Marvelous example.
    I would like to ask for a recommendation/help. I would like to implement the following functionality:
    After I click on an image. the camera to navigate to it. But as soon as the image occupies, let’s say, 1/4(might vary) of the screen to pause the camera. This would be useful if someone wants to spend a little more time watching at the picture. Do you guys have any suggestions on this ?

    Best Regards,
    Kiril

  22. Vontux Says:

    I was trying to port this project to WPF, but am failing miserably. Can any pointers for doing so be provided?

  23. » some sources about silverlight 3D progra … Doing & Done Says:

    [...] Flash vs Silverlight: 3D Image Space   [...]

  24. wonderfulpackage Says:

    good idea

  25. E Power Lanka Says:

    Thanks a lot Guys.

  26. Adobe Flash Technology Or Microsoft Silverlight? | Gaming Outcasts Says:

    [...] About the Author: If you enjoy reading this, you may love to read more about Silverlight 3 and flash 3d Share and [...]

  27. What Should I Choose? Adobe Flash Or Microsoft Silverlight? : Hot Articles Online Says:

    [...] you enjoy reading this, you may like to get more about Silverlight 3 and flash 3d Share and [...]

  28. Adobe Flash Technology Versus Microsoft Silverlight » Gadget Reviews & News Says:

    [...] About the Author: If you enjoy reading this, you may love to get more about Silverlight 3 and flash 3d Share and [...]

  29. Microsoft Silverlight versus Adobe Flash | Blognsocialnetworks.com Says:

    [...] About the Author: If you enjoy reading this, you may love to read more about Silverlight 3 and flash 3d Related PostsSeptember 16, 2009 — Microsoft Slams Best Buy Employees With False Information About [...]

  30. Ways To Live A Happier Life | Home Based Business Advisor Says:

    [...] happier. About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash [...]

  31. Web Works » Blog Archive » Adobe Flash Vs Microsoft Silverlight Says:

    [...] About the Author: If you enjoy reading this, you may like to read more about Silverlight 3 and flash 3d Posted in Technology | No Comments » Leave a [...]

  32. OE/PSI – Private Strategies for the Internet » Blog Archive » Adobe Flash Technology Or Microsoft Silverlight? Says:

    [...] Adobe has no competition with anyone in the market for a long period of time. Maybe Microsoft can connect the PCs with the TVs this time. About the Author: If you enjoy reading this, you may like to get more about Silverlight 3 and flash 3d [...]

  33. What Should I Choose? Adobe Flash Or Microsoft Silverlight? | Crafty Addicts Says:

    [...] time. About the Author: If you love reading this, you may like to get more about Silverlight 3 and flash 3d Share and [...]

  34. 7 Tips To Help You Get Away From Sadness | Health and Weight Loss Says:

    [...] life. About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash [...]

  35. 7 Tips To Help You Get Away From Sadness Says:

    [...] happier. About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash [...]

  36. Ways To Live A Happier Life « Self Improvement Reviews and Articles Says:

    [...] happier. About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash [...]

  37. You Can Never Be Sad! | I want to be entrepreneur Says:

    [...] About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash water. You can follow any responses to this entry through the RSS 2.0 feed. [...]

  38. 7 Tips To Help You Get Away From Sadness | Everything iPhone Says:

    [...] About the Author: If you are peculiar most this article, you haw encounter whatever rousing on 3d flash as substantially as flash [...]

  39. You Can Never Be Sad! » Gadget Reviews & News Says:

    [...] happier. About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash water. Share and [...]

  40. You Can Never Be Sad! | Health Bells Says:

    [...] About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash water. Read more… Posted by Anne Yau   @   3 October [...]

  41. You Can Never Be Sad! | Plug In Monster Says:

    [...] About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash water. Share and [...]

  42. Ways To Live A Happier Life | Jason Finch - 7 Figure Marketing School Says:

    [...] happier. About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash water. Share and [...]

  43. Adobe Flash Vs Microsoft Silverlight Says:

    [...] Adobe Flash, having almost no direct competitor for years, finally faces some challenges as Microsoft joins the competition of bridging the gap between computers and televisions with the introduction of Silverlight. About the Author: If you enjoy reading this, you may like to read more about Silverlight 3 as well as flash 3d [...]

  44. Adobe Flash Vs Microsoft Silverlight » Gadget Reviews & News Says:

    [...] About the Author: If you love reading this, you may like to read more about Silverlight 3 and flash 3d Share and [...]

  45. Adobe Flash Vs Microsoft Silverlight | Computers Says:

    [...] About the Author: If you love reading this, you may like to get more about Silverlight 3 and flash 3d Tags: Adobe, Application, business, C#, computer, Computers, Flash, Game, Image rotators, [...]

  46. 7 Tips To Help You Get Away From Sadness | Your Blogmate Says:

    [...] About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash [...]

  47. Ways To Live A Happier Life | Chang Siu dot Com Says:

    [...] About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash [...]

  48. What Should I Choose? Adobe Flash Or Microsoft Silverlight? | News Internet Marketing Secrets Says:

    [...] the Author: If you enjoy reading this, you may love to get more about Silverlight 3 as well as flash 3d Category: Online Business  | Tags: Adobe, Application, business, c, computer, Flash, [...]

  49. 7 Tips To Help You Get Away From Sadness- Nydira.com Says:

    [...] happier. About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash water. Tags: advice, blogging, Break, fun, happiness, health, internet, Laugh, [...]

  50. Boy Craft at BoyCraft.info » Blog Archive » What Should I Choose? Adobe Flash Or Microsoft Silverlight? Says:

    [...] Adobe has no competition with anyone in the market for a long period of time. Maybe Microsoft can connect the PCs with the TVs this time. About the Author: If you love reading this, you may love to read more about Silverlight 3 as well as flash 3d [...]

  51. Adobe Flash Technology Versus Microsoft Silverlight « Business Reviews and Articles Says:

    [...] Microsoft may just be structuring the connection between the PC and the TV more successfully. Adobe should finally be expecting a tough competition after all these years. About the Author: If you enjoy reading this, you may like to read more about Silverlight 3 and flash 3d [...]

  52. Adobe Flash Technology Or Microsoft Silverlight? | Jovie Business Stories Says:

    [...] Microsoft may just be structuring the connection between the PC and the TV more successfully. Adobe should finally be expecting a tough competition after all these years. About the Author: If you enjoy reading this, you may love to read more about Silverlight 3 and flash 3d [...]

  53. You Can Never Be Sad! | Best Strength Says:

    [...] happier. About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash water. SHARETHIS.addEntry({ title: “You Can Never Be Sad!”, url: [...]

  54. Adobe Flash Vs Microsoft Silverlight | Ojith Technology Blog Says:

    [...] the Author: If you enjoy reading this, you may like to get more about Silverlight 3 as well as flash 3d  Link to this page  Link to this page Copy the code below to your web site. [...]

  55. Adobe Flash Technology Or Microsoft Silverlight? | My Business Tips Says:

    [...] Microsoft may just be structuring the connection between the PC and the TV more successfully. Adobe should finally be expecting a tough competition after all these years. About the Author: If you enjoy reading this, you may love to get more about Silverlight 3 and flash 3d [...]

  56. Adobe Flash Technology Versus Microsoft Silverlight Says:

    [...] Adobe Flash, having almost no direct competitor for years, finally faces some challenges as Microsoft joins the competition of bridging the gap between computers and televisions with the introduction of Silverlight. About the Author: If you love reading this, you may like to read more about Silverlight 3 and flash 3d [...]

  57. Game Player Zone » Blog Archive » Adobe Flash Vs Microsoft Silverlight Says:

    [...] About the Author: If you love reading this, you may love to read more about Silverlight 3 and flash 3d Share and [...]

  58. Adobe Flash Vs Microsoft Silverlight | devhideout.com Says:

    [...] celebration of the mass this, we might adore to review some-more about Silverlight 3 as well as flash 3d Share and [...]

  59. You Can Never Be Sad! » Blisworth Web Design Says:

    [...] happier. About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash [...]

  60. Adobe Flash Vs Microsoft Silverlight | Home Based Business Advisor Says:

    [...] Microsoft may just be structuring the connection between the PC and the TV more successfully. Adobe should finally be expecting a tough competition after all these years. About the Author: If you enjoy reading this, you may like to read more about Silverlight 3 and flash 3d [...]

  61. Ways To Live A Happier Life | Concert Tickets Info Says:

    [...] life. About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash [...]

  62. You Can Never Be Sad! | Best Articles Hub Says:

    [...] happier. About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash water. Share and [...]

  63. 7 Tips To Help You Get Away From Sadness | Robert Ramos Jr Says:

    [...] life. About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash water. Share this on FacebookTweet This!Post this to MySpaceEmail this to a [...]

  64. Best Hot Games Blog » Blog Archive » Adobe Flash Technology Or Microsoft Silverlight? Says:

    [...] Adobe has no competition with anyone in the market for a long period of time. Maybe Microsoft can connect the PCs with the TVs this time. About the Author: If you love reading this, you may love to get more about Silverlight 3 as well as flash 3d [...]

  65. Ways To Live A Happier Life | I want to be entrepreneur Says:

    [...] About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash water. You can follow any responses to this entry through the RSS 2.0 feed. [...]

  66. 7 Tips To Help You Get Away From Sadness | Life Diary Says:

    [...] About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash water. Related PostsAvoiding Common Affiliate Marketing MistakesDon’t Wait [...]

  67. Ways To Live A Happier Life | Interviewhelper Articles Says:

    [...] life. About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash [...]

  68. 7 Tips To Help You Get Away From Sadness « Well Cool Tech Says:

    [...] About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash [...]

  69. Ways To Live A Happier Life | Free Articles Says:

    [...] About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash [...]

  70. Ways To Live A Happier Life | Free Articles Directory Says:

    [...] you are curious about this article, you may find some inspiration on 3d flash as well as flash [...]

  71. Ways To Live A Happier Life | Your Complete News Guide to Latest Technologies and Trends Says:

    [...] you are curious about this article, you may find some inspiration on 3d flash as well as flash water. AKPC_IDS += “475,”;Popularity: unranked [?]More Related TopicsFinding [...]

  72. Ways To Live A Happier Life | ModernHealthyLiving.com Says:

    [...] you are curious about this article, you may find some inspiration on 3d flash as well as flash [...]

  73. 7 Tips To Help You Get Away From Sadness Says:

    [...] you are curious about this article, you may find some inspiration on 3d flash as well as flash [...]

  74. BLOG Biz Network » You Can Never Be Sad! Says:

    [...] you are curious about this article, you may find some inspiration on 3d flash as well as flash [...]

  75. You Can Never Be Sad! | Verloggers Place Says:

    [...] life. About the Author: If you are curious about this article, you may find some inspiration on 3d flash as well as flash water. Sphere: Related ContentOff-Page Search Engine Optimisation Simplified [...]

  76. Lucero Swank Says:

    I know just what you mean about concentration, it makes a WORLD of difference. Great suggestion.

  77. Yamaha Owner Manual Says:

    I found your site from bing and it is magnificent. Thankx for supplying such an amazing blog post…

  78. Flash ve Silverlight karşılaştırması | AdobeHaber Says:

    [...] Flash Silverlight Download [...]

  79. mehrdad Says:

    Hi. I want site Similar tish site: http://www.simiaco.com/portfolio.html
    Please Help me.
    Please video tutorial
    Thank you
    Bye

Leave a Reply