POV-Ray : Newsgroups : povray.binaries.images : Sandstone blocks Server Time
15 Nov 2024 17:12:24 EST (-0500)
  Sandstone blocks (Message 1 to 10 of 28)  
Goto Latest 10 Messages Next 10 Messages >>>
From: PM 2Ring
Subject: Sandstone blocks
Date: 27 Apr 2006 13:35:01
Message: <web.4450ffd4fe18178f76ba2c900@news.povray.org>
Hi, everyone!

I've been so busy at work this year I've barely had time to lurk here. And
I've been spending most of my spare time at home learning Unix, and haven't
had much time for raytracing. Which is kind of ironic, considering I
installed Unix mostly because of POV. :)

I have done some things with POV, though. I was trying to make more
realistic sand, when I stumbled upon this texture, which immediately
reminded me of sandstone. I haven't done much with the colours yet, but I
hope these images show the potential.

I have a funny monitor. You may need to drop the brightness &/or gamma to
see my images the way I do.


Post a reply to this message


Attachments:
Download 'sandstoneaw1.jpg' (243 KB)

Preview of image 'sandstoneaw1.jpg'
sandstoneaw1.jpg


 

From: PM 2Ring
Subject: Re: Sandstone blocks
Date: 27 Apr 2006 13:50:01
Message: <web.445103b51843be3376ba2c900@news.povray.org>
// Persistence of Vision Ray Tracer Scene Description File
// File: Sandstone.pov
// Vers: 3.6
// Desc: Pyramid of sandstone blocks
// Date: 2006.02.06
// Auth: PM 2Ring
//
//  -d +A0.2 +AM2 +R2
//

#include "functions.inc"

global_settings {
  assumed_gamma 1.0
}

//Block dimensions etc
#declare W = 1.5;
#declare D = 1.5;
#declare H = 0.75*1.25;
#declare ROUGH = 0.30*.75;        //Bump height      //0.45, 0.22
#declare BUSY = 0.40;           //Bump period
#declare M=0.975; //1.0075;       //Mortar space adjustment
//#declare M=1.05;       //Mortar space adjustment

//Number of levels in pyramid. Also controls floorsize & light & camera
distance, along with H.
#declare LEVELS=12;

//---The functions--------------------------------------------------------

#declare f_Sandstone = function{f_wrinkles(x*BUSY, y*BUSY, z*BUSY)}

#declare f_Ground =
function{
   0.125*f_noise3d(x*1.5, y*1.5, z*1.5)
 + 0.005*f_noise3d(x*70,  y*60,  z*70)
}

//---The textures---------------------------------------------------------
#declare SkyBlue = rgb<.035, .27, .67>+.125;
#declare Sandy = rgb<1, .9, .675>;

#declare FSand1 =
finish{
  diffuse 0.75 ambient 0.125
  specular 1 roughness 1e-3
}

#declare FSandstone =
finish{
  diffuse 0.75 ambient 0.05
}

#declare NSand1 = normal{granite 0.125 scale 1.5E-3}

#declare TSand1 =
texture{
  pigment {Sandy }
  finish{FSand1}
  //normal{NSand1 .15}
}

#declare Transmit = .8;
#declare CM_Sandstone =
colour_map{
  [0.3 rgbt <1, 1, 1, 1.2*Transmit>]
  [0.4 rgbt <1, 0, 0, Transmit>]
  [0.41 rgbt <0.5, 0.2, 0.1, .5*Transmit>]
  [0.42 rgbt <1, 0, 0, .75*Transmit>]
  [0.6 rgbt <1, 0.5, 0, Transmit>]
  [0.7 rgbt <1, 1, 1, .5*Transmit>]
}

#declare TSandstone =
texture{
  pigment {Sandy}
  finish{FSandstone}
}

#declare TStain = texture{
  pigment{
    wrinkles
    turbulence 0.1875
    colour_map{CM_Sandstone}
    //scallop_wave

    translate 0.95*1.1
    rotate <10, 75, 25>
    scale 1.5*W*7
  }
  finish{FSandstone}
}

#declare TSandstone2 =
texture{TSandstone}
texture{TStain}

//---The objects---------------------------------------------------------

#declare TScale = 3.75;    //Texture scale adjustment
//#declare TScale = 2.345;    //Texture scale adjustment

//Plain block
#macro Block(cx,cy,cz)
box{
  -1,1
  scale <W, H, D>
  translate <cx, cy, cz>

  texture{
    TSandstone2
    normal{granite .25 scale 3e-2}
    translate <cx,cy,cz>*TScale
  }
  translate y*(H-0*.5*ROUGH)
}
#end

//Stone Block
#macro IsoBlock(cx,cy,cz)
isosurface{
  function {
    max(
      abs(x-cx)-(W-ROUGH*f_Sandstone(x, y, z)),
      abs(y-cy)-(H-ROUGH*f_Sandstone(x, y, z)),
      abs(z-cz)-(D-ROUGH*f_Sandstone(x, y, z))
    )
  }
  contained_by{box{<cx-W, cy-H, cz-D>, <cx+W, cy+H, cz+D>}}
  max_gradient 1.2 // 1.1 // 1.25 // 1 1.4
  accuracy 1e-3

  texture{TSandstone2 translate <cx,cy,cz>*TScale}
  translate y*(H-0.5*ROUGH)
}
#end

#declare U=W*M;
#declare V=D*M;
#declare HH=H*2;
#declare HH=(HH-ROUGH);

//Stack blocks into a hollow pyramid.
#declare Pyramid =
union{
  #declare mk=2;
  #declare k=LEVELS-1;
  #while(k>=mk)
    #declare j=-k;
    #while(j<=k)
      #declare i=-k;
      #while(i<=k)
        #if(abs(i)=k | abs(j)=k | k=mk)
          //Block(i*U, (LEVELS-k-1)*HH, j*V)
          IsoBlock(i*U, (LEVELS-k-1)*HH, j*V)
        #end
        #declare i=i+2;
      #end
      #declare j=j+2;
    #end
    #declare k=k-1;
  #end
}

#declare BB=6 * LEVELS;

#declare Ground =
isosurface{
  function{y - f_Ground(x/6, y/6, z/6)}

  max_gradient 1.1
  contained_by { box{ <-BB,-1,-BB>, <BB,1,BB>} }
  accuracy 5e-3

  texture{TSand1 scale 4}
}

//---The scene---------------------------------------------------------

#if(1)
  sky_sphere{
    pigment{
      function{y}
      color_map{
        [0.0 SkyBlue]
        [0.19 rgb <0.0,0.1,0.8>*.60]
      }
      translate -y * .275
      scale 0.85
    }
  }
#else
  background{SkyBlue}
#end

object{Ground}
object{Pyramid rotate -25*y}

//#declare CamPos = <0, 4.875, -7.75> * 1.25 * LEVELS*H;

#declare CamPos = <0, 1.875*H, -1.875*W> * 1.2 * LEVELS;
camera {
  location CamPos
  direction z
  right     x*image_width/image_height up y
  look_at   1.0*LEVELS*H*y
  angle 30
}

light_source {
  <-0.5, 1, -1> * 8 * LEVELS*H
  rgb 1.25
  //area_light .2*x,.2*z, 3,3 jitter adaptive 1 orient circular
}

//---The end---------------------------------------------------------


Post a reply to this message


Attachments:
Download 'sandstoneeg1s.jpg' (115 KB)

Preview of image 'sandstoneeg1s.jpg'
sandstoneeg1s.jpg


 

From: etrask
Subject: Re: Sandstone blocks
Date: 27 Apr 2006 16:10:00
Message: <web.4451249f1843be33cb2bfb270@news.povray.org>
Very cool...

Can we get the source to the first picture you posted? The code you posted
is too advanced for me, and I want to render it in 1600x1200 for a
wallpaper.


Post a reply to this message

From: PM 2Ring
Subject: Re: Sandstone blocks
Date: 27 Apr 2006 23:45:01
Message: <web.44518e2b1843be3376ba2c900@news.povray.org>
"etrask" <et7### [at] yahoocom> wrote:
> Very cool...

Thanks!

> Can we get the source to the first picture you posted? The code you posted
> is too advanced for me, and I want to render it in 1600x1200 for a
> wallpaper.

Sorry, I've only got modified versions here at home: the original is on my
machine at work. This one is pretty close, though. To get closer, play with
the H variable in the Ground isosurface, & the scale parameter in TStain.
Also play with the gradient vector & turbulence.

Warning: this can be very slow to render with high anti-alias.

// Persistence of Vision Ray Tracer Scene Description File
// File: Sandstone.pov
// Vers: 3.6
// Desc:
// Date: 2006.02.06
// Auth: PM 2Ring
//
//  -F -A0.5 +AM2 +R1
//  -d +W1200 +H900 +A0.1 +AM2 +R3
//  -d +A0.2 +AM2 +R2
//

//#include "colors.inc"
#include "functions.inc"

global_settings {
  assumed_gamma 1.0
}

//---The textures---------------------------------------------------------

#declare Sandy = color rgb<1, .9, .65>;

#declare Transmit = .8;
#declare CM_Sandstone =
colour_map{
  [0.3 rgbt <1, 1, 1, 1.2*Transmit>]
  [0.4 rgbt <1, 0, 0, Transmit>]
  [0.41 rgbt <0.5, 0.3, 0.1, .5*Transmit>]
  [0.42 rgbt <1, 0, 0, .75*Transmit>]
  [0.6 rgbt <1, 0.5, 0, Transmit>]
  [0.7 rgbt <1, 1, 1, .5*Transmit>]
}

#declare FSandstone =
finish{
  diffuse 0.85 ambient 0.05
}

#declare TSandstone =
texture{
  pigment {Sandy}
  finish{FSandstone}
}

#declare TStain = texture{
  pigment{
    //agate
    gradient <.3, 2, .1>//2
    turbulence 0.15
    colour_map{CM_Sandstone}
    scale 0.75
  }
  finish{FSandstone}
}

#declare TSandstone2 =
texture{TSandstone}
texture{TStain}

//---The objects---------------------------------------------------------

#declare f_Height = function{0.5*f_wrinkles(x*.4, y*.4, z*.4)}

#declare H = 0.6;
#declare Ground =
isosurface {
  function {(y - f_Height(x, 0, z))/H}
  max_gradient 2.0
  contained_by {box {<-4,-5,-4>, < 4, 1, 4>}}
  accuracy 1e-3
}

//---The scene---------------------------------------------------------

object{Ground texture{TSandstone2 translate 17.123}}

#declare CamPos = <0.45, 6, -8>* .35;
//#declare CamPos = 4*y;

camera {
  location CamPos
  direction z
  right     x*image_width/image_height up y
  look_at   y* 0.25
  angle 40
}

light_source {
  <-0.5, 1, -1> * 8
  #if(1)
    rgb 1.15 // 1.75
  #else
    rgb 45
    fade_distance 1.25 fade_power 2
  #end
}

//---The end---------------------------------------------------------


Post a reply to this message

From: Thomas de Groot
Subject: Re: Sandstone blocks
Date: 28 Apr 2006 02:55:48
Message: <4451bc74$1@news.povray.org>
Very realistic indeed! An excellent sandstone, especially when it has been
exposed to weathering and/or ground water seepage. I shall certainly take it
up in my (small) collection of geological textures.

Thomas


Post a reply to this message

From: PM 2Ring
Subject: Re: Sandstone blocks
Date: 28 Apr 2006 09:00:00
Message: <web.445210571843be3376ba2c900@news.povray.org>
"Thomas de Groot" <t.d### [at] internlnet> wrote:
> Very realistic indeed! An excellent sandstone, especially when it has been
> exposed to weathering and/or ground water seepage. I shall certainly take it
> up in my (small) collection of geological textures.
>
> Thomas

Thanks, Thomas. It's always nice to get your geologist's approval of my
stones.
Living in Sydney, I've seen weathered sandstone all my life, and plenty
weathered by seepage. Sydney basin is built on sandstone and shale. As well
as the white, yellow and apricot colours of my palette, the real stones have
some beautiful shades of red, ranging from pale rose pinks to an almost
purple colour. I know the reds & yellows come from iron, but I don't know
about the purple.

Here's a large stone block sitting on a floor in a geology museum (maybe :)
Sorry, the source code is a bit messy...

// Persistence of Vision Ray Tracer Scene Description File
// File: Sandstone.pov
// Vers: 3.6
// Desc:
// Date: 2006.02.06
// Auth: PM 2Ring
//
//  -D +A0.1 +AM2 +R2
//  -F -A0.5 +AM2 +R1
//  -F +A0.6 +AM2 +R2
//  -d +W1200 +H900 +A0.3 +AM2 +R2
//  -d +W1200 +H900 +A0.1 +AM2 +R3
//
//  -d +A0.2 +AM2 +R2 +C
// povray SandstoneD.pov +p +A0.2 +AM2 +R2 +W800 +H600
//

//#include "colors.inc"
#include "functions.inc"

global_settings {
  assumed_gamma 1.0
  max_trace_level 5
}

//Block dimensions
#declare W = 1.25;
#declare D = 1.5;
#declare H = 0.75;
#declare ROUGH = 0.45;          //Bump height
#declare BUSY = 0.40;           //Bump period

//---The textures---------------------------------------------------------

#declare SkyBlue = rgb<.035, .27, .67>;              //For water & sky
#declare Sandy = rgb<1, .9, .65>;

#declare Transmit = .8;
#declare CM_Sandstone =
colour_map{
  [0.3 rgbt <1, 1, 1, 1.2*Transmit>]
  [0.4 rgbt <1, 0, 0, Transmit>]
  [0.41 rgbt <0.5, 0.2, 0.1, .5*Transmit>]
  [0.42 rgbt <1, 0, 0, .75*Transmit>]
  [0.6 rgbt <1, 0.5, 0, Transmit>]
  [0.7 rgbt <1, 1, 1, .5*Transmit>]
}

#declare FSandstone =
finish{
  diffuse 0.85 ambient 0.05
  //brilliance .5
}

#declare TSandstone =
texture{
  pigment {Sandy}
  finish{FSandstone}
}

#declare TStain = texture{
  pigment{
    //agate    //maybe try something derived from f_Height
    //wrinkles  //good!
    //wood
    marble
    //gradient <.3, 2, .1>/2
    turbulence 0.1875
    colour_map{CM_Sandstone}
    //scallop_wave

    translate 0.95*1.1
    rotate <10, 75, 25>
    scale 1.5*W*7
  }
  finish{FSandstone}
}

#declare TSandstone2 =
texture{TSandstone}
texture{TStain}

//---The objects---------------------------------------------------------

#declare f_Height = function{f_wrinkles(x*BUSY, y*BUSY, z*BUSY)}
#declare smod = function(A,B) {mod(B+mod(A,B),B)}

//#declare f_cnoise = function(x,z) {(W-R)*f_snoise3d(floor(x*.5/W), 0,
floor(z*.5/W))}
//#declare f_modnoise = function(x,z) {smod(x,2*W)-W+f_cnoise(x,z)}

//Stone Blocks
#declare IsoBlocks =
isosurface{
  function {
    max(
      smod(x,2)-(W-ROUGH*f_Height(x, y, z)),
      smod(z,2)-(D-ROUGH*f_Height(x, y, z)),

      //abs(x)-W*(1-ROUGH*f_Height(x, y, z)),
      abs(y)-(H-ROUGH*f_Height(x, y, z))
      //abs(z)-D*(1-ROUGH*f_Height(x, y, z))
    )
  }
  contained_by{box{<-W*5, -H, -D*5>, <W*5, H, D*5>}}
  max_gradient 16
  accuracy 3e-4
  //all_intersections
}

#declare IsoBlock =
isosurface{
  function {
    max(
      abs(x)-(W-ROUGH*f_Height(x, y, z)),
      abs(y)-(H-ROUGH*f_Height(x, y, z)),
      abs(z)-(D-ROUGH*f_Height(x, y, z))
    )
  }
  contained_by{box{<-W, -H, -D>, <W, H, D>}}
  max_gradient 1.3
  accuracy 1e-5
  //all_intersections
}

#declare Ground =
isosurface {
  function {(y - f_Height(x, y, z))}
  max_gradient 3.6
  contained_by {box {<-4,-5,-4>, < 4, 1, 4>}}
  accuracy 1e-3
}

#declare BB=12;
#declare Floor =
box{
  <-BB,-1,-BB>,<BB,0,BB>
  pigment{checker rgb .1, rgb 1 rotate -45*y}
  finish{
    ambient 0.1 reflection 0.175
  }
}

//---The scene---------------------------------------------------------

object{IsoBlock texture{TSandstone2}  rotate -30*y translate y*(H-ROUGH/2)}

#if(0)
  object{Ground texture{TSandstone2 translate 17.123}}
#else
  object{Floor}
#end

#if(0)
  //#declare SkyBlue = 2; //2.5 + SkyBlue;
  sky_sphere {
    pigment {
      gradient y
      color_map {
        [0.4 0.1*SkyBlue]
        [0.9 0.8*SkyBlue]
        [1   1.0*SkyBlue]
      }
    }
  }
#else
  background{rgb .5}
#end

#declare CamPos = <0.45, 3.75, -6.25> * 0.9;
//#declare CamPos = 4*y;
camera {
  location CamPos
  direction z
  right     x*image_width/image_height up y
  look_at   y* 0.3
  angle 40
}

light_source {
  <-0.5, 1, -1> * 8
  #if(0)
    rgb 1.25 // 1.75
  #else
    rgb 50
    //spotlight point_at <-1,-1,0> falloff 2.25 radius 0.35
    //area_light .2*x,.2*z, 3,3 jitter adaptive 1 orient circular
    fade_distance 1.25 fade_power 2
  #end
}

//---The end---------------------------------------------------------


Post a reply to this message


Attachments:
Download 'sandstonee0s.jpg' (123 KB)

Preview of image 'sandstonee0s.jpg'
sandstonee0s.jpg


 

From: Chambers
Subject: Re: Sandstone blocks
Date: 28 Apr 2006 16:53:40
Message: <445280d4@news.povray.org>
It's amazing how many good background images I get out of these 
groups...  Maybe the POV team should publish a compilation, "The Best of 
P.B.I." ?

...Chambers


Post a reply to this message

From: dlm
Subject: Re: Sandstone blocks
Date: 28 Apr 2006 21:45:08
Message: <4452c524$1@news.povray.org>
> some beautiful shades of red, ranging from pale rose pinks to an almost
> purple colour. I know the reds & yellows come from iron, but I don't know
> about the purple.

Manganese?
See e.g. http://web.uct.ac.za/depts/geolsci/dlr/kirstenbosch/mang1.htm
Nice fresh-hewn sandstone btw.

DLM


Post a reply to this message

From: Thomas de Groot
Subject: Re: Sandstone blocks
Date: 29 Apr 2006 03:22:32
Message: <44531438@news.povray.org>
"PM 2Ring" <nomail@nomail> schreef in bericht
news:web.445210571843be3376ba2c900@news.povray.org...
>
> Thanks, Thomas. It's always nice to get your geologist's approval of my
> stones.

Oh hum... <grin>

> Living in Sydney, I've seen weathered sandstone all my life, and plenty
> weathered by seepage. Sydney basin is built on sandstone and shale. As
well
> as the white, yellow and apricot colours of my palette, the real stones
have
> some beautiful shades of red, ranging from pale rose pinks to an almost
> purple colour. I know the reds & yellows come from iron, but I don't know
> about the purple.
>
It very much depends on the minerals in solution percolating through. Iron
of course, manganese like dlm says. I am not too familiar with that branch
of the trade. The irony is of course that I am living in a country that is
very poor in hard rock! But you can get the same kind of staining in sands
too, especially in the older deposits from the Pleistocene. And sands are
the building blocks of sandstones, so...


Thomas


Post a reply to this message

From: Marc Jacquier
Subject: Re: Sandstone blocks
Date: 29 Apr 2006 14:30:26
Message: <4453b0c2@news.povray.org>

news:44531438@news.povray.org...
>
>The irony is of course that I am living in a country that is
> very poor in hard rock!

Just wait few millions years ;-)

Marc


Post a reply to this message

Goto Latest 10 Messages Next 10 Messages >>>

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