2

I tried this in AS3.0, but cannot get anything near to blur. What i get is blinking image. I was curious to know, if it's even possible to get blurness in motion on average computers due to high speed ? Or motion blur does not occur due to high speed ? Or something else ?

import flash.display.MovieClip;
import flash.utils.Timer;
import flash.events.TimerEvent;

var a_Mc:MovieClip ;
var tim:Timer = new Timer(1); // 1 milliseconds


tim.addEventListener(TimerEvent.TIMER, time)

tim.start();

function time(e:TimerEvent)
{
    a_Mc.rotation = a_Mc.rotation+  90  

}
Martijn Pieters
  • 1,048,767
  • 296
  • 4,058
  • 3,343
Vishwas
  • 1,533
  • 2
  • 19
  • 40

2 Answers2

3

I think this is mainly due to a misunderstanding of the reasons of blur in video.

Blur appears when during the exposure time, the projection of an object on the sensor moves by more than one unit of resolution (pixel for a digital sensor).

This is not the case (by default at least) in AS3 and computer science in general. Here the image is created with the state of all the object at a specific time and with no motion, then printed, and then created for t+1... so no blur can happen.

The solution is to emulate the blur. To do this in AS3 you can read this.

Community
  • 1
  • 1
  • I thought blurness occur due to high speed of an object. Never ever seen motion blur in real life, but TVs and Cinemas though. :) – Vishwas Jun 11 '13 at 10:21
  • Maybe a professional in optic can now answer why the human eye (and brain) don't "motion blurize" high speed objects :) – Florent Vielfaure Jun 12 '13 at 14:51
  • I'm an optometrist. The brain does, indeed, cause motion blur. For the visually observant, go outside in natural light and wave your hand very fast back and forth against a solid background. You will see a blurred hand. Now go inside in a room lit by a single flourescent light, or stand outside on a dark night on a street lit by a single street lamp and do the same thing. You will observe "framey-ness" rather than blur because your hand is lit and then not lit as the flicker rate of the light cycles. – Neal Davis Dec 19 '16 at 05:00
0

To get a blur effect in flash you need to apply a blur filter to it. You can create and apply this filter to an object in code and adjust the amount of blur as well. For a motion blur, you could apply filter and use the object's speed as a multiple for the amount of blur you want.

mitim
  • 3,169
  • 5
  • 21
  • 25
  • I know. I generally do it manually in photoshop. I wanted to know, if blur can be generated programatically. Or is it not possible by computers even. Let's say because average computers cannot display motion on high speed ? – Vishwas Jun 11 '13 at 10:05
  • You mean in general or just within flash? In general, certainly computers can generate realistic motion blur (say in 3d rendering). Within flash, the effect is just applied with a filter. As mentioned, this filter can be created and tweaked through code and not manually applied. Cherniv's answer has an example code snippet for creating it and applying it. – mitim Jun 11 '13 at 10:10