Der Schmale – David Lenaerts’s blog

Flash Platform Experiments

A heartbeat, some books, and an IDE

Tags: , , , , , , , ,

Ouch! My last post has almost been 5 months ago! Realizing this, I had two options: to feign my own death until the next update, or to give some sign of (what for me passes as) life. Let’s go with the second option and see if there’s anything useful I can pass on anyway.

Not having posted in such a long time doesn’t mean I’ve been slacking off, though. Quite the contrary; the past months have seen some of the most intense coding sessions I’ve went through in a long time. First a 3-month non-stop coding spree for Away3D, followed by continued development on Farbe. Hopefully, the result of both will be available in the (very?) near future, along with some other updates!

Now, instead of giving you demos or code, here’s some other things to help you develop.

(and no, I won’t be sharing any thoughts on the future of Flash)

Books!

Books form such an important part of my development process and knowledge, I’m a bit surprised myself that I haven’t really shared any titles here. Trying to ammend the situation, here’s some of the more influential ones I’ve read since I’ve started this blog (leaving out more general ones concerning design patterns etc):

  • The Pragmatic Programmer, by Andrew Hunt and David Thomas: it’s a classic, and you should already have read it. So why am I still listing it? Because it often seems many Flash platform programmers stick to ActionScript/Flex-related books. Here’s a book that changes the way you think about your code, be it in form of design principles, tools or workflow. It’s a rather short read, so no excuses!
  • Elements of Programming,  by Alexander Stepanov and Paul McJones: I found this one on a random trip to the bookstore. Approaching algorithms and data structures in a very formal and mathematical way, it forces you to – again - think differently about your code, but on a lower level (mainly concerning algorithms using data structures). What I love about this type of books is that you suddenly realize how differently you start tackling certain algorithmic problems. Perhaps not a book for everyone, but an interesting read nonetheless.
  • 3D Game Engine Design, by David H. Eberly: (Thanks to Ralph for suggesting it way back :) ). “The Morgan Kaufmann Series in Interactive 3D Technology” has quite a few good books, but to me, this is the most valuable. Of all books I had at the time, this one taught me most about many 3D engine concepts. During the development of Wick3d, I couldn’t do without it.

IDE – IntelliJ

I’ve recently started using IntelliJ IDEA 9 for ActionScript and Flex development, after hearing Joa and the Flash Bum raving about it. Coming from Eclipse (Flex Builder and FDT), it took a while to get used to, but now I have I can’t imagine returning to Eclipse at all. I have been raving about it in real life, much to the annoyance of my co-workers, so it would be wrong of me not to mention it here.  The refactoring, template and code generation support is simply unmatched, there’s a very useful and clean UML diagram view, properly integrated Maven support, … AND I get to annoy the Java/back-end team directly inside the IDE ;-)

To think I was once had to code C in MS-Dos Edit, how times have changed… :)

Edit: The Flashbum just wrote an article on InsideRIA about how to get started. Read all about it!

That’s about it. I hope this sign of life is useful to anyone after all! If not, I promise there will be more real updates soon!

Leave a comment (5 comments)

One year later: a short retrospective

Tags: , , ,

birthdaypieThe first post on this blog dates from May 4th, 2008, so I thought it fitting to look back at the year that has passed since then.

Over the time I’ve done some experiments/projects that, when I look back at them, make me think “What was I thinking?!”. On the other hand, there are luckily a few of which I’m actually proud, or at least content with how they turned out – whether they were practically useful or not (which is not exactly always my goal). A lot of the things I did, I did as a way to learn. As such there was Wick3d, a (now defunct) basic 3d engine to rehash my algebra (actually, I worked on it some more after the last update without comitting anything to svn). And of course Pixel Bender came along, giving me a whole new area to explore, as did Alchemy.

I do feel I learned quite a bit, but at the same time it seems with everything I learn, there’s twice as much I still need to study. Feels like a constant battle against ineptitude, especially when talking to those who actually seem to know what they’re talking about ;)

Lastly, I’d like to pass some more updates on Farbe. I recently made some updates implementing oil paint and airbrush. There’s still so much work to do before it can go public, but soon it will be time to look for a Flex UI-designer/skin artist. If you know or are anyone with experience, send me a hoot with some examples! AS3/MXML/CSS experience is a must of course :) Just keep in mind, the project is free and will likely be open-sourced eventually (which is also a cheap way of saying: no money involved ;) ). If you follow me on Twitter, you might have seen some demo pictures being tweeted. Those that haven’t: here’s some previews of Farbe simulating pencils (1, 2), oil paint and airbrush.

Off towards another year! Thanks to all you readers!

Leave a comment (4 comments)

Image bleeding with water (Flash + PixelBender)

Tags: , , , , , , ,

Image BleedingThe last 2 months, I’ve been investing 99% of my free time into the next iteration of Farbe, turning it into a real Flex-based image editing tool simulating natural media. Although there’s nothing of the application itself that I can show yet, today I created another small proof of concept for it that I can make public.

One of the things lacking in the watercolour POC was that once a brush stroke was made, nothing could be done with it. I thought it’d be nice to still be able to add water once the paint was rendered and have the colours bleed out. Using much of the same physics as for the watercolours, I figured out an algorithm that was both adequate in speed (real-time) as visually effective enough to water down the image. As usual, much Pixel Bender was used. The multi-threaded nature of ShaderJob really proved its worth in this case. You can keep adding water without the simulation slowing down the interaction, even if the simulation itself gets slow when there’s a lot of wet areas to cover.

To get the most realistic results, settings such as “ink speed” and “water amount” should be kept low while slowly rubbing over the image. Higher levels are not natural and will look caricatural (reminding me of Kai’s Power Tools of old! ;) ).

So check it out! :)

Note that, even tho Farbe is not an open source project (or not yet at least), I’m providing the source for this POC – consider it a late Easter present ;) But do remember, it IS poc-style code!

In closing, I’ll leave you with a few updates on Farbe. First of all, the watercolour paint is quite a bit faster (unless, of course, you’re working on much bigger canvas sizes than the cheaply upscaled old version) and so far it seems it’s pretty bug free! Secondly, I recently finished a pencil and eraser tool which are looking alright. The rest of the time has been spent mainly on the user interface and typical paint tool functionality. I’m starting to feel quite overworked at the moment, but the app is shaping up so it’s worth it! I hope I’ll be able to give out some more tangible updates on all that soon :)

Leave a comment (8 comments)

Flash watercolour simulation (using PixelBender)

Tags: , , , , , , , , , ,

farbe-watercolour

Something I’ve been thinking about doing for a long time is imitating real artistic media, in particular watercolours. Not because I’m an avid watercolour painter (last time I’ve touched them was in kindergarten), but because I think it’s an interesting dynamic. Since it is mainly fluid dynamics, the idea resurfaced after my previous fluid sims. And luckily, with Pixel Bender, I can finally do this kind of thing! This paper by Cassidy J. Curtis et al was great, tho it also caused me to loose some time figuring out some errors. Finally I came up with something, dubbed Farbe (simply German for ‘colour’). One thing I dropped was the interaction between different strokes, because that would kill the cpu easily enough.

For a change, there’s no source of this, and for a few reasons. First of all, it’s a mess and needs to be optimized. Apart from that, I might just add on to this before I release anything (hence the project name ‘Farbe’).

The picture on the left is my poor imitation of Joan Miró’s Barcelona ’92 poster (Strepie, this one’s for you ;) ), so ignore that and create your own :)

See Farbe in action

Leave a comment (25 comments)

© 2009 Der Schmale – David Lenaerts’s blog. All Rights Reserved.

This blog is powered by Wordpress and Magatheme by Bryan Helmig.