POV-Ray : Newsgroups : povray.binaries.images : Lost City : Re: Lost City Server Time
4 Nov 2024 13:44:54 EST (-0500)
  Re: Lost City  
From: Reactor
Date: 7 Apr 2009 17:05:01
Message: <web.49dbbf874279559f2c610b6a0@news.povray.org>
"Robert McGregor" <rob### [at] mcgregorfineartcom> wrote:
> In this WIP I've mesh-deformed the base terrain and added some underbrush and a
> foreground water surface (also quickly modelled in Wings).
>
> So, the basic composition is there - next up, the background water, sky,
> mountains, etc...
>
> :)



The water is kind of lifeless at this point.  I hope you use some media and
other tricks to make it more interesting.  I was experimenting with wings3D and
water a while ago.  I gave up mostly because of the large sizes of meshes that
resulted, and moved primarily toward heightfields and isosurfaces.

Of course, with wings, one can make a wave roll as it breaks, but animating it
would be... tricky.

Anyway, attached is a picture of a heighfield based water test I did fairly
recently.  Below is the code I used for the water.

// CODE:

#declare matMyWater =
material{
texture{

    pigment{ color rgbt <1,1,1,0.90> }

    finish{
        specular  1.0000
        roughness 0.0001
        reflection{ 0, 0.99 fresnel }
        conserve_energy
    }
  }

interior{
    ior 1.333
  #if( use_dispersion )
    dispersion 1.01
    dispersion_samples 11
  #end

#local mSamples = 15;
#local mVariance = 1/255;
#local mThickness = 2.5;
#local mAbsorptionColor = <1.00,0.00,0.25>;  // absorb more red and some blue
#local mAbsorptionGray  = <1.00,1.00,1.00> * 0.25;
#local mAbsorbV = vnormalize(mAbsorptionColor + mAbsorptionGray);
    media
    {
        intervals 1
        samples mSamples
        confidence 1 - mVariance
        variance mVariance
        absorption    color rgb mAbsorbV * mThickness // absorbing media, block
light of specified color
        scattering
        {
            1, color rgb <0.50,0.50,1.00> * mThickness / 25
            extinction 1.0     // for balancing amount of absorption [1.0]
        }
        method 3               // adaptive sampling
        aa_threshold 0.1     // accuracy threshold for method 3 [0.1]
        aa_level 4           // maximum recursion depth for method 3 [4]
        density{ color rgb <1,1,1> }
    }
  }
}


Post a reply to this message


Attachments:
Download 'water_media_test.jpg' (153 KB)

Preview of image 'water_media_test.jpg'
water_media_test.jpg


 

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.