Real-time Character Motion Effect Enhancement Based on Fluid Simulation

In fast figure animation, motion blur is of crucial importance, and this is especially true when an artist wants to generate exaggerating effect through figure motion. For a quite long period of time, animators seek the answer by using certain kind of image blending, no matter by the means of hardware or software. In recent years, methods based on 3D geometry of the motion figure with global illumination become gradually in demand, as they could deliver relatively high quality of motion blur effect. However, the computation cost in those methods is always very high, thus real time rendering become quite difficult to achieve. In this paper, a real-time motion effect based on 3D geometric approach is proposed, in which a special effect along the motion trajectory based on fluid simulation is combined with the volumetric motion blur. Furthermore, the motion trajectory would be decomposed and multi-pass geometry rendering would be employed to achieve geometry instancing for reuse. In this manner, the redundant calculation of each frame could be avoided, and the limitation of trajectory generation would be broken. In the pipeline, we separate motion tracking and fluid solution, to support various fluid effects flexibly. The scheme we present makes use of GPU geometry shading in parallel, aiming at guaranteeing high efficiency of computation while delivering splendid rendering. As a result, real time rendering including the motion blur effect is achieved.


INTRODUCTION
Motion blur is able to realize various effects in live-action footage: it can concentrate viewers' attention to certain area that the animator wants to emphasize, by blurring its background or surrounding, it can express the extreme speed of a moving object, and it can deliver the idea of vibration of an environment or the dizziness one character feels.With proper design, motion blur can provide motion figure animation with highly convincing details.With the help of GPU computation, the trails of moving objects can be analyzed to provide better continuity and smoothness.
Adding realism to high-speed scenarios is the most common purpose among all the motion blur techniques.Originally, it was realized by merging individual frame with its prior frame, instead of simply inserting data into adjacent frames.In using the most popular tools of DirectX 9 and OpenGL 2.0, the outcomes are generally not satisfying: the moving objects and their background are often mixed together, leading to the result of image quality downgrading, with quite low efficiency.Due to the aforementioned reasons, the employ of motion blur is still limited.
A novel scheme of real-time motion effects based on geometry volume will be presented in our paper, which shows motion blur with well quality of illumination in 3D space, by making use of up-to-date GPU capability.To avoid the duplicated calculation of individual frame, we decompose the trajectory into segments, and employ multi-pass geometry rendering to achieve geometry instancing for reuse.Besides, a special calculation in real time based on fluid dynamics is performed to enhance the post-motion effect.
The structure of our paper is as follows: first, related works on the topics concerning our study interest will be briefly introduced in the Section 2. After that, main principles of our method, along with descriptions of the overall algorithms will be given in Section 3. Following with that are some key solutions for implementation and the testing results in varying complexity, which will be presented in Section 4 & 5. Finally, we conclude in Section 6 with some discussions of the future work.

II. RELATED WORK
In the early days, motion blur is often achieved with the help of OpenGL accumulation buffer.Haeberli and Akeley [1] provided in-depth analysis towards the use of this architecture.
Using ray tracing to perform the Monte Carlo evaluation of integrals [2] in the rendering equations, the problems of motion blur, depth of field, and penumbra can be solved.As the accumulation buffer is separated from the normal rendering hardware, the performance of the hardware was unable to achieve the requirement as demanded in this aspect.However, since GPU has come to our sight nowadays, accumulation buffer was gradually abandoned.Brostow and Essa [3] present a post-process approach to simulate motion blur automatically.They first track the motion within the image plane, and then integrate the changing scene as the time elapses.In this manner, a better support for live-action footage and smoothness can be accomplished.The problem is that image-based motion blur can only provide the most basic effect, without sufficient flexibility.Some powerful or special effect such as the fluid dynamics we proposed in this work cannot be integrated with it.
A framework for elliptical weighted average (EWA) surface splatting with time-varying scenes was introduced by Heinzle et al. [4].They use a piecewise linear approximation to construct a rendering algorithm for point-based objects.In the context of point-sample geometry, 3D Gaussian kernel rather than 2D Gaussian kernel is employed to unify a spatial and temporal component for motion-blurred images, and the change makes sure the continuity in both space and time.
Since Microsoft released a sample "Motion Blur 10" [5] in DirectX 2007, a geometric approach came into the world with the birth of Geometry Shader in Shader Model 4. Based on this method, Sander et al. (Hong Kong UST, Microsoft Research, and Princeton University) [6] proposed an efficient method for traversal of mesh edges using adjacency primitives, which was effective to optimize the motion blur algorithm in the original application by identifying the shared edges to avoid redundant edge extrusion.Simultaneously, DX SDK adopted the similar optimization.However, the computation load depending on trajectory length is still not eliminated.
It was found in the recent work by Schmid et al. [7] that Monte Carlo sampling [2] is not very effective if the time of a trace is very short, compared with the motion effect's active period.To provide better solution to the aforementioned scenario, they propose a 4D data structure called TAO (Time Aggregate Object) by combining the object's geometry at certain instance into a single representation.In addition, the vertices of edges that define surfaces are inserted between adjacent time segments.In this structure, the accuracy of trace could scale with the number of TAO intersections.With volume based motion blur prototype, a 3D appeal is generated, and by intensive ray tracing, the resultant images are in high quality.However, the complexity of computation makes it difficult to realize real-time rendering.
In addition, many of methods above only consider the motion blur effect, which has less-level requirement for long-trajectory motion tracking.However, an important motion effect we want to realize is the effects based on fluid dynamics, thus the requirement of tracking length is much higher than the common motion blur.Therefore, image-based methods have drawbacks on geometric flexibility, and traditional geometry-based tracking has the problem of efficiency for tracking long trajectories.

Split Trajectory Method
An important task of motion effect generation is to trace the motion trajectory.In traditional method, it is convenient to construct the whole trajectory, because the length of motion blur is often very short.However, in our purpose, we want to make it available to trace a long trajectory, in order to support fluid effect with fluid simulation, since the lifetime of a particle in fluid simulation often lasts quite long time.Thus, to trace the whole trajectory is a deal of consumption.To make things simple, we only focus on a segment of trajectory, which makes the base of Split Trajectory Method (STM) [8].
In this section, we first give an overview of our approach named Split Trajectory Method employed to generate high quality real-time motion effect with a dramatic efficiency.The primary steps in the working procedure are as follows:  Character Data Tracking: The motion data are generated by hierarchically traversing each bone from root to leaves along the tree structure of the model. Skinning: The motion data on the skeleton are blended according to the weight in each vertex data structure. Trajectory Segment Construction: By sampling and interpolating the vertex data transformed by the world transformation function of adjacent frames in the Geometry Shader, the trajectory segments are exported back to the memory buffer for reuse. Trajectory Welding: All the trajectory segments are connected by rendering the corresponding segments in sequence of time.The joint of every two segments is sampled at the same time. Motion Effect Solution: Various motion effects are generated based on the constructed trajectory.Here we mainly focus on motion blur and fluid tails. Illumination: In the Pixel Shader (Fragment Shader), the solved trajectory is rendered for visualization. Integration: The motion effect is merged into the scene rendered in the frame-buffer by depth analysis.
The whole procedure of our approach is shown in Fig. 1.
Based on GPU computation, the key stage of our approach is the Geometry Shading, which generates motion trajectory.Conceptually, we split the whole trajectory into a number of segments, named Trajectory Segment (TS), instead of constructing the whole trajectory at once.Such a process reduces the complexity of motion tracking, accelerates the algorithm, and increases the flexibility of the trajectory for GPU computation and the further supports of fluid dynamics.

Trajectory Denotation.
As is mentioned in Section 3.1, in order to avoid the complexity of handling the whole trajectory, we split the trajectory into Trajectory Segments, which is the part in the interval between two adjacent frames, and generate only one segment per frame.For the detailed structure, a Trajectory Segment consists of many points, called Trajectory Vertex.We only sample the motion data at the current (t = 0) and the previous (t -Δt) frames respectively as the boundary vertices of the segment.
A vertex location in motion state can be represented by a 4D vector (x, y, z, t), where p(x, y, z) is the spatial coordinate in modeling space, and t is the corresponding time.For any time t, P(x, y, z, t) is denoted by: where T(t) is the world transformation at time t.Thus, the position of a trajectory vertex is described by P(x, y, z, t) and calculated.The normal vector is calculated similarly.Then, we define a trajectory vertex in the obtained position and fill the data from the Input Assembler, recording the texture coordinates, color with transparency, etc.As we obtained the two sets of boundary vertices transformed by T(t) and T (t -Δt) respectively, a trajectory segment is construct in the interval by joining boundary vertices.

Taxonomy of Trajectory Segment.
In traditional applications, there are three basic types of geometry: point, line, and face.Our Trajectory Segments also have three categories of models for different applications.For particle system, especially for some recently popular particle based simulation, e.g.Smoothed-Particle Hydrodynamics (SPH) [9], the trajectory segment can be constructed as points.In this model, vertex generation is the only necessity, and vertex connection is needless.After simulation, the points are extended to for visualization.Thus, we call this category Motion Particle shown in Fig. 2. We can also process the mesh, and make the vertex distribution homogeneous, so that motion particles can be applied to realize some advanced fluid effect.
For velocity description, a line based model, namely Motion Line (Fig. 3) is proper for speed-line.Only the vertices generated from the same original vertex are joined.Moreover, in cartoon rendering (Fig. 4 [10]), speed-line is a typical abstract object, and in order to simulate the different sizes of brush footprints, lines can be extended to tubes in the next passes of rendering for more complex shading.As motion blur is often presented in the photo-realistic rendering of animation, it is not suitable only drawing several lines like speed-lines in cartoon, i.e. what is visualized should be full-filled geometry.Motion Particle is not a proper alternative either, in respect that sparsely particles cause hole-style noise in the final rendered image, while densely distributed ones cost more vertex buffer and computation.
Here we mainly use motion volume as an important structure to build motion blur and other high-density structure.The illumination model can also be enforced on the volume surfaces correctly in 3D space.Thus, we choose motion volume as the prototype of motion blur.
Different from motion particle and motion line, for motion volume model, vertex data are input as triangle into the Geometry Shader.As is shown in Fig. 5, the three vertices of the input triangle constitute a set of boundary vertices.Then, we interpolate between the two sets of boundary vertices, and obtain the intermediate vertices.Thus, each set of trajectory vertices encloses the cross-section of the volume.

Trajectory Smoothing.
For real-time animation, the motion effect is significant as the object is in high-speed motion.In such a situation, sampling  from each frame is sufficient to construct a good-looking motion effect for human vision.However, for a higher demand, a smoothing strategy is necessary.Hence, we utilize interpolation to generate new joints.Since the trajectory is split, the trajectory segments are independent, i.e. the adjacent data cannot be shared to provide at least four points for traditional cubic curve fitting.Therefore, we considered a strategy depending on the skinning algorithm.
In traditional skinning algorithm, linear interpolation is directly employed on the world transformation matrices.However, some movements of joint area should not be linear.When rotation transformations occur, linear operation on vertex cannot present the curvilinear movement.Nevertheless, we can utilize Dual Quaternion Linear Blending [11] to solve such problems.A dual quaternion is a pair of quaternions shown as following, in which the first row denotes the rotation transformation and the second row denotes the translation transformation.
Since the transformation of skinning is already represented in quaternion form, for our smoothing method, we just directly employ linear interpolation between the dual quaternions, and then transform the original vertices with the interpolated dual quaternion Q t,τ , to obtain the intermediate trajectory vertices.The formula below presents the linear quaternion interpolation.
where τ is the interpolation parameter from time t to t -Δt, denoted in interval [0, 1].Thus, q t and q t-Δt are the world transformation at time t and at t -Δt respectively, both in quaternion form.

Principles of Fluid Simulation
One novel feature of our approach is supporting motion effect using fluid dynamics.Once the trajectory segment is constructed, the basic sketch of motion effect is instantiated as 3D structure.As the trajectory segments constitute the prototype of motion effect, for further effect in visualization, we need solve the effect from initial trajectory to self-solved motion variety to express enhanced effect and fantasy.Our work emphasizes the effect with fluid trajectory.In this section, we will describe the techniques during solving and visualizing the fluid effect.

Physical Model.
We use the fundamental physical model of Navier-Stokes (N-S) Equation [12] for fluid dynamics simulation: where u, p, ρ and F are velocity, pressure, density, and external force respectively.All the data values are measured in unit volume.
For our simulation, we do not consider the viscosity temporarily.Then (4) can be simplified in vector form as (5), where a is the acceleration in unit volume.
In order to solve the N-S equation, the process is divided into several steps:  Advection: we apply Semi-Lagrangian Advection for stable fluids [14] to realize the particle motion according to the velocity.In GPU simulation, since we use fixed cells to represent particles, it is necessary to trace the data from the cell before advection. Poisson Pressure: the pressure term can be transferred into the form of ( 6), which is a linear system.Then we have to solve the system and compute the pressure p.   External force: the acceleration affected by external force is pushed on the velocity.This fact depends on the motion trajectory, which will be discussed in Section 3.3.2. Projection: since the pressure field has been solved, the acceleration provided by pressure difference is calculated by (7), and the new velocity now can be updated.

Fluid -Character Interaction.
We enforce the physical model discussed above into the effect solution system.As is shown in Fig. 6, the process is iterative according to the current simulation time.
For the external data transmission to the solution system, we substitute the property of the segment as the impulse of fluid simulation system.The external force is calculated according to the segment of Motion Volume, and the pigment of the fluid is sampled by the color source of the segment.Instead of expressing the external force/acceleration term in ( 4 for velocity is expressed by (9).
, , where τ is the interpolation parameter from time t to t -Δt, and k is the coefficient for deducting energy loss.p and Tt(τ, p) denotes the original position of vertex and the world transformation function of at time t respectively.

Fluid Initialization Problem.
Except for the physical information, the source of pigments is another significant material we must provide.Here, we use motion particle model to emit particles as voxels.However, as in many meshes, the vertices are not equally distributed.Only applying the motion particle generation makes sparse results.Here, one choice is making use of the UV information.Since UV coordinates in many models are well distributed basically, we can render the vertex information into UV space as an information buffer.
However, a condition must be satisfied that the UV element is a unique parameterization of the mesh; otherwise, the distinct vertices will be record into the same pixel, leading to data loss.Nevertheless, in many applications, for some symmetrical mesh, artists may assign shared area of UV atlas to save texture size.One solution is to remapping UV by some effective UV unwrapping algorithm, such as Least Squares Conformal Maps (LSCM) [14] and Angle Based Flattening (ABF) [15], but it greatly increases the computation of preprocessing.
For such intractable cases, we also proposed a simple process to reallocate particles without rendering vertices in the global UV space.We emulate rasterization in triangle space with GPU Geometry Shader (DX10/11) or Compute Shader (DX11), due to the consideration of efficiency even for the offline preprocessing.As is shown in Fig. 7, for an arbitrary triangle primitive, we conceptually transform it into UV space.Our purpose is to select out the area inside the triangle (back points), compute the positions in modeling space, and generate vertices.To reduce the calculation of texel search, we first restrict the area of UV using (10).
where t begin and t end are the vector to define the boundary rectangle of a triangle in UV space.t A , t B , and t C are the texture coordinates of vertex A, B and C respectively.Similarly to Scan-line Rendering algorithm [16], with the boundary defined, we scan the area row by row with a user-given step to calculate the position of each vertex in modeling space, so that the number of vertices generated is guaranteed to be controllable.We employ bilinear interpolation to obtain the position of the vertex attached on the surface of a triangle face.The algorithm is demonstrated in Fig. 8.
For mapping the position of a certain vertex P in modeling space (red point) from the texture coordination, we construct a set of parameter equations shown as following.
where α and β are the interpolation parameter respectively, and t p is the texture coordinate of the corresponding vertex, generated during scanning from t begin and t end .Besides, t m is the intermediate value.All the UV vectors are in form t i (u, v).We solve the equation, thus obtaining the parameter α and β: where u i and v i are the components of vector t i (u, v).
Care must be taken that for the area inside the triangle, the value of α and β are distributed in the interval [0, 1].Vice versa, for either parameter out of the range [0, 1], it indicates that the vertex is located outside the triangle (blue points), which should be discarded.
Finally we calculate the position p(x, y, z) in modeling space by substitute the solved α and β into the bilinear interpolation equation ( 13) on the positions of Vertex A, B and C, which enclose the triangle.
where p A , p B , and p C are the position of vertex A, B and C in modeling space respectively.All the position vectors are in form p i (x, y, z).Therefore, using the algorithm above, a set of vertices (black points) is generated, which satisfies isotropic distribution on each triangle face.Then, we can emit the particles, and rendering them into pigment buffer, so that the rendering material of fluid effect is prepared.

IV. IMPLEMENTATION
Our system is implemented in DirectX 10.For the construction of the geometric prototype of the motion effects, our Split Trajectory Method is deployed.Then, for advanced effect, we fetch the trajectory segment as the impulse, solve N-S equation with GPU to simulate the fluid dynamics, and shade the effect finally.

GPU Acceleration
In our real-time rendering pipeline in DirectX 10, we make use of multi-pass rendering.Especially, Geometry Shading is recommended to burden the computation for trajectory segment construction.Besides, we also have a function accompanied by the Geometry Shader, which is named Stream Output (named Transformed Feedback in OpenGL 3.0).Stream-out is able to store the primitives generated by the Geometry Shader back to the memory buffer.With our Split Trajectory Method, first, a queue of buffers is prepared for fetching the generated segments.Then, we construct a trajectory segment in the Geometry Shader, and then stream-out the segment to a memory buffer, which is de-queued for the segment out of lifetime, and en-queued for the new segment.This method does not only accelerate the trajectory construction especially with skinning, but also break the limitation of the Geometry Shading.Fig. 9 simply expresses the rendering pipeline for our implementation.

Character Animation
In our work, the character is animated with skeletal animation.In order to enhance the skinning quality, as is mentioned in Section 3.2.3,we choose the dual quaternion algorithm for skinning.After loading two sets of matrices at the current frame time t and the previous frame time t -Δt, we transform them into dual quaternion, and then skin the quaternion using (14) for weight blending and (15) for a fast vertex transformation [14].
Since the animation data of many models exported from the modeling software is represented in the matrices, we have to transfer the matrices into dual quaternion.As many transformation concerns the scaling, thus we follow Xu's suggestion [18], so that the whole skinning workflow is below:  Split the world transformation matrix into translation, rotation and scaling matrix. Transfer the translation & rotation matrix into quaternions; extract the scaling matrix into scaling vector S(x, y, z)  Rotation quaternion is stored in the first row of DQ; translation quaternion is stored in the second row; scaling vector S is stored in the third row. Blend DQ using ( 14), and blend scaling vector using k = 1 in ( 14). Transform vertex position using scaling factor S.  Transform normal using 1/S. Transform scaled vertex using (15).

Trajectory Segment Generation
We construct the trajectory segments in the Geometry Shader, while different types of segments are constructed similarly but varying a little, as expressed in the pseudo programs.
a) Motion Particle: Algorithm 1 shows the Motion Particle construction in GPU Geometry Shader.First, the original vertex data is cloned to the sample.Then, we interpolate the position of the vertex.In skinning function Skin(V, t i ) for position and SkinN(V, t i ) for the normal vectors, V is the input vertex and t i is the flag to identify the transformation of the current frame (cur) and the previous frame (pre).After the transparency is calculated by the attenuation function, we finally append the vertex to the geometry stream.In Motion Particle model, the primitive topology of input assembler is POINTLIST and the output stream format is point<S>.are as the same as Motion Particle model, except that the primitive topology is set to LINELIST and that the output stream format is line<S>.
3) Motion Volume: In order to construct the segment in Motion Volume model, we first calculate the trajectory vertices as similarly as Motion Particle (Algorithm 2).All the vertices are sorted into three arrays S k [] according to the original vertex V[k] during generation.After vertex construction, the vertices are appended to output stream in order to generate triangle faces.Care must be taken that the order of vertex output is significant.Thus, we simply derive the organization of indices following from the example below (Fig. 10).In addition, for Motion Volume, the primitive topology of input vertex is TRIANGLELIST and the stream format is triangle<S>.Algorithm 3 presents the process in GPU Geometry Shader.

Simulation & Rendering
In this section, we will discuss the implementation of shading the two types of motion effects separately.

Motion Blurs & Speed-lines.
Motion blur and speed-line do not concern physical simulation.Therefore, we skip solving the physical system of the effect, and illuminate the motion effect directly in one pass.
In the previous pass, we have computed the position and the normal vector in world space, set the transparency by attenuation function, and copied the information of color and texture coordinate from the original vertex.In a new pass, after rasterization, the final color of the output pixels is computed in the Pixel Shader.During pixel shading, we enforce Phong Illumination Model [19].

Fluid Effect.
We implement the smoke effect with figure motion in our experiment, and a complex process of fluid solution is necessary for smoke.Here 16bit-float textures are used in to denote each vector field to compute the signed values directly.The detailed resource allocation is shown in Table 1.Then, we follow the steps below to implement the smoke effect in Pixel Shader: 1) Segment output: we output the pigment and the initial velocity according to the status of the constructed trajectory segment at once in the same rendering pass.The pigment and the velocity are accumulated to the pigment buffer and velocity buffer in corresponding format respectively.
2) Velocity advection: Using Semi-Lagrangian Advection as (16), we sample the velocity buffer, and trace the last position according to the obtained velocity.Then we sample the velocity buffer again with the source position.After that, the velocity in current voxel/pixel is updated with the velocity in the source position.
where u(x, t) denotes the velocity of the particle located in position x at time t, and x t represents the position at time t.
3) Pigment advection: the pigments are updated as similar as the previous step, but operate on the pigment buffer.Besides, an attenuation function is employed on pigments simultaneously as well.4) Divergence calculation: the divergence is calculated for solving pressure by sampling the adjacent texels.5) Poisson Pressure: the pressure must be discretized from (6) as is mentioned in Section 3.3.1,so that we deploy Jacobi Iteration (17) [20] to solve the linear system by 7-8 cycles.
6) Projection: we transform the pressure differential of adjacent pressure into acceleration, and update the velocity buffer.Moreover, we recommend off-screen rendering [21] for fluid tails in order to eliminate aliasing and hide the flaw of 3D transparent calculation.Hence, we first illuminate the fluid effect into a texture, namely fluid buffer.In order to obtain a smooth combination, in the Pixel Shader we merge the fluid buffer to frame-buffer with alpha blending by depth value as is shown in (18), instead of general depth testing.

V. RESULTS
In this section, we evaluate our method, and show the results of individual motion effects and an integrated demo with complex constructed scene obtained by our method.Our testing machine is equipped with Graphic Card Nvidia○ R Geforce GT240M and Intel○ R CoreTM2 Duo CPU P7450.We also prepare an attach video to animate our result.

Analysis & Evaluation
Our Split Trajectory Method is not only a geometric approach to generate motion effects with high quality, but also accelerate the construction of trajectory by utilizing the GPU parallel computation and pipeline design.In order to evaluate how much it speed up the motion effect by splitting the trajectory, we compare our result to the demo without trajectory splitting from DirectX SDK [Microsoft 2007].In the demo, we keep all things by Microsoft, and add our approach into the codes ( Fig. 11).We also do the statistics for the skinning frequency, the number of vertices output from the Geometry Shader, and the rendering speed in the contradistinctive demo, depending on the trajectory lifetime (length of tracking).
Here we try to avoid the frequency of using skinning algorithm, due to the consumption of skinning.Fig. 12 indicates that with the previous method, the frequency depends on the trajectory lifetime, while in our algorithm, to construct trajectory segment each frame, we only skin the character with constant frequency.The number of vertices output by the Geometry Shader is limited due to the current standards of GPU.In our testing GPU, the output vertex count multiplied by the total number of scalar component of output data cannot be greater than 1024.From Fig. 13, it is obvious that when the trajectory lifetime increases greater than 16, it is out of limitation and disabled without STM, while our method is lifetime-independent.Therefore, our method can generate a long trajectory, thus making it possible to support fluid simulation.Finally, the FPS is counted for both demos ( Fig. 14), in which we only focus on the character animation, excluding other objects.It is persuasive that our approach indeed faster than the general trajectory generation method using the Geometry Shader, due to the fact that we reduce the frequency of using highly-consumptive algorithm.
In a word, the Split Trajectory Method accelerates the pipeline macroscopically.It reduces the generation burden from the Geometry Shader, and avoids the calls of complex

Examples
We first present the individual samples of our result.Here we show the speed-line and motion blur tested on a running character as shown in Fig. 15.To express the effect obviously, a mild attenuation function is applied to the motion volume, thus the results are exaggerated.It is obvious that the motion effects are abundant in spatial perception and flexible to satisfy the different demands of clarity for different effects.In the image of (a), the lines are clear and brief, which is appropriate for both static cartoon and animation.The image (b) shows that the motion blur is an area of blurring effect, which possess high density of pixels, thus the prototype Motion Volume is very suitable for it.What's more, we modeled an integrated scene with our motion effects in a complex scale.The integrated example simulates a situation with many techniques commonly used in current games, including shadow mapping, dynamic water reflection, HDR etc.The whole scene including trees and bamboos are all modeled in 3D, with a relatively complex environment.
Fig. 16 shows an image of our demo result, picked up from a demo video given in the attached file.Besides, the model statistics is as given in the Table 2. Testing with such environment shows that the algorithm and method proposed is feasible for a general gaming environment in real time operations.

VI. CONCLUSION
In this paper, we present an approach to generate the motion effects for real-time figure animations.In order to provide motion effects, we explored methods of GPU computation and multi-pass geometry rendering to reuse the trajectory segment data, thus accelerating the rendering process and making the motion effects with long trajectories possible, especially for skeletal animation with complex skinning algorithm.Our approach is based on geometric shading, which presents more spaciousness than that using image processing.We

Trajectory lifetime
General STM some commonly used motion effects based on the geometric structure, making use of GPU computation for full rendering.Meanwhile, we especially have enhanced the motion effect to support fluid dynamics.Our method can be easily incorporated into many existing real-time animation systems and simplified physical simulation systems, yielding the benefits of both efficient rendering and realistic result production.
Our future work is to enforce our method to much larger scale scenes with optimization.Another necessary improvement is to enhance the fluid effect with more precise simulation.Besides, we also intend to have our approach to support other physical simulation method in Larangian space, such as SPH and Lattice Boltzmann Method, for reducing the complication of Poisson solution and acquiring more advanced fluid effect and physical results.Besides, more types of effects driven by physical simulation can be realized, such as water splash, fire, and explosion.We expect to attempt the interaction among different fluid effects, character motions, and environments in the scene (terrains)

Fig. 4 .
Fig. 4. Speed-lines can describe the direction of motion in cartoon by Maic Masuch.
denotes the attenuation factor of alpha, D fluid and D scene are the depth of fluid buffer and frame-buffer respectively, b represent the buffer value.We clamp the result into interval [0, 1] with saturate().Finally, we multiply the alpha value by the value z fade as the output value of pixel shading.

Fig. 13 .
Fig. 13.Number of Vertices output by the Geometry Shader.It is disabled to generate trajectory more than 108 vertices, due to the limitation of the Geometry Shader on our GPU.
limitation of stream output, so it is made to be possible to construct a trajectory lasting for long time in preparation for the fluid simulation.
specifies some details of our result.It is clear that the vivid motion blur is partly hidden and partly visible surrounded by the atmosphere of smoke.Here we mainly focus on the smoke.As is shown, since the motion and the propagation of smoke are computed obeying the physical model (N-S equation), the perception of diffuse and the spinning vortices are sufficiently expressed accompanied with the motion of the character.

TABLE 1 :
BUFFER ALLOCATION, FOR SOME BUFFERS, TWO SETS ARE NECESSARY FOR READ/WRITE SWAPPING

TABLE 2 :
STATISTICAL TABLE FOR DATA AMOUNT IN THE SCENE OF THE DEMO