Learn the science of clouds with Hou­dini

Create re­al­is­tic cu­mu­lus clouds

3D Artist - - CONTENTS -

In is­sue 116’s at­mo­spher­ics tu­to­rial we learned some ba­sic sci­en­tific as­pects of at­mo­spher­ics. one kind of phe­nom­ena was in­ten­tion­ally miss­ing from that be­cause this step-by-step is all about them: clouds. There are many kinds of clouds but we have cho­sen the most com­mon one, the cu­mu­lus, as the sub­ject of our study.

while we now use hou­dini not just for ex­per­i­ments but also for as­set cre­ation, in the end we can have a ver­sa­tile cu­mu­lus gen­er­a­tor pipe­line to create small clouds or a hero thun­der­storm for­ma­tion. hou­dini has a pro­ce­dural cloud toolset but our ap­proach in­volves dy­nam­ics be­cause we want to achieve a higher level of re­al­ism with the op­por­tu­nity for time­lapse an­i­ma­tion or to achieve a more nat­u­ral shot con­ti­nu­ity. This tu­to­rial isn’t in­tended to be ex­tremely ac­cu­rate from a sci­en­tific view­point but the 15 steps can be seen as an over­view. if you’re in­ter­ested, you’ll find ad­di­tional ma­te­ri­als on the au­thor’s artstation pro­file at artstation.com/scivfx.

01

Ob­serve cloud dy­nam­ics dur­ing spring in the north­ern hemi­sphere, we have more of a chance to ob­serve cu­mu­lus clouds. it’s worth ob­serv­ing them from above if we fly. we­b­cams with good sky views can also help us, es­pe­cially if we utilise a time-lapse video – this can be our se­cret weapon for dy­nam­ics ob­ser­va­tion. how­ever, on a hot­ter day, the way that these clouds are de­vel­op­ing can also be vis­i­ble to the naked eye. how­ever, as these clouds are vol­u­met­ric phe­nom­ena, we can’t ex­actly dis­tin­guish shapes from light and shadow ef­fects. it’s also worth ob­serv­ing how clouds can af­fect their en­vi­ron­ment. dis­cover which parts of the cloud are darker than the sky and by how much over on step 9.

02

Shape of clouds clouds are clas­si­fied on the ba­sis of two cri­te­ria: shape and height. Those at high al­ti­tude are cir­rus, cir­ro­stra­tus or cir­rocu­mu­lus. stra­tus clouds are the re­sult of slower, more sta­ble pro­cesses, thus their shapes are ho­mo­ge­neous and flat. on the other hand, cu­mu­lus clouds form in an un­sta­ble and/or tur­bu­lent en­vi­ron­ment, so they get their fluffy shape. it’s the same with mid-al­ti­tude clouds, al­to­stra­tus and al­tocu­mu­lus. our con­cern is with the more dy­namic low-level clouds, which are cu­mu­lus clouds. how­ever, ev­ery cloud is unique, so there are in-be­tween cat­e­gories like stra­tocu­mu­lus, and also dif­fer­ent va­ri­eties like al­tocu­mu­lus lentic­u­laris.

03

Pres­sure, tem­per­a­ture, den­sity These are the three prop­er­ties of air that we should keep in mind dur­ing this project. while grav­ity keeps air mol­e­cules stuck to earth, this grad­u­ally lessens the higher up we go as ev­ery mol­e­cule pushes the ones be­low to­wards the planet’s sur­face. how­ever, this se­vere ki­netic move­ment doesn’t al­low them to lie down on the sur­face as liq­uid wa­ter does. The tem­per­a­tures, pres­sures and den­si­ties are all in­ter­re­lated. in­deed, it’s the same as chang­ing the read­out of your bath­room scale by pulling your­self up, bounc­ing, or danc­ing on it with some­body else.

04

Eva­po­ra­tion and con­den­sa­tion air’s wa­ter con­tent comes from sur­face eva­po­ra­tion, fu­elled di­rectly by the en­ergy of the sun, or in­di­rectly by the wind, tran­spi­ra­tion of plants or wave splashes from the ocean. if the wa­ter is in the vapour state, it’s ba­si­cally in­vis­i­ble and needs a con­di­tion to con­dense and get the wa­ter con­tent to be nat­u­rally vis­i­ble. cu­mu­lus clouds do this with lo­calised con­vec­tive lift­ing – the un­even sur­face heats up the air above un­evenly, so the warmer ar­eas start to rise be­cause they ex­pand more and the den­sity gets lower. as they lift, the pres­sure and tem­per­a­ture lower and the wa­ter vapour mol­e­cules bounce less fre­quently, so they start to stick to­gether. To form con­sid­er­ably sized wa­ter droplets, they also need sur­faces – the con­den­sa­tion nu­clei.

05

Cloud base as we ob­serve real cu­mu­lus clouds, we can clearly see this height: these fluffy clouds have flat bot­toms, which are the lift­ing con­den­sa­tion lev­els. The tem­per­a­ture de­crease is the re­sult of the lower pres­sure at this height. in­stead of ex­act sci­en­tific sim­u­la­tion, we can sim­plify things to get more con­trol. Thus, in­stead of sim­u­lat­ing the air mass from the ground, it’s bet­ter to use a poly­grid at the in­tended height of our cloud base. it’s rec­om­mended to use real-world units, so around 1,000 hou­dini units (me­tres) is a good start. we can paint all the ini­tial phys­i­cal prop­er­ties on it, like tem­per­a­ture, humidity and ve­loc­ity, or use a fluid source with an­i­mated tex­tures.

06

Pyro solver a large cu­mu­lonim­bus, the ma­tured thun­der­storm ver­sion of the cu­mu­lus, is like an ex­tremely slowed down atomic bomb in terms of shape, ther­mo­dy­nam­ics and the amount of the en­ergy in­volved. Thus we can use the pyro solver in hou­dini to sim­u­late a birth of a cloud. The most im­por­tant pa­ram­e­ter is the buoy­ancy, which we should set care­fully. it is best to switch off all fea­tures at the be­gin­ning and then turn them on one by one, or use sep­a­rate mi­cro­solvers. our tem­per­a­ture and humidity source can be a par­ti­cle sys­tem emit­ted from the ground with wind and tur­bu­lence to be a bit more sci­en­tific and get a more chaotic spread.

07

La­tent heat and oth­ers This is an ex­tra boost for the up­lift­ing force – as the wa­ter con­denses, the en­ergy stored at the time of the eva­po­ra­tion re­leases. other fac­tors also af­fect the en­ergy bal­ance, like the ab­sorp­tion of the sun­light. even if just the few per cent of the ra­di­a­tion gets ab­sorbed, this is sig­nif­i­cant and so we should use the heat/ burn fea­ture of the pyro solver to mimic these ex­tra ef­fects above the cloud base. in this case, the wa­ter vapour is the fuel, la­tent heat is the heat and con­den­sa­tion is burn. we should switch on the ad­vect fuel on the com­bus­tion/fuel tab to lift the wa­ter vapour with the heat.

08 Com­plex­ity of cloud op­tics as we al­ready know how com­plex the scat­ter­ing of light by wa­ter droplets is, we should make an ef­fec­tive light­ing setup that is based on science but with sim­pli­fi­ca­tions and artis­tic con­trol. we should trust in our senses and ex­pe­ri­ences and rely on ob­ser­va­tions to com­pen­sate the un­achiev­able com­put­ing needs for brute force sim­u­la­tion. in clouds, it’s not just the scat­ter­ing of the in­com­ing light that is com­pli­cated, but the in­di­rect light events are or­ders of mag­ni­tude more com­pli­cated than in a usual fi­nal ren­der setup. ad­di­tion­ally, the mul­ti­ple scat­ter­ing makes clouds very white, so sin­gle scat­ter­ing is just a small part of the albedo of these clouds. in cu­mu­lus clouds, there are wa­ter droplets that are usu­ally small enough for light dif­frac­tion that add a bit of ad­di­tional com­plex­ity. 09

Vis­ual il­lu­sions clouds can have very bright and very dark ar­eas, and these ar­eas have ad­di­tional de­tails with much less dy­namic range. as a re­sult, the si­mul­ta­ne­ous per­cep­tion of the bright­est ar­eas with the de­tails in the dark­est is quite a hard task. our eyes can deal with these very well but they will en­hance them in or­der to be able to do so. ac­tu­ally, this en­hance­ment is sim­i­lar to those in­volved in hdr to Ldr con­ver­sions – a big ra­dius sharpen/un­sharpen mask or an in­verted glow – it’s just less ob­vi­ous. Pho­to­chem­i­cal film de­vel­op­ment also has sim­i­lar side ef­fects by its na­ture and it’s also an in­te­gral part of many pain­ters’ works. it’s im­por­tant to keep in mind that the small­est in­ten­sity change can have a sig­nif­i­cant vis­ual im­pact on our im­age, es­pe­cially in the mid-tone and dark ar­eas. we should be very care­ful to set the scene’s lin­ear in­ten­si­ties and colours, as well as the shading pa­ram­e­ters. 10

For­ward scat­ter­ing ver­sus mul­ti­ple scat­ter­ing for­ward scat­ter­ing is cru­cial for re­al­ism as we learned in is­sue 116, but the count­less pho­ton bounces in­side a cloud are just as im­por­tant. us­ing hou­dini’s cop nodes, we can un­der­stand some ba­sic con­cepts. we lay down schematic cloud roto shapes on this hdr im­age and use blur nodes to do the scat­ter­ing. for sin­gle scat­ter­ing, blend two of them to get an ac­cept­able re­sult. for mul­ti­ple scat­ter­ing, we use the Loop cop node. as we dive in­side, we can add a blur with some opac­ity. The it­er­a­tions pa­ram­e­ter of the Loop node is the depth of scat­ter­ing in this case. as we com­pare the two shapes, we can clearly see the most im­por­tant dif­fer­ence: the gra­di­ent with the sin­gle scat­ter­ing – which has just the sim­pli­fied for­ward scat­ter­ing lobe – is much steeper than the mul­ti­ple one, which is flat­tened out by the looped blur. around the sun, the edge with sin­gle scat­ter­ing is brighter. how­ever, the in­ner part con­ducts the light fur­ther, just as real clouds do. 11

Ba­sic light com­po­si­tion for fast re­sults, use solid ob­jects in­stead of vol­umes, and the most ef­fec­tive way is to con­vert our vol­ume ob­ject to a poly­gon. use a dif­fuse white shader or a sub­sur­face scat­ter­ing one to set up the sun­light and sky­light. The re­flec­tions from the ground are also im­por­tant, and all of these are in­cluded in hou­dini’s sky sys­tem. we can also use an hdr en­vi­ron­ment, with the bot­tom part pro­jected onto a ground plane. it’s im­por­tant to in­clude a draft ver­sion of the ef­fects of mul­ti­ple scat­ter­ing from the be­gin­ning, but with an emis­sion colour or a fast sub­sur­face scat­ter­ing to al­ter the mood a lot, mak­ing it prefer­able for artis­tic de­ci­sions.

12 Vol­ume shader tweaks af­ter we switch back to vol­ume ob­ject, we use hou­dini’s pyro shader ma­te­rial node be­cause it has some nice built-in fea­tures like pro­ce­dural tex­tures. how­ever, af­ter we switch off all emis­sion-re­lated ef­fects, we should tweak the node net­work in­side to get a phys­i­cally plau­si­ble phase func­tion. Pyro shader core has a sim­ple phase func­tion but we can du­pli­cate it and use a layer mix node. The first phase should be very close to 1, like 0.98; the other can be a bit above half. if you pre­fer to use more low-level shading nodes, you can tweak a Vol­ume shader core node in­stead and mix just the phase func­tions in­side it. we can’t get sci­en­tif­i­cally ac­cu­rate re­sults with these as the phase func­tion in real clouds is much more com­plex and de­pends on droplet size, which is be­yond our scope now. 13

In­di­rect light­ing with Mantra’s brute force fea­tures, the ren­der­ing of mul­ti­ple scat­ter­ing in clouds can be ex­tremely slow. we need as many light bounces as pos­si­ble for mul­ti­ple scat­ter­ing to sim­u­late the light con­duct­ing ef­fects of the real clouds. how­ever, the spa­tial ac­cu­racy isn’t so im­por­tant for the in­di­rect light­ing, thus we can use the Gi Light node in hou­dini to sim­u­late and store a pho­ton map. it’s a bit hard to un­der­stand, but we will utilise it with the di­rect Global Pho­ton Map set­ting, which means us­ing a pho­ton map only. The in­di­rect… set­ting means util­is­ing a pho­ton map cal­cu­la­tion first, then a fi­nal gath­er­ing cal­cu­la­tion when it comes to ren­der­ing, which is still slow for us. we can ac­tu­ally take ad­van­tage of the in­ac­cu­racy of the pho­ton map with the di­rect… set­ting. if we set the fil­ter­ing value to a high one, ei­ther the pre­filter or the fil­ter, which is the on-the-fly ver­sion, the ef­fect is the same. This spa­tially blurs the light­ing ef­fects of the pre­cal­cu­lated pho­tons, adding fur­ther re­al­ism and com­pen­sat­ing for the depth lim­its of the pho­ton sim­u­la­tion. 14

Comp dur­ing the 3d look-dev, there is a point when we can’t get bet­ter re­sults with the new it­er­a­tions or it gets less good. This is the point when it’s rec­om­mended to ren­der out as much aov as pos­si­ble and tweak the im­age fur­ther in 2d. we can add slight blur nodes for ad­di­tional scat­ter­ing ef­fects and also colour grade aovs dif­fer­ently, and bal­ance them to get con­vinc­ing re­sults. for aerial per­spec­tive ef­fects, we can use the depth aov as a mask, firstly for a mul­ti­ply node with a red or am­ber colour, then for an add node with a less sat­u­rated blueish hue. This is a cheap sim­u­la­tion of the scat­ter­ing of the at­mos­phere. at the end, it’s im­por­tant to add the usual comp steps – like fringe, glare, glow and grain – and use proper colour man­age­ment. how­ever, the best thing to do is to do slap comps from the be­gin­ning, and not to com­pen­sate the lack of lens ef­fects with light­ing and shading. 15

Sci­en­tific con­clu­sion There have been great ex­am­ples in re­cent years of sci­en­tif­i­cally based ap­proaches help­ing artists achieve high qual­ity and re­al­is­tic clouds both in VFX and an­i­ma­tion films. in The Good Di­nosaur, Pixar Tds and artists cre­ated a pipe­line that was based on real cloud satel­lite maps, sim­u­la­tions and ac­cu­rately shaded but art-di­rectable cloud as­sets. in At­trac­tion, Main road Post artists also used hou­dini to sim­u­late cu­mu­lus clouds and used cus­tom-phase func­tion shading for re­al­is­tic cloudy back­grounds in the full cg jet fighter scenes.

08

09

11

10

12

15

14

13

Newspapers in English

Newspapers from UK

© PressReader. All rights reserved.