//nebula //you only need this if you want stars inside the nebula. //#version unofficial megapov 1.0; //stars /* #local rs = seed(17); #local nStar = 0; #while ( nStar < 1000 ) glow { type 2 location (-.5)*<4000,4000,4000> size 3 radius 20 //cutoff, makes no significant difference to speed. fade_power 2 color rgb *.2 + .8 translate z*1600 } #local nStar = nStar + 1; #end */ sky_sphere { pigment { spotted scale .002 poly_wave 20 colour_map { [0 rgb 0] [1 rgb 3] } } } //nebula #macro m_pNebula(fTransmit) spotted scale 3//.6 colour_map { [0 rgb <1,.6,.1> transmit fTransmit] [.4 rgb <1,.1,.1> transmit fTransmit] [1 rgb <.1,.1,1> transmit fTransmit] } #end #declare fThreshold = .2; #declare fDensity = 5; #macro m_pNebulaForm() pigment_pattern { spherical scale 6 turbulence .8 poly_wave 2 //CHANGE THE OTHER ONE! NOT THIS!! pigment_map { [0 rgb 0] [1 granite scale 1/3 //translate 2 scale 6 poly_wave fThreshold pigment_map { [.0 rgb 1] [.8 rgb 0.02] [1 rgb 0] } //pigment_map ] } //pigment_map } #end light_group { sphere { 0, 10 hollow on material { texture { pigment { rgbt 1 } } interior { media { scattering { 1, rgb fDensity //set base density here, set colour in the density section. The two get multiplied together when used. extinction 1 //let it glow a little } absorption 0 emission 0 density { m_pNebulaForm() density_map { [0 rgb 0] [1 m_pNebula(0)] } //density_map } //density } //media } //interior } //material scale 40 } //sphere light_source { <-1,1,0>*1000 rgb 1.2 } } camera { // spherical right x*image_width/image_height up y direction z*.7 // angle 360,180 // angle 120*image_width/image_height,120 #declare CamSpline = spline { natural_spline 0, <80,0,-170> //green 1, <40,-20,-160> //blue 2, <0,0,-120> //cool swirly feature 3, <0,-10,-80> 4, <0,0,0> 6.21, <-50,100,200> //exit, stage left //<50,40,0> //nice dark and light thing } location CamSpline(clock) look_at CamSpline(clock+.2) }