Mue 발표자료 박동규조미리나

21
An Interactive Fire Animation on a Mobile Environment DongGyu Park, SangHyuk Woo, MiRiNa Jo Dept. of Information and Communications Engineering, Changwon National University DoHoon Lee Research Institute of Computer Information and Communication, Pusan National University

Transcript of Mue 발표자료 박동규조미리나

Page 1: Mue 발표자료 박동규조미리나

An Interactive Fire Animation on a Mobile Environment

DongGyu Park, SangHyuk Woo, MiRiNa JoDept. of Information and Communications Engineering, Changwon National UniversityDoHoon LeeResearch Institute of Computer Information and Communication, Pusan National University

Page 2: Mue 발표자료 박동규조미리나

Motivation and Contribution• Fluid simulation

– Physics based on realistic animations of water, smoke, explosions, and related phenomena

• Advances in the mobile handset– The development of mobile hardware has accelerated.– The mobile handset which can process 4 million polygons.– Expected that the fluid simulation will be possible.

• Physics based models in Mobile Game– As PC games are converted to mobile, we expect that

physically based modeling will be implemented in mobile environment.

Page 3: Mue 발표자료 박동규조미리나

Introduction-Mobile hardware• Display

– Small screen– 48x84 1bit pixel ->

320x240, 256 pixel(WIPI minimum requirement)

• Mobile Chipset– ARM 9 family : 200 Mhz– ARM 10 family : 400 ~ 600

Mhz– ARM 11 family : 400Mhz ~

1Ghz processor for Smart phone

• Small Memory size

Page 4: Mue 발표자료 박동규조미리나

Introduction-Mobile 3D API• OpenGL-ES

– Low-level Graphic API– Widely adopted stan-

dard for Mobile device– Most OS’s, thousands of

applications– A foundation for high

level APIs• OpenInventor, Java3D,

game engines.

• JSR-184– Java Standardization

Request(JSR)– Mobile 3D Graphics API

for J2ME

Page 5: Mue 발표자료 박동규조미리나

WIPI & NF3D• WIPI(Wireless Internet Platform for Interop-

erability)– Standard wireless platform in Korea

• About NF3D– Mobile 3D API based on OpenGL-ES– Support 3D camera, object handling functions

Page 6: Mue 발표자료 박동규조미리나

Fire simulation on Mobile Games

• Mobile Game – “Rupee Story”– 3D adventure games– Interactive fire simulation on realtime game– WIPI + NF3D API

Page 7: Mue 발표자료 박동규조미리나

Navier-Stokes Equation• NS Equation describes the flow of fluid. • The sum of inflow and outflow is 0. (Conservation of mass)• Conservation of momentum

– u : velocity vector field– t : time step– : fluid density– p : fluid pressure– v : coefficient of viscosity – f : external force

fu1

u)u(u

0u

2

p

t

fu1

u)u(u

0u

2

p

t Advec-tion Pres-

sure

Dif-fuse

External force

Page 8: Mue 발표자료 박동규조미리나

Stable Fluid Solver• Stable Navier-Stokes Solver

– Analysis of evaluating solution is difficult.• Evaluate approximation Solution using numerical method

– Finite difference : Having instability that don’t conver-gence quickly.

• When the time interval is large, it is unstable.• the fluid velocity, we must use a small time interval

– Stable Fluid• Semi-Lagrangian : the method of getting velocity by back

tracking to the particle of current cell• Can tolerate the use of larger-than-desired time intervals

Page 9: Mue 발표자료 박동규조미리나

Fire simulation• Fire consists of the components: Fuel, Oxy-

gen, Heat, Inert gas– Fuel + Oxygen      Heat + Waste– If there is insufficient oxygen and fuel , the fire makes

smoke.• Physical phenomena around the fire

– As temperature rises, the surrounding air(smoke) has ris-ing force

– As the air moves away from the source of fire, the tem-perature goes fall down

Page 10: Mue 발표자료 박동규조미리나

Fire simulation• Fire and smoke can be simulated by using

buoyancy force and cooling factor – Buoyancy force

• This can raise high temperature of gaseous.– Cooling factor

• As fire and smoke go away from the energy source, the temperature goes down.

• The temperate goes fall down by certain ratio and is conducted to neighbor cells

• We can draw the color of fire and smoke based on its temperature.

Page 11: Mue 발표자료 박동규조미리나

Interaction• Use the external force term in NS equation.• When the game character approaches to the

fire, external force affect the velocity field. • Interaction for various effects.

– Perturbing the flame and scattering smoke.

Apply external forces for interaction

Page 12: Mue 발표자료 박동규조미리나

Coloring the Fire and Smoke• The temperature(wavelength) of the fire de-

termines the color of the flame.• As the temperature increases; the color

changes from red, green (yellow), blue and white– EX) As the temperature changes, the color of the flame is

not same on burning tree.

850 ℃

1100 ℃

1500 ℃

Low temperature

High temperature

Page 13: Mue 발표자료 박동규조미리나

Coloring the Fire and Smoke• The temperature of the fire determines the

color of the flame.• Set the standard temperature

– Separate fire and smoke by specific temperature• Define the temperature value of grid cell for

simulation– Float value between 0 and 1– To use RGB color system for coloring flame and smoke– Set five basic colors: linear interpolation of assigned col-

orsLinear interpolationLinear interpolation

Low temperature

High temperature

< The color of the flame >

Page 14: Mue 발표자료 박동규조미리나

Billboard• Orienting the polygon based on the view di-

rection– Two dimensional animated texture maps– As the view changes, the orientation of the polygon change– Using to show complex geometry model as one image

• EX) tree, cloud– Alpha texturing + Fire animation explosion and smoke ef-

fect

Simulated billboard on Mobile 3DSimulated billboard on PC

Page 15: Mue 발표자료 박동규조미리나

Billboard• Using fixed point operation of NF3D • Using off-screen buffer

– Save simulation result to off-screen buffer– Copy it as image– Texturing on billboard– White background process alpha blending transparently

128

12

8

Off-screen buffer

Image

Billboard

128

12

8

Off-screen buffer

Image

Billboard

Page 16: Mue 발표자료 박동규조미리나

Billboard• Using alpha blending

– Control transparency of Billboard– Specified color is complete clearness

(a) does not apply alpha blending

(b) apply al-pha blending (50%)

(b) erased original white background and apply al-pha blending

Page 17: Mue 발표자료 박동규조미리나

Implementation• The simulation are applied on our mobile 3D

game “Rupee Story”• Real-time Interaction with Game Characters,

demo

Page 18: Mue 발표자료 박동규조미리나

Performances• NF3D supports Frame per second check func-

tion• Tested on emulator and FPS(Frame Per Sec-

ond) check functionSimulation and rendering results

0

5

10

15

20

25

30

32*32 48*48 64*64 96*96 128*128

Simulation grid

FP

S

Page 19: Mue 발표자료 박동규조미리나

Performances• The change of billboard refreshment period

– According to importance of game and fluid simulation• The change of simulation grid size

– Simulation speed is depend on the size of the grid– For realtime game application we should have to find ap-

propriate grid size– By an experiment, 64*64 grid size is good for our realtime

game application

Page 20: Mue 발표자료 박동규조미리나

Conclusions and Future Works• Physically based model for animating and render-

ing fire and smoke with using billboard technique on a mobile environment.

• We demonstrated that this model could be used to produce realistic looking fire and smoke animation and plausible realtime interaction for mobile games.

• More realistic fluid effect on new mobile 3D plat-forms

• Implement water and ocean effects on mobile plat-forms

• Implement with level-set methods that are very ef-fective methods for tracking fluid surfaces.

Page 21: Mue 발표자료 박동규조미리나

Thank you