Motion Blur in today’s games
Today’s HD games demand the use of
a lot special effects, which range from HDR, to bloom. All of these effects are
done simply like a filter over the game, done as post processing after the scene is rendered.
One of the more special effects is motion
blur, done mainly to first/third person camera games, or any where the player
can dynamically move the camera . The main reason is to make the camera movements
more blurry, and in a way “more realistic”. Though the effect is most defiantly
unique, it also is annoying, as a lot of people prefer to turn it off when
playing their game.
Heres some examples of motion blur in action
Crysis 3 + motion blur
MW2's trailer using motion blur
Blurring in games
The Blurring technique is done in countless games, is quite
simple in concept. We start by mixing the color values of each pixel with the
ones nearby. Generally blurring is done
with every pixel around it, in a 1 pixel radius, resulting in an area of 3x3
pixels per run. We average out this mixed color, and apply it to the pixels in
the area.
With this we can blur
the sharpest pictures. Not only it be used for just for special effects, but it
is also an important step used to help create a bloom effect.
How motion blur is done
To go any deeper, we would have to know about frame buffers,
which are where the scene is rendered to prior to displaying them. Here in
frame buffers we have many different values which we can pass in, and others we
may not want to pass in. These may be the color of the scene, or the depth of
the objects in the scene.
For Motion blur, we need the depth buffer as input to
a pixel shader program in order to generate the scene's general velocity. This shader program will
compute the world positions for each pixel by using
the depth value,
stored in the depth buffer,
and with the current frame's view-projection matrix. Once we determine the world position at that pixel,
we can transform it by
using the previous frame's view-projection matrix. Then we can compute
the difference in the viewport
position between the current
frame and the previous frame in order to generate the per-pixel velocity
values. A motion blur effect can then be achieved by using this velocity vector as a direction
to gather multiple samples
across the frame buffer, averaging them out along the way to generate a blur.
From all of this we can see how different the game can look after see it with motion blur. With motion blur, some people argue that it is a neccessity to have in future games. Not only does it give the sence of realism but it also allows for game developers to create less detailed games, while maintaining a great look. This is because motion blur warps our perspective, not allowing up to carefully examine objects in the scene. Whether motion blur is seen more in the future, or not, we cannot deny how important these "special effects" are in today's games.
No comments:
Post a Comment