POV-Ray : Newsgroups : povray.binaries.images : Beyond this point... : Re: Beyond this point... Server Time
9 May 2024 12:17:16 EDT (-0400)
  Re: Beyond this point...  
From: Thomas de Groot
Date: 27 Dec 2023 04:11:07
Message: <658bea2b$1@news.povray.org>
Op 26-12-2023 om 21:55 schreef Kenneth:
> Josh English <Jos### [at] joshuarenglishcom> wrote:
>> On 12/23/2023 4:32 AM, Thomas de Groot wrote:
>>>
>>> My last scene for this year...
> 
> Oooh, I like this. Very beautiful and peaceful, Thomas.
> 
>>
>> I really love the style of this. The trees have an almost painterly
>> quality to them instead of looking ray-traced. How did you pull that off?
> 
> That's exactly my impression too. Nicely done!
> 

Thank you indeed, Josh, Kenneth, much appreciated.

The trees are very simple in fact, and basically the result of their 
Arbaro origin which makes them very useful for large number use, more 
especially in backgrounds. However, to break the monotony of a single 
leaf colour, you need to introduce some variation.

For the Black Tupelo by Friedrich Lohmueller, the original is as follows:

// tree textures: ---------------------------------------
#declare Stem_Texture =
  texture{ pigment{ color rgb< 0.70, 0.56, 0.43>*0.25 }
           normal { bumps 1.00 scale <0.025,0.075,0.025> }
           finish { phong 0.2 reflection 0.00}
         } // end of texture
//-------------------------------------------------------
#declare Leaves_Texture_1 =
  texture{ pigment{ color rgbf< 0.27, 0.36, 0.0, 0.1>*1.4 }
           normal { bumps 0.15 scale 0.05 }
           finish { phong 1 reflection 0.00}
         } // end of texture
//--------------------------------------------------------
#declare Leaves_Texture_2 =
  texture{ pigment{ color rgbf< 0.25, 0.35, 0.0, 0.1>*1.4 }
           normal { bumps 0.15 scale 0.05 }
           finish { phong 0.2 reflection 0.00}
         } // end of texture
//--------------------------------------------------------
//--------------------------------------------------------------------------
#include "black_tupelo_15m.inc"
//#declare Tree_Height = black_tupelo_15_height; // // ~22.10  ft
//--------------------------------------------------------------------------
// tree with leaves

#declare Black_Tupelo =
    union{
           object{ black_tupelo_15_stems
                   texture{ Stem_Texture }
                 } //------------------------
           object{ black_tupelo_15_leaves
                   double_illuminate
                   texture{ Leaves_Texture_1 }
                   interior_texture{ Leaves_Texture_2 }
                 } //------------------------
       scale 1/3
       rotate <0,40,0>
       translate<0,0,0>
     } // end of union

Black_Tupelo
//--------------------------------------------------------------------------

I did not touch the Stem_Texture, nor did I touch the Leaves_Texture_2 
which represents the underside of the leaves. I could have done so and 
maybe I shall some day in the future to explore further possibilities.

So I first designed a leaf texture macro with randomizing possibilities:

//-------------------------------------------------------
#declare LeafPig =
pigment {
   granite
   color_map {
     [0.4 rgbf <RRand(0.3, 0.6, R), RRand(0.4, 0.7, R), 0.0, 0.1>*1.4]
     [0.7 rgbf <RRand(0.7, 0.6, R), RRand(0.4, 0.7, R), 0.0, 0.1>*1.4]
   }
   scale RRand(0.1, 5, R)
   warp {turbulence 0.5}
}


#macro LeafTex ()
   pigment {LeafPig}
   normal {bumps 11.5 scale 0.0001}
   finish {specular 0.5 roughness 0.001 diffuse 0.8}
#end
//--------------------------------------------------------

And finally, after including the tree mesh file, a tree macro which 
would take into account the randomizations in a trace loop (I used 1500 
trees in the scene):

//--------------------------------------------------------------------------
#include "black_tupelo_15m.inc"
//#declare Tree_Height = black_tupelo_15_height; // // ~22.10  ft
//--------------------------------------------------------------------------
// tree with leaves

#macro Black_Tupelo ()
#local Tupelo =
union {
   object {
     black_tupelo_15_stems
     texture {Stem_Texture}
   } //------------------------
   object {
     black_tupelo_15_leaves
     double_illuminate
     texture {LeafTex()}
     interior_texture {Leaves_Texture_2}
   } //------------------------
   scale 1/3
   rotate RRand(-179,180,R)*y
}
Tupelo
#end
//--------------------------------------------------------------------------

And then it is only a matter of calling the macro repeatedly:


object {Black_Tupelo()
   scale SomeRandomScale
   translate SomeRandomTranslate
}

Improvements pending obviously ;-)

-- 
Thomas


Post a reply to this message

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