Silverlight Particle Generator

particleman

I’ve been experimenting with particle generation a little bit over the weekend.  I guess that if I were a gamer, particle effects may seem kind of ordinary.  They’re first draft fodder for game guys.  For me, though, there is still a lot of allure and new here.

The result: I’ve got myself a new effect crush. I still have a ways to go toward ideal implementation though.  The basics seem to be there, it does emit particles after all.  Most of the issues that I’ve been running into are related to performance.  There really isn’t a “lightweight” way to generate all those particles, so I end up just creating hundreds of ellipses and moving them around the screen.  Given what I’m doing, I think that Silverlight’s doing a pretty outstanding job keeping up…but I wish there were a lighter-weight way to handle these kinds of drawing operations.  In WPF, I would override OnRender for the control and then just issue drawing commands.

Well, in the meantime, you can check out a full screen version of the demo or download the source. This isn’t final, though, so stay tuned for some updates.  Planned changes may include: gravity, directional momentum, some simulated 3D, support for multiple colors and some more perf tweaking.  You can, of course, always get the most current version from the labs page.

Finally, as always, if you do end up doing something with this I would really love to know about it.  Please send email to hello@nerdplusart.com.  Knowing that people use it is the fun part of putting stuff out there.

28 Comments

Jay Solomon / AUG 19 2008

Fantastic work. Very very impressive.

Jay

dongin.lee / AUG 19 2008

It’s good! It’s funny.

Sameer C Thiruthikad / AUG 19 2008

Wow! Super cool app in Silverlight.
The control panel looks very cute as well… I liked its colors and layout a lot.

Mariusz / AUG 19 2008

Hi Robby, your particle generator looks very hot, especialy the magic wand effect :-)
I like it, keep it up ;-)

james / AUG 19 2008

Awesome work! What are you using for your primary IDE … Blend, Visual Studio, etc.?

Tom / AUG 19 2008

That’s a wonderful demo! And surprisingly polished – I really like the UI. Aren’t particles fun? My first DirectDraw app was a configurable particle system, but it wasn’t nearly as cool as this. It’s just a shame that Silverlight is so CPU intensive. This kind of stuff will be a lot more practical if/when Silverlight gets some hardware acceleration. They had better do it, eh? Maybe in version 2 or 3.

John / AUG 19 2008

Very, very cool. Thanks (especially for the source)!!!!!!

senkwe / AUG 19 2008

Awesome…

Jeremiah Morrill / AUG 19 2008

Very sick! Awesome even!!

I was a little bummed about the lack of any raster-type API in SL2, but seeing this made me remember that there’s a lot of visual effects you still can do with vectors.

Looking forward to seeing more!

-Jer

Robby Ingebretsen / AUG 19 2008

Wow! Just logged in to find ten (yup 10) comments waiting for approval. Nice! Thanks guys.

@james: This was mostly done in Visual Studio. I have a weird workflow for things that require visual attention / detail (like the control templates). For those, I actually use a hybrid of Blend and Kaxaml. I really should do a post about this…more details in that (future) post.

@sameer / Tom: Glad you like the property panel UI. BTW, the control templates are included in the app as well (I guess that’s obvious) so get ‘em while they’re hot.

Thanks again to all who commented.

2008 August 20 - Links for today « My (almost) Daily Links / AUG 19 2008

[...] Wahlin updates his SL articles – REALLY worth a looksee A flyout stackpanel menu control Vector based particle generator engine An awesome tutorial on Messagebox functionality in SL2 Creating a Silverlight 2 Client Access [...]

Ervin / AUG 20 2008

This is awesome job. Thanks for sharing it

Page Brooks / AUG 20 2008

This is awesome! Nice work!

techwizard / AUG 22 2008

Awesome…

Mark / OCT 17 2008

Hi

Can you please update to latest version now. i just found your article but can;t view it.

Cheers

Mike Greenway / SEP 26 2009

An Insipation as always
Thank You

Posty / DEC 02 2009

I’m not a programmer, but I feel like I can still use it during my playtime.
Well done & thanks for posting!

Michael / FEB 17 2011

I remember seeing this within the last six months and i came across and decided that I should have our devs look into what you did since we they had to create a WPF particle generator

Robby Ingebretsen / FEB 18 2011

@Michael. Great! I hope it turns out. Sounds intriguing :)