Experiments with Motion Detection in the Flash

Basically it was used BitmapData Class and the methods: draw, threshold, getColorBoundsRect and getPixel. In the first three samples the detection is accomplished by the coordinates x and y (getColorBoundsRect) and in the last two samples for detection by colors (getPixel).

Simple detection


Detection and fire


Playing keyboard (with sound)


Playing boxes (with sound)


Color detection


30 Responses to “Experiments with Motion Detection in the Flash”

  1. Will Says:

    Erick, these are fantastic experiments, in that they are basic enough to grasp the fundamental possibilities. We have just returned from the Flash Forward conference in Boston, MA, and are full of ideas. Unfortunately, when it comes to using the camera class withOUT flash media server, Adobe’s documentation is sparse at best. If you don’t mind, what are some of your resources for learning this stuff? We are diving in, and are looking for answers, from which to build our own experiments. Again, these are great experiments!

  2. Webcam Motion Detection in Flash — Knut Urdalen’s Blog Says:

    […] whole process is described in this tutorial. I also found some other examples. If you have any references on using webcam motion detection, please post it in the […]

  3. Bolo Says:

    Could you post your sources ?

    thanks

  4. Thomas Gooday Says:

    This is amazing, exactly what i have been searching for.
    Could you possibly send me the source codes for the colour detection, as I am intending on integrating this facility with motion detection to create a game.
    If not could you produce/ supply me with a tutorial on how to complete this.

  5. brice Says:

    i’m trying to use some of the basic principles that you are using in these experiments. for now i’m just looking for a way to interact with something on the screen, like the first experiment with the red ball moving around. could you possibly send me the source code? thanks a lot.

  6. brice Says:

    p.s. i’m using a.s. 2.0

  7. Flo Says:

    Hi,

    really cool webcam experiments! 4 months ago I published my Interactive Webcam Package for ActionScript 3 and 2 ( http://www.derhess.de/weblog_detail.php?id=47 ). My Classes seem to work very similair as yours. Also Benjamin Bojko from Germany implemented very cool Color Tracking classes, too. (http://www.bbojko.de/?p=26 , http://www.bbojko.de/?p=29). I think there are a lot of more cool possibilities with webcam interaction. Keep up coding! :-)

  8. Gary Says:

    Great work Erick. Would it be possible for you to send me the source of the Playing boxes (with sound.) Ive been struggling with something similar is AS3 for quite a while now.

    Any help would be greatly appreciated!

  9. Andrea Says:

    hi! may i have the source code? tnk! :o)

  10. MikeM Says:

    Cool work! Yes, can you share source code for study it and make it better? Thanks!

  11. Pwhndvve Says:

    Honi soit the dazzlingly buy cytotec meat steamed held.

  12. Jaze Says:

    hi! where can I find the tutorials for these?

  13. tom Says:

    hey nice examples! :)
    are there any tutorials or source codes available? specially i’m looking for something like your first example “Simple detection”.

    please let me know.
    thanks
    tom

  14. Robby Says:

    Hi there! Your examples of work on here are awesome! i am currently trying to implement something simular to this for a university project. i was wondering if you would be willing to share the source code, or just point me in the right direction. I’ve noticed that a lot of people have requested this but i am not sure if you replied to them. Any help would be most apreciated! Thanks!

  15. alex Says:

    hai…
    by seeing your work i am so eager to know more about your impressive work…
    can you help me…. with a tutorial…
    or please help me with a source code..

  16. A. Cortes Says:

    Hi Erick! Let me conrgratulate you about your job, i think that is amazing. Can u please send me a copy fo your source code, im trying new things adn i like to learn to use flash and webcams techologies. Thank you very much.

  17. sandrar Says:

    Hi! I was surfing and found your blog post… nice! I love your blog. :) Cheers! Sandra. R.

  18. angelina jolie Says:

    I love your site. :) Love design!!! I just came across your blog and wanted to say that I’ve really enjoyed browsing your blog posts. Sign: ndsam

  19. megan fox Says:

    Sign: umsun Hello!!! rcuwwymhyw and 5903ssgfhphzye and 3438Great Blog!

  20. katty11 Says:

    Sign: bmzaf Hello!!! tcxtr and 1026kzavbpqnvp and 5290 My Comments: Great!

  21. haikal Says:

    hi im haikal from The one academy college in Malaysia,taking multimedia as my major.i want to asking you for your help about your “Playing keyboard (with sound)” project. ive got my final project using a projection floor interactive game.i dont have any idea how to do that until i saw your website. can u teach me how to coding this project? kind of like a stepping on the floor and the beat will be hear.
    (i apologize with my bad english)

  22. pictures of miley cyrus Says:

    Sign: zbdtg Hello!!! pukcz and 2542bdmeemcbdr and 7954 : Great!

  23. jervieriesype Says:

    Sta kazete o njenim stopalima?
    Uclanio sam se na njen site i mogu reci da ima jako lijepa stopala!
    Stopala su na njoj najbitnija stavka!

  24. Lee, Eun Taeg Says:

    Hi Erick
    I’m student who study in Korea.
    I’m sorry but can you send me the source of ‘playing boxes’?
    thank you very much.

    my e-mail : lut83@hanmail.net or letsky00@hotmail.com

  25. Josh south Says:

    Hello!
    I am a masters student working on my thesis project. It involves many similar concepts such as yours. I would like to see if its possible to work with you on my directed study. Or possibly instruct via email or chat? I am willing to pay for assistance or whatever is needed.

    If the answer is no, I truly understand. Hope to hear back from you!

    My family is from Ecuador! i will be in south america in january!

    thank you for you time!

  26. noname2605 Says:

    Hello Erick!
    I’m a student who study in Viet Nam.
    I’m very interested in the source of ‘playing boxes’.I’m very grateful if you send it to me.Thank you very much.
    My email:hongphuong260588@gmail.com

  27. John Says:

    Hi!
    Love your work, we´re trying to do similar things out here in Spain. Are you sharing your source code? If so I´d love to take a look at it.

    -John

  28. Choi Says:

    Hi! thanks for sharing your nice work.
    I am just wondering if you could share your source for study. Thanks a lot :)

  29. Choi Says:

    Especially for the Playing boxes (with sound) and Playing keyboard (with sound)

  30. Broderick Murray Says:

    You have to express more your opinion to attract more readers, because just a video or plain text without any personal approach is not that valuable. But it is just form my point of view

Leave a Reply