an optimized real time algorithm for window frost formation suited to mobile...

15
Multimed Tools Appl (2018) 77:11807–11821 An optimized real time algorithm for window frost formation suited to mobile devices Jaeho Im 1 · MyungJin Choi 1 · Jung Lee 2 · Chang-Hun Kim 1 Received: 17 October 2016 / Revised: 4 May 2017 / Accepted: 4 May 2017 / Published online: 18 May 2017 © Springer Science+Business Media New York 2017 Abstract We propose a real time simulation for window frost formation on mobile devices that uses both particles and grids. Previous ice formation methods made heavy demands on both memory and computational capacity because they were designed for a desktop envi- ronment. In this paper, a frost skeleton grows around a location touched by the user using particles, and the ice surfaces are constructed using a grid. Using a nonlattice random- walk technique, the frost skeleton grows freely and naturally. A hash grid technique is used to search efficiently for neighbor particles during the crystallization process. Finally, some 2.5D details are added to the ice skeleton by adjusting the height of the grid ver- tices around the skeleton. Experiments show that our method creates realistic frost in real time. Our method can be used to express ice formation effects in touch-based mobile device applications such as weather forecasts or games. Keywords Window frost · Ice formation · Mobile device 1 Introduction As high-performance mobile devices have developed, their available memory and com- putational resources have increased significantly. This has made mobile-based physics simulations feasible. Stanton et al. [21] proposed a water simulation method for a mobile Chang-Hun Kim [email protected] Jaeho Im [email protected] 1 KoreaUniversity, 407B Woojung Building, Anam-dong 5(o)-ga, Seongbuk-gu, Seoul 136-713, Republic of Korea 2 Hallym University, 1303 Engineering Building, 1 Hallymdaehak-gil, Chuncheon, Gangwondo 24252, Republic of Korea DOI 10.1007/s11042-017-4819-2

Upload: others

Post on 12-Oct-2020

0 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: An optimized real time algorithm for window frost formation suited to mobile deviceskucg.korea.ac.kr/new/seminar/2019/paper/pdf-2019-03-14.pdf · 2019. 3. 19. · Multimed Tools Appl

Multimed Tools Appl (2018) 77:11807–11821

An optimized real time algorithm for window frostformation suited to mobile devices

Jaeho Im1 ·MyungJin Choi1 · Jung Lee2 ·Chang-Hun Kim1

Received: 17 October 2016 / Revised: 4 May 2017 / Accepted: 4 May 2017 /Published online: 18 May 2017© Springer Science+Business Media New York 2017

Abstract We propose a real time simulation for window frost formation on mobile devicesthat uses both particles and grids. Previous ice formation methods made heavy demands onboth memory and computational capacity because they were designed for a desktop envi-ronment. In this paper, a frost skeleton grows around a location touched by the user usingparticles, and the ice surfaces are constructed using a grid. Using a nonlattice random-walk technique, the frost skeleton grows freely and naturally. A hash grid technique isused to search efficiently for neighbor particles during the crystallization process. Finally,some 2.5D details are added to the ice skeleton by adjusting the height of the grid ver-tices around the skeleton. Experiments show that our method creates realistic frost in realtime. Our method can be used to express ice formation effects in touch-based mobile deviceapplications such as weather forecasts or games.

Keywords Window frost · Ice formation · Mobile device

1 Introduction

As high-performance mobile devices have developed, their available memory and com-putational resources have increased significantly. This has made mobile-based physicssimulations feasible. Stanton et al. [21] proposed a water simulation method for a mobile

� Chang-Hun [email protected]

Jaeho [email protected]

1 Korea University, 407B Woojung Building, Anam-dong 5(o)-ga, Seongbuk-gu, Seoul 136-713,Republic of Korea

2 Hallym University, 1303 Engineering Building, 1 Hallymdaehak-gil, Chuncheon, Gangwondo24252, Republic of Korea

DOI 10.1007/s11042-017-4819-2

Page 2: An optimized real time algorithm for window frost formation suited to mobile deviceskucg.korea.ac.kr/new/seminar/2019/paper/pdf-2019-03-14.pdf · 2019. 3. 19. · Multimed Tools Appl

11808 Multimed Tools Appl (2018) 77:11807–11821

environment that used input from a gyro-sensor to simulate the water movement. However,their algorithm was data driven, rather than being physics based.

There are two main requirements for performing physics-based simulation on mobiledevices. First, real time performance, i.e. responding to user input instantly, is very impor-tant. Second, the presentation quality should be convincing. Conventional physics-basedsimulations for desktop computers have involved enormous numbers of particles, a high-resolution simulation grid, and heavy computational costs. Despite the recent advances inmobile devices, it remains impossible to run physics-based simulations interactively. Inaddition, the battery power required is considerable and battery lifetime might be shortenedwith the increased CPU usage.

A study to express Window frost was proposed by Kim et al. [10]. In this technique, thediffusion limited aggregation (DLA) and the stable fluid technique [20] are used to simulatethe ice generated and grown on arbitrary planes. However, in this technique, stable fluidsimulation using a high-resolution grid is required to obtain high-quality results, so thatthere is a need for high computational cost. Due to the nature of mobile devices that need tooperate in real time using limited resources, algorithms that require high computational costare not suitable. We propose a physics-inspired frost-formation method for mobile devicesby optimizing the formation process of Kim et al.’s particle-based method [10]. Unlike Kimet al.’s technique, our technique can express natural ice growth without using a stable fluidsolver. It is also possible to find adjacent particles quickly and efficiently by proposing afreezing candidate area. Because window frost is created and grows on plane surfaces, itis suited to the 2D screen of mobile environments and could be used as a lock screen orfor touch effects. Although our method is not entirely physics based, we can guarantee realtime performance and can provide some photorealistic results (See Fig. 1).

Our contributions are as follows.

– A dynamic and natural result is acquired by moving water particles randomly incontinuous space, not within a discrete grid.

– Our method requires relatively small resources because of its local-grid-based remesh-ing simulation.

– High-quality frost is expressed by applying ice shape patterns to an ice skeleton createdby water particles.

The remainder of the paper is organized as follows. Section 2 describes the previous liter-ature related to a problem. Section 3 introduces techniques for efficiently creating window

Fig. 1 Our results on a mobile device (left) and actual image (right)

Page 3: An optimized real time algorithm for window frost formation suited to mobile deviceskucg.korea.ac.kr/new/seminar/2019/paper/pdf-2019-03-14.pdf · 2019. 3. 19. · Multimed Tools Appl

Multimed Tools Appl (2018) 77:11807–11821 11809

frost on mobile devices. Section 4 will compare our results to the performance of previousresults. Section 5 provides final conclusions and directions for future work.

2 Related work

Kharitonsky et al. [9] introduced a simplified method for creating icicles. Gagnon et al. [3]proposed an interactive icicle formation method that improves the performance. Kim et al.[10] proposed a method that creates ice on random surfaces by combining a Lie algebramethod [23], a phase-field approach [4], and a stable fluid solver [20]. Kim et al. [11]proposed a method for producing stalactite-shaped icicles by solving the Stefan problem.Ishikawa et al. [6] expressed glazed frost via supercooling effects using the fluid-implicitparticle method of Zhu and Bridson [24].

Marechal et al. [13] proposed a voxel-based method for expressing large-scale winterscenes as melted snow or frozen water. Their method established an accurate phase-transition model by applying a latent-heat technique. Iwasaki et al. [7] proposed usingsmoothed-particle hydrodynamics in their small-scale ice melting simulation method. Itsimulated the effects of water-to-ice or ice-to-water transitions on ice surfaces using aphase-transition model. Festenberg and Gumhold [2] expressed accumulated snow on acomplicated object such as a snow bridge by constructing height-span maps. Reynolds et al.[18] proposed real time simulation of snow accumulating in a dynamic 3D environmentusing a height map. Stomakhin et al. [22] implemented snow dynamics using a material-point method and semi-implicit methods. Their methods were used to produce effects in thefamous animated film ‘Frozen’ (2013).

Carte [1] studied the motion of air bubbles when ice is created. Seipel and Nivfors [19]proposed the real time formation of an opaque area using textures, while expressing reflec-tion and refraction effects. Madrazo et al. [12] created an opaque area by simulating thedissolved air emitted from ice–water interfaces using a grid-based method. Nishino et al.[17] expressed an opaque area by considering pressure and freezing speed. Im et al. [5] pro-posed a particle–grid hybrid method that created an opaque area in an object with a stablevolume. Miao and Xiao [15] proposed a particle-based ice freezing model that created air bub-bles dynamically by solving for heat conduction and air diffusion based on fluid dynamics.

3 Algorithm

This section introduces techniques for efficiently creating window frost on mobile devices.First, Section 3.1 defines the terms to describe our technique. Section 3.2 describes thewhole process of our technique. Section 3.3 describes the creation of the starting point ofthe window frost, and Section 3.4 describes the method of accelerated generation of windowfrost optimized for mobile devices. Finally, Section 3.5 introduces a rendering technique forrealistically representing the ice skeleton generated by our technique.

3.1 Definition

Freezing area When a water particle enters a freezing area, it changes into a crystal parti-cle. Kim et al. [10] determined the freezing area by combining a phase-field equation witha stable fluid solver. Because they performed heat transfer using an advection term, someregions far away from the crystal particle could be frozen via external forces such as wind.To improve performance in our method, the freezing area is restricted to a range hc aroundthe crystal particle and external forces are ignored.

Page 4: An optimized real time algorithm for window frost formation suited to mobile deviceskucg.korea.ac.kr/new/seminar/2019/paper/pdf-2019-03-14.pdf · 2019. 3. 19. · Multimed Tools Appl

11810 Multimed Tools Appl (2018) 77:11807–11821

Freezing candidate area This is the area adjacent to a freezing area, where the chancesare high that water particles are frozen. It is inefficient to calculate the freezing possibilityof every water particle at each time step. We improve the performance by considering waterparticles only in the freezing candidate area.

Crystal particle When a water particle enters a freezing area, it becomes a new crystalparticle, which creates a new freezing area and constructs an ice skeleton by connecting tothe existing crystal particles. The freezing candidate area is updated whenever a new crystalparticle is created.

Active area This is a local simulation area where a water particle is created, moves, andchanges into a crystal particle. Ice growth occurs only in an active area. If a water particleleaves an active area, it is removed and recreated inside the active area.

3.2 Overview

Our algorithm is composed of initialization, ice growth, and visualization stages (see Fig. 2).Seed crystal particles are planted by user input and active areas are created around them.Water particles are then created according to the humidity and positioned randomly withinthe active area.

During the ice growth process, ice grows along with the water particles and hash gridsare updated. A hash grid is updated according to the freezing candidate areas of the crystalparticles. A water particle moves via a random-walk technique. If it enters a freezing candi-date area, its presence within the freezing area is checked. A water particle in a freezing areais frozen into a crystal particle. A new crystal particle is connected to the existing crystalparticles and forms an ice skeleton. If it were too far from the existing particles, the qualityof the ice skeleton would be degraded. To restore skeleton quality in this case, upsamplingis performed by adding some particles between the new and the existing crystal particles.

Fig. 2 Algorithm flow

Page 5: An optimized real time algorithm for window frost formation suited to mobile deviceskucg.korea.ac.kr/new/seminar/2019/paper/pdf-2019-03-14.pdf · 2019. 3. 19. · Multimed Tools Appl

Multimed Tools Appl (2018) 77:11807–11821 11811

To create ice geometry during the visualization process, sharp features are added to theice skeleton and bumpy surfaces are constructed. After constructing and rendering the icegeometry, the number of water particles is updated according to the humidity.

Because our method performs both ice growth and visualization at each time step, it ispossible to watch the ice growth in real time. The user can affect the ice growth process inreal time by planting a seed crystal particle during the simulation. In addition, it is possibleto create multiple ice areas.

3.3 Initialization

During the initialization process, a hash grid and a geometry grid are constructed. The hashgrid is composed of N × M cells. If the resolution of the hash grid is set to match thedisplay resolution, the computational cost increases significantly. Therefore, we adjust thegrid resolution by using a freezing area radius hc that is specified by the user. Therefore,

N = w

2hc

, (1a)

M = h

2hc

, (1b)

where N and M are the width and height of the hash grid, respectively. Parameters w and h

are the width and height of the mobile display, respectively, while hc is used as the radius ofa freezing area within which to perform phase transitions during the crystallization process,and as a criterion for generating bumpy surfaces during the visualization process.

Whenever the user touches a specific location, a new seed crystal particle is created,together with its active area, at that location.

3.4 Ice growth simulation

In the ice growth simulation stage, it simulates the generation and growth of ice. In this step,an active area is created around the point entered by the user, and all water particles in theactive area move by random walk. When a water particle enters a freezing area of a crystalparticle, its state changes to a crystal particle. In our technique, freezing candidate area wasset using a hash grid to check whether the water particle was located in the freezing area ofthe crystal particle. Compared to inspecting all nine neighboring cells (27 in 3D) in orderto search for adjacent particles in a general particle-based fluid simulation, our methodinspects only the region set as the freezing candidate area, and it is possible to rapidly detectadjacent particles and grow ice.

3.4.1 Freezing candidate area update

Ice growth simulation first begins with the process of updating the freezing candidate areas.During this process, freezing candidate areas are added using the freezing areas of crystalparticles and updated to the hash grid.

As described in Section 3.1, a freezing candidate area is an area where the chances arehigh that water particles will be frozen. It is specified as a collection of hash-grid intersec-tions with freezing areas (see Fig. 3c). In other words, a water particle cannot be frozenoutside a freezing candidate area. The hash grid stores state values for freezing candidate

Page 6: An optimized real time algorithm for window frost formation suited to mobile deviceskucg.korea.ac.kr/new/seminar/2019/paper/pdf-2019-03-14.pdf · 2019. 3. 19. · Multimed Tools Appl

11812 Multimed Tools Appl (2018) 77:11807–11821

Fig. 3 a Hash grid and indices assigned to the simulation space. b Freezing areas for crystal particles (redcircles). c Freezing candidate areas (yellow grid: the freezing candidate area updated up to the previous step,purple grid: the freezing candidate area to be newly updated in the current simulation step). d State valuesfor the hash grid and crystal particle index

areas and the indices of crystal particles affecting the freezing candidate areas. In Fig. 3,P4–P8 are the indices of the crystal particles. Since a crystal particle is stored in an arraywhenever it is newly created, index means the index of the array of crystal particles. If anarea corresponding to a node of the hash grid becomes a freezing candidate area, its statevalue is set to 1. Otherwise, it is set to 0 (see Fig. 3).

3.4.2 Random walk

After this step of updating the freezing candidate areas, water particles are created in theactive areas. In the lattice model, the movement directions for water particles are restrictedto four directions, i.e., left, right, up, and down, which may cause artifacts in the ice growthresults. In this paper, water particles move by the nonlattice random-walk technique ofMeakin [14]. Using the nonlattice structure, a water particle can move freely within a rangeof radius r at each frame. Because of this high degree of freedom of motion, the ice growthis not restricted.

The position of a water particle is determined as

Xt+1w = Xt

w + MRotR, (2a)

MRot =(cos θ, − sin θ

sin θ, cos θ

), (2b)

where Xtw and Xt+1

w are the positions for the current and next time steps, respectively. R is a2D vector (a, 0), where a is a random value between 0 and r . r is the value specified by theuser before the simulation is performed. The parameter θ is a random value between 0 and2π . Based on (2), a water particle moves to a new random position. If it is located outside anactive area, it is removed and recreated within the active area, but not in a freezing candidatearea (see the white hash grid in Fig. 3d).

3.4.3 Crystallization

If a water particle reaches a freezing area after the random walk, it is converted into a crystalparticle (see Fig. 4). This process is called crystallization.

Page 7: An optimized real time algorithm for window frost formation suited to mobile deviceskucg.korea.ac.kr/new/seminar/2019/paper/pdf-2019-03-14.pdf · 2019. 3. 19. · Multimed Tools Appl

Multimed Tools Appl (2018) 77:11807–11821 11813

Fig. 4 Illustration of the crystallization process (blue dots: water particles, orange dots: crystal particles,dotted circles: freezing areas). a A water particle moves via a random walk. b A water particle reaches afreezing area. c A water particle is converted into a crystal particle. d A new freezing area is created aroundthe location of the newly converted crystal particle

First, the hash-grid key for the water particle is calculated based on its location. It ischecked for having entered a freezing candidate area by investigating the state value of thehash grid. If it belongs to a freezing candidate area, it is checked for being inside a freezingarea by calculating the distances to neighboring crystal particles stored in the hash-gridarray. If the distance between a water particle and a crystal particle is lower than hc, thewater particle is converted into a crystal particle. For small hc values, the ice will growslowly but densely.

3.4.4 Crystal particle upsampling

If hc increases, the ice will grow faster but a coarse ice skeleton will be constructed withlarge distances between adjacent crystal particles. A coarse ice skeleton will lead to the lossof sharp features during the reconstruction of the ice geometry. To improve the details ofice surfaces, crystal particles can be upsampled in our method. Our upsampling techniqueis divided into the two steps of partition and insertion. In the partition stage, the locations

Page 8: An optimized real time algorithm for window frost formation suited to mobile deviceskucg.korea.ac.kr/new/seminar/2019/paper/pdf-2019-03-14.pdf · 2019. 3. 19. · Multimed Tools Appl

11814 Multimed Tools Appl (2018) 77:11807–11821

of upsample particles are determined by dividing the distance between two adjacent crystalparticles regularly. This is expressed as

Nu =⌊ | Xnc − Xoc |

D

⌋, (3)

Xkac = Xoc + k

Nu − 1(Xnc − Xoc)(k = 1, 2, · · · , Nu − 1), (4)

where Nu − 1 is the number of upsample particles, Xnc is the location of an upsampleparticle, Xoc is the location of the existing crystal particle nearest to Xnc, D is a constantvalue satisfying 0 < D < hc. D is the distance between upsample particles and is definedby the user prior to the simulation. Xk

ac is a location of the k-th upsample particle.Upsample particles are considered as a subset of the crystal particles. An upsample par-

ticle could be used as a crystal particle, but it would not significantly affect the final qualityand would require considerable additional memory and computational cost. Therefore, weuse such particles only when constructing ice skeletons and sharp features.

3.5 Visualization

In general, an ice crystal shows sharp features along the boundaries and bumpy surfacesfor the inner parts (see Fig. 5a). To express these features, we create sharp features alongthe ice skeleton and bumpy ice surfaces by applying the locations of crystal particles to thegeometry grid. During the rendering process, alpha blending is applied to the ice surfacesto express the semitransparency of the ice, and Phong shading is applied to sharp featuresand ice surfaces to express the ice reflection effect (See Fig. 5d).

3.5.1 Sharp feature generation

Sharp features in ice crystals are constructed using a pair of connected particles. First, amidpoint between the particles is created (see Fig. 6a). Next, two points are created in thedirection perpendicular to the line connecting the two particles (see Fig. 6b). The distancefrom the midpoint to the perpendicular point is heuristically determined as one and a halftimes the distance between the crystal particles. Then, the midpoint is elevated by half of thedistance between the crystal particles (see Fig. 6c). Finally, faces connecting the two crystalparticles and the three new vertices are created to express sharp features (see Fig. 6d).

Fig. 5 a An actual ice crystal (red circle: sharp feature, yellow circle: bumpy surface). b Sharp features byour method. c bumpy surfaces by our method. d Combined sharp edges and bumpy surfaces by our method

Page 9: An optimized real time algorithm for window frost formation suited to mobile deviceskucg.korea.ac.kr/new/seminar/2019/paper/pdf-2019-03-14.pdf · 2019. 3. 19. · Multimed Tools Appl

Multimed Tools Appl (2018) 77:11807–11821 11815

Fig. 6 Sharp feature construction process (a1 and a2 are upsampling particles, P1 is a crystal particle, m1and m2 are mid-point particles, s1 and s2 are perpendicular points)

3.5.2 Bumpy surface generation

To create bumpy surfaces, we use a simplified version of Kamal et al.’s terrain-generationmethod [8]. Their method constructs a terrain mesh efficiently by creating a random pla-nar mesh structure and elevating the height of its vertices. We create bumpy surfaces byelevating the vertices of the geometry grid (see Fig. 7).

Bumpy surfaces are constructed using crystal and upsample particles. First, verticeswithin a radius of hc from each particle are found and these vertices are elevated (see Fig. 7).The elevation amount is determined by a user parameter in this paper. By applying the sameprocess to every crystal and upsample particle, bumpy ice surfaces are acquired very fastand efficiently (see Fig. 7f).

4 Results

Our experiments were performed on a Samsung Galaxy S5. To implement our method, weused Android NDK and the shader language of OpenGL ES for rendering.

It is important for the mobile device to maintain a performance of about 25 fps due tothe fact that it must respond to the user’s input promptly. However, at a frame rate of 25 fpsor more, the user does not feel a large difference visually, and causes unnecessary compu-tational cost to render. For this reason, many mobile applications including our techniqueuse a fixed frame rate of 25 fps. Also, during the simulation, the memory usage is only verysmall, less than 5 MB.

Parameters affecting the results were the radius hc of the freezing area, the distanceD between upsample particles, and the humidity. Results for various parameter values arepresented in Fig. 8, The parameters used in the result are written in Table 1.

Page 10: An optimized real time algorithm for window frost formation suited to mobile deviceskucg.korea.ac.kr/new/seminar/2019/paper/pdf-2019-03-14.pdf · 2019. 3. 19. · Multimed Tools Appl

11816 Multimed Tools Appl (2018) 77:11807–11821

Fig. 7 Bumpy surface construction process (blue particle: crystal particle, red dot: vertex of geometry grid)

If D is too small, few sharp features are shown and bumpy surfaces appear extensively.For large D values, very few bumpy surfaces appear because of the coarse distribution ofcrystal particles and large sharp features will be created (see Fig. 8 top).

If hc is too small, the ice grows slowly and the sharp features become very small. Thisleads to a large computational cost. The ice will grow fast under large values of hc. However,the sharp features constructed will be very large because of the large distance betweencrystal particles. This leads to artifacts at the ice center (see Fig. 8 middle).

If the number of water particles increases because of increased humidity, the ice willgrow quickly and more densely at the ice center. However, large humidity values lead to alarge computational cost because many water particles will be simulated at the same time(see Fig. 8 bottom).

Our method is about six times faster than a general hash-grid method, which wouldusually investigate nine cells to find adjacent particles in a fluid simulation such assmoothed-particle hydrodynamics [16]. In the case of techniques using a general hashgrid, the presence of crystal particles in adjacent cells is checked to freeze the water par-ticles. Therefore, the larger the number of water particles, the more computation time isrequired. The maximum number of water particles generated in our technique is determinedby humidity. Because the number of water particles decreases as the simulation progresses,the number of tests of adjacent cells also decreases. Therefore, the simulation step and theprocessing time are inversely proportional to each other. In contrast, our method checks awater particle only if it comes within the freezing candidate area and it is efficient becausewe investigate only the one hash grid where the particle is located (see Fig. 9). All simula-tions were performed on a 760×1280 grid and wemeasured the computation times, omittingthe visualization process. The general hash-grid method requires much computation timebecause of the large area to be examined when the ice is first created. In contrast, our methodis much faster because ice grows only in the freezing candidate areas. In addition, Kim

Page 11: An optimized real time algorithm for window frost formation suited to mobile deviceskucg.korea.ac.kr/new/seminar/2019/paper/pdf-2019-03-14.pdf · 2019. 3. 19. · Multimed Tools Appl

Multimed Tools Appl (2018) 77:11807–11821 11817

Fig. 8 Results for various parameter values. (top: sharp features by varying D, middle: sharp features byvarying hc , bottom: both sharp features and bumpy surfaces by varying Humidity)

et al.’s method [10] required over four minutes for the simulation process alone, whereasour method deals with both simulation and rendering processes in real time to providephotorealistic results (see Fig. 1).

Table 1 Simulation parameters

a-1 a-2 a-3 b-1 b-2 b-3 c-1 c-2 c-3

D 1.0 2.5 5.0 3.0 7.0 10.0 7.0 7.0 7.0

hc 10.0 10.0 10.0 3.0 7.0 10.0 7.0 7.0 7.0

Humidity 3,000 3,000 3,000 3,000 3,000 3,000 500 3,000 5,000

Page 12: An optimized real time algorithm for window frost formation suited to mobile deviceskucg.korea.ac.kr/new/seminar/2019/paper/pdf-2019-03-14.pdf · 2019. 3. 19. · Multimed Tools Appl

11818 Multimed Tools Appl (2018) 77:11807–11821

Fig. 9 Simulation time comparison

5 Conclusions and future work

We propose a physics-inspired method for real time window frost formation in a mobiledevice environment. Ice grows by random-walk movement of water particles and the useof freezing candidate areas is proposed to improve the performance of the ice growth pro-cess. Sharp features around ice boundaries are created using an ice skeleton constructed byconnecting adjacent crystal and upsample particles. Bumpy ice surfaces are also visualizedeffectively by adapting Kamal et al.’s terrain-generation method to the mobile device envi-ronment. Experiments show that our method creates window frost ices very efficiently andrealistically.

Although our method is not physically accurate, it produces plausible results similarto actual images and is suited to real time performance on mobile devices. Moreover, theproposed hash-grid method can be extended to the acceleration of particle-based physicssimulations. In future work, we plan to experiment with various touch effects according tothe actual temperature acquired from real time weather data and provide a lock screen withfrost-related visual effects.

It is difficult to show the ice growing permanently around a seed crystal as in Kim et al.’smethod [10], because the maximum range of ice growth is restricted to guarantee real timeperformance. Moreover, because the computational cost increases significantly as the max-imum range of ice growth increases, we plan to improve the performance by using parallelprogramming based on OpenCL.

Acknowledgements This research was supported by Basic Science Research Program through theNational Research Foundation of Korea (NRF), funded by theMinistry of Education, Science, ICT and FuturePlanning (NRF-2017R1A2B2005380) and Institute for Information & Communications Technology Pro-motion (IITP) grant funded by the Korea government (MSIP; 2016-0-00285, High performance computing[HPC] based rendering solution development) and Korea Creative Content Agency(KOCCA) grant fundedby the Korea government(MCST) (2015-0-00060, Developing the technology of open composable contenteditors for realistic media) and Business for Cooperative R&D between Industry, Academy, and ResearchInstitute funded P Korea Small and Medium Business Administration (Grant C0443008).

Page 13: An optimized real time algorithm for window frost formation suited to mobile deviceskucg.korea.ac.kr/new/seminar/2019/paper/pdf-2019-03-14.pdf · 2019. 3. 19. · Multimed Tools Appl

Multimed Tools Appl (2018) 77:11807–11821 11819

References

1. Carte AE (1961) Air bubbles in ice. Proc Phys Soc 77(3):757. http://stacks.iop.org/0370-1328/77/i=3/a=327

2. Festenberg NV, Gumhold S (2011) Diffusion-based snow cover generation. Comput Graphics Forum30(6):1837–1849. doi:10.1111/j.1467-8659.2011.01904.x

3. Gagnon J, Paquette E (2011) Procedural and interactive icicle modeling. Vis Comput 27(6):451–461.doi:10.1007/s00371-011-0584-9

4. Grinstein G, Mazenko G (1986) Directions in condensed matter physics: memorial volume in honor ofShang-keng Ma, vol 1. World Scientific

5. Im J, Park H, Kim JH, Kim CH (2013) A particle-grid method for opaque ice formation. ComputGraphics Forum 32(2pt3):371–377. doi:10.1111/cgf.12057

6. Ishikawa T, Dobashi Y, Yue Y, Kakimoto M, Watanabe T, Kondo K, Iwasaki K, Nishita T (2013) Visualsimulation of glazed frost. In: ACM SIGGRAPH 2013 Posters, SIGGRAPH ’13. ACM, New York,pp 14:1–14:1. doi:10.1145/2503385.2503400

7. Iwasaki K, Uchida H, Dobashi Y, Nishita T (2010) Fast particle-based visual simulation of ice melting.Comput Graphics Forum 29(7):2215–2223. doi:10.1111/j.1467-8659.2010.01810.x

8. Kamal K, Kaykobad M (2008) Generation of mountain ranges by modifying a controlled terrain gener-ation approach. In: 11th international conference on computer and information technology, 2008. ICCIT2008. pp 527–532, doi:10.1109/ICCITECHN.2008.4803058

9. Kharitonsky D, Gonczarowski J (1993) A physically based model for icicle growth. Vis Comput10(2):88–100. doi:10.1007/BF01901945

10. Kim T, Henson M, Lin MC (2004) A hybrid algorithm for modeling ice formation. In: Pro-ceedings of the 2004 ACM SIGGRAPH/eurographics symposium on computer animation, SCA’04. Eurographics Association, Aire-la-Ville, Switzerland, pp 305–314. doi:10.1145/1028523.1028564

11. Kim T, Adalsteinsson D, Lin MC (2006) Modeling ice dynamics as a thin-film stefan problem. In:Proceedings of the 2006 ACM SIGGRAPH/eurographics symposium on computer animation, SCA’06. Eurographics Association, Aire-la-Ville, Switzerland, pp 167–176. http://dl.acm.org/citation.cfm?id=1218064.1218087

12. Madrazo C, Tsuchiya T, Sawano H, Koyanagi K (2009) Air bubbles in ice by simulating freezingphenomenon. The Journal of the Society for Art and Science 8(1):35–42

13. Marechal N, Guerin E, Galin E, Merillou S, Merillou N (2010)Heat transfer simulation for modeling real-istic winter sceneries. Comput Graphics Forum 29(2):449–458. doi:10.1111/j.1467-8659.2009.01614.x

14. Meakin P (1983) Diffusion-controlled cluster formation in two, three, and four dimensions. Phys. Rev.A 27:604–607. doi:10.1103/PhysRevA.27.604

15. Miao Y, Xiao S (2015) Particle-based ice freezing simulation. In: Proceedings of the 14th ACM SIG-GRAPH international conference on virtual reality continuum and its applications in industry, VRCAI’15. ACM, New York, pp 17–22. doi:10.1145/2817675.2817676

16. Muller M, Charypar D, Gross M (2003) Particle-based fluid simulation for interactive applications.In: Proceedings of the 2003 ACM SIGGRAPH/eurographics symposium on computer animation.Eurographics Association, pp 154–159

17. Nishino T, Iwasaki K, Dobashi Y, Nishita T (2012) Visual simulation of freezing ice withair bubbles. In: SIGGRAPH asia 2012 technical briefs, SA ’12. ACM, New York, pp 1:1–1:4.doi:10.1145/2407746.2407747

18. Reynolds DT, Laycock SD, Day AM (2014) Real-time accumulation of occlusion-based snow. VisComput 31(5):689–700. doi:10.1007/s00371-014-0995-5

19. Seipel S, Nivfors A (2007) Real-time rendering of ice. In: Proceedings of the ninth IASTED internationalconference on computer graphics and imaging, CGIM ’07. ACTA Press, Anaheim, pp 60–66. http://dl.acm.org/citation.cfm?id=1710707.1710719

20. Stam J (1999) Stable fluids. In: Proceedings of the 26th annual conference on computer graphicsand interactive techniques, SIGGRAPH ’99. ACM Press/Addison-Wesley Publishing Co., New York,pp 121–128. doi:10.1145/311535.311548

21. Stanton M, Humberston B, Kase B, O’Brien JF, Fatahalian K, Treuille A (2014) Self-refining gamesusing player analytics. ACM Trans Graph 33(4):73:1–73:9. doi:10.1145/2601097.2601196

22. Stomakhin A, Schroeder C, Chai L, Teran J, Selle A (2013) Amaterial point method for snow simulation.ACM Trans Graph 32(4):102:1–102:10. doi:10.1145/2461912.2461948

Page 14: An optimized real time algorithm for window frost formation suited to mobile deviceskucg.korea.ac.kr/new/seminar/2019/paper/pdf-2019-03-14.pdf · 2019. 3. 19. · Multimed Tools Appl

11820 Multimed Tools Appl (2018) 77:11807–11821

Jaeho Im is Ph.D candidate in the the Department of Computer Science and Engineering at Korea University.He received the B.A. degree in the Department of Media at Soogsil University in 2010. He received M.S.degrees in the Department of Computer Science and Engineering at Korea University, in 2012. His currentresearch interests include fluid simulation and natural phenomenon modeling.

MyungJin Choi received the B.A. degree in the Department of Computer and Radio Communications Engi-neering at Korea University in 2013. His current research interests include fluid simulation and scientificvisualization.

23. Witten TA, Sander LM (1981) Diffusion-limited aggregation, a kinetic critical phenomenon. Phys RevLett 47:1400–1403. doi:10.1103/PhysRevLett.47.1400

24. Zhu Y, Bridson R (2005) Animating sand as a fluid. In: ACM SIGGRAPH 2005 Papers, SIGGRAPH’05. ACM, New York, pp 965–972. doi:10.1145/1186822.1073298

Page 15: An optimized real time algorithm for window frost formation suited to mobile deviceskucg.korea.ac.kr/new/seminar/2019/paper/pdf-2019-03-14.pdf · 2019. 3. 19. · Multimed Tools Appl

Multimed Tools Appl (2018) 77:11807–11821 11821

Jung Lee is an assistant professor in the department of convergence software in Hallym University. Hiscurrent research interests include fluid animation and augmented reality.

Chang-HunKim is a professor in the Department of Computer Science and Engineering at Korea University.His current research interests include fluid animation and mesh processing. He is also amember of IEEEComputer Society and ACM.