POV-Ray : Newsgroups : povray.text.scene-files : possible bug? (source for image) Server Time
29 Oct 2024 22:48:58 EDT (-0400)
  possible bug? (source for image) (Message 1 to 1 of 1)  
From: nospam
Subject: possible bug? (source for image)
Date: 4 Oct 2001 20:50:47
Message: <3bbce6ae.1572861@localhost>
Source for the image I posted on the binaries group:

-- 
#include "functions.inc" // can't use functions without this!


#declare rseed = seed(43493938);


global_settings {
  assumed_gamma 2.4
  max_trace_level 10
}


#macro rnd_rotate()
  rotate <360 * rand(rseed), 360 * rand(rseed), 360 * rand(rseed)>
#end


#macro rnd_translate()
  translate <4 - 8 * rand(rseed), 4 - 8 * rand(rseed), 4 - 8 *
rand(rseed)>
#end


#macro perturb()
  rnd_translate()
  rnd_rotate()
#end


#macro rrange(rlo, rhi)
  #local real_low = min(rlo, rhi);
  #local real_high = max(rlo, rhi);
  #local rr_return = real_low + rand(rseed) * (real_high - real_low);
  rr_return
#end


camera {
  location 0
  direction <0, 0, 1>
  right <640 / 480, 0, 0>
  up <0, 1, 0>
  translate <0, 0.01, -4>
}


sky_sphere {
  pigment {
    gradient <0, 1, 0>
    color_map {
      [ 0.0 color rgb <0, 0.5, 1> * 0.6 + 0.4 ]
      [ 0.2 color rgb <0, 0.5, 1> ]
      [ 1.0 color rgb <0, 0.08, 1> ]
    }
    warp { repeat <0, 1, 0> flip <0, 1, 0> }
  }
}


isosurface {
  function {
    f_sphere(x, y, z, 0.5) -
    // 0.8 * f_noise3d(x + 1, y, z)
    0.8 * f_noise_generator(x + 1, y, z, 0) // 0 or 1 bad, 2 - fine
  }
  accuracy 0.0001 // changing this doesn't seem to help
  max_trace 10    // ditto
  contained_by { box { -2, 2 } }
  threshold 0.5
  rotate y*-30
  pigment { color rgb (<1, 0.5, 0> * 0.2 + 0.8) * 0.9 }
  finish {
    ambient 0.4 diffuse 0.6
    // specular 1.0 roughness 0.02
  }
}


light_source {
  <2000, 3000, -2000>
  color rgb 0.6
}

light_source {
  <0, -10, -2000>
  color rgb 0.4
}


/* actual end of this file */


Post a reply to this message

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