|
|
// A demo of a furry density_map for Povray 3.1
// ******* CAMERA *******
camera { // Camera StdCam
location <-2.293, -4.761, 3.481>
direction <0.0, 0.0, 1.1547>
sky <0.0, 0.0, 1.0> // Use right handed-system!
up <0.0, 0.0, 1.0> // Where Z is up
right <1.33333, 0.0, 0.0>
look_at <0.237, 0.487, 0.973>
}
//
// ******* L I G H T S *******
//
light_source { // Light1
<3.924, -4.169, 4.869>
color rgb <1.000, 1.000, 1.000>
fade_distance 4.0
fade_power 2.0
}
//
// ******** TEXTURES *******
//
// Fur texture!
// For spaces with a density of 0 (where I want empty non-filled space
// in my density texture). Much to my suprise this is legal!
// (and very useful).
#declare Air =
density {
}
// For spaces with a density of 1
#declare Spherical =
density {
spherical
scale 10000
}
// For the spherical shapes
// To make the edges of the furball fade at the edges
// so we can't see the boundaries of the container sphere
#declare Spherical_Map =
density {
spherical
density_map {
[0.0 Air]
[0.1 Spherical]
[1 Spherical]
}
}
// Combine vertical radial density texture with spherical density texture
// using a density_map.
#declare Radial =
density {
radial
frequency 40
density_map {
[0.0 Air]
[0.6 Air] // You can raise or lower these two values to make the
[0.6 Spherical_Map] // "hairs" thicker or thinner or make the boundaries
// less defined by using different values. I used the
// same values to make the edges as sharp as I can.
[1 Spherical_Map]
}
}
// This is really the same texture as above. I made this for clarity
// in the source code. (Vertical radial density)
#declare Y_Radial =
density {
Radial
}
// Rotate the radial density texture 90 degrees toward the observer
#declare Z_Radial =
density {
Radial
rotate <0,0,90>
}
// Rotate the radial density texture 90 degrees so it's horizontal
#declare X_Radial =
density {
Radial
rotate <90,0,0>
}
// Combine ("interesect") the Y_Radial density with the X_Radial density
// using a density_map
#declare X_Y_Radial =
density {
Y_Radial
density_map {
[0.0 Air]
[0.6 Air]
[0.6 X_Radial]
[1.0 X_Radial]
}
}
// Combine ("intersect") the X_Radial & Y_Radial with the Z_Radial density
// using a density map. Just like I did above.
#declare X_Y_Z_Radial =
density {
X_Y_Radial
density_map {
[0.0 Air]
[0.6 Air]
[0.6 Z_Radial]
[1.0 Z_Radial]
}
}
// For the smaller denser area in the middle of the furball.
// Otherwise it will look like it has no "body" and look more like a
// collection of dandilion seeds. (That could be useful too! :) )
#declare Sphere_Body =
density {
spherical
density_map {
[0.0 Air]
[0.5 Spherical]
[1 Spherical]
}
}
// The last step!
// Combine the X_Y_Z_Radial using the Sphere_Body density texture using
// a density_map yet again! As opposed to the previous density maps
// note that I wanted to fill up density 0.0 (the empty spaces) with
// the Sphere_Body density map rather than leave them open like above.
#declare Furball =
density {
X_Y_Z_Radial
density_map {
[0.0 Sphere_Body]
[1 X_Y_Z_Radial]
}
}
// Black shiny texture to use for eyes and nose
#declare EyesNose =
texture {
pigment {
color rgb <0,0,0>
}
finish {
phong 1
phong_size 100
}
}
#declare
// *********** CYLINDRICAL FUR *********************
// This is similar to the fur that I used for the head except instead of
density_mapping 3 radial
density_map with a gradient density_map.
#declare Cylindrical_Map =
density {
cylindrical
density_map {
[0.0 Air]
[0.2 Spherical]
[1 Spherical]
}
//rotate <90,0,0>
}
#declare Gradient_Z =
density {
gradient z
density_map {
[0.0 Air]
[0.3 Air]
[0.3 Spherical]
[0.7 Spherical]
[0.7 Air]
[1 Air]
}
scale <0,0,0.3>
}
#declare Radial_Gradient_Z =
density {
radial frequency 40
rotate <90,0,0>
density_map {
[0.0 Air]
[1.0 Gradient_Z]
}
}
#declare Radial_Gradient_Z2 =
density {
Radial_Gradient_Z
density_map {
[0.0 Air]
[1.0 Cylindrical_Map]
}
}
#declare Cylinder_Body =
density {
cylindrical
density_map {
[0.0 Air]
[0.65 Spherical]
[1 Spherical]
}
}
#declare Fur_Cyl =
density {
Radial_Gradient_Z2
density_map {
[0.0 Cylinder_Body]
[1 Radial_Gradient_Z2]
}
}
//
// ******** OBJECTS *******
//
sphere { // Sphere001
<0,0,0>,1.1
texture {
pigment {
color rgbf <1,1,1,1>
}
finish {
ambient 0.15
diffuse 1 }
}
hollow
interior {
media {
intervals 10
scattering { 1, rgb <3,1.5,0.4>} // Make a brown color for areas that
// are lit
absorption rgb <2,2,2> // This is the key to making "solid" 3-D textures.
// Set this so all areas of the density that are
// in shadow are black.
samples 1, 2
confidence 0.600
variance 1/600
ratio 0.600
density {
Furball
turbulence 0.05
}
}
}
scale <0.7, 0.5, 0.6>
translate <0.0, -0.162254, 2.645079>
}
cylinder { // SuperQ001
<0,0,-1>,<0,0,1>,1
// scale 1.1
texture {
pigment {
color rgbf <1,1,1,1>
}
finish {
ambient 0.15
diffuse 1 }
}
hollow
interior {
media {
intervals 10
scattering { 1, rgb <3,1.5,0.4>} // Make a brown color for areas that
// are lit
absorption rgb <2,2,2> // This is the key to making "solid" 3-D textures.
// Set this so all areas of the density that are
// in shadow are black.
samples 1, 2
confidence 0.600
variance 1/600
ratio 0.600
density {
Fur_Cyl
turbulence 0.05
}
}
}
scale <1.0, 0.75, 1.0>
translate <0.0, -0.183012, 1.0>
}
plane { // Plane001
z,-0.1
texture {
pigment {
color rgb <0.15,0.15,1>
}
finish {
ambient 0.1
diffuse 0.75
reflection 0.25
}
}
}
cylinder { // SuperQ001
<0,0,-1>,<0,0,1>,1
// scale 1.1
texture {
pigment {
color rgbf <1,1,1,1>
}
finish {
ambient 0.15
diffuse 1 }
}
hollow
interior {
media {
intervals 10
scattering { 1, rgb <3,1.5,0.4>} // Make a brown color for areas that
// are lit
absorption rgb <2,2,2> // This is the key to making "solid" 3-D textures.
// Set this so all areas of the density that are
// in shadow are black.
samples 1, 2
confidence 0.600
variance 1/600
ratio 0.600
density {
Fur_Cyl
turbulence 0.05
}
}
}
scale <0.4, 0.4, 0.8>
rotate <-90.0, 0.0, -45.0>
translate <-1.016273, -0.720791, 0.430257>
}
cylinder { // SuperQ001
<0,0,-1>,<0,0,1>,1
// scale 1.1
texture {
pigment {
color rgbf <1,1,1,1>
}
finish {
ambient 0.15
diffuse 1 }
}
hollow
interior {
media {
intervals 10
scattering { 1, rgb <3,1.5,0.4>} // Make a brown color for areas that
// are lit
absorption rgb <2,2,2> // This is the key to making "solid" 3-D textures.
// Set this so all areas of the density that are
// in shadow are black.
samples 1, 2
confidence 0.600
variance 1/600
ratio 0.600
density {
Fur_Cyl
turbulence 0.05
}
}
}
scale <0.4, 0.4, 0.8>
rotate <-90.0, 0.0, 45.0>
translate <0.989884, -0.720791, 0.430257>
}
cylinder { // SuperQ001
<0,0,-1>,<0,0,1>,1
// scale 1.1
texture {
pigment {
color rgbf <1,1,1,1>
}
finish {
ambient 0.15
diffuse 1 }
}
hollow
interior {
media {
intervals 10
scattering { 1, rgb <3,1.5,0.4>} // Make a brown color for areas that
// are lit
absorption rgb <2,2,2> // This is the key to making "solid" 3-D textures.
// Set this so all areas of the density that are
// in shadow are black.
samples 1, 2
confidence 0.600
variance 1/600
ratio 0.600
density {
Fur_Cyl
turbulence 0.05
}
}
}
scale <0.4, 0.4, 0.7>
rotate <-90.0, 0.0, 45.0>
translate <0.906375, -0.655839, 1.590844>
}
cylinder { // SuperQ001
<0,0,-1>,<0,0,1>,1
// scale 1.1
texture {
pigment {
color rgbf <1,1,1,1>
}
finish {
ambient 0.15
diffuse 1 }
}
hollow
interior {
media {
intervals 10
scattering { 1, rgb <3,1.5,0.4>} // Make a brown color for areas that
// are lit
absorption rgb <2,2,2> // This is the key to making "solid" 3-D textures.
// Set this so all areas of the density that are
// in shadow are black.
samples 1, 2
confidence 0.600
variance 1/600
ratio 0.600
density {
Fur_Cyl
turbulence 0.05
}
}
}
scale <0.4, 0.4, 0.7>
rotate <-90.0, 0.0, -45.0>
translate <-0.942043, -0.655839, 1.590844>
}
cylinder { // SuperQ001
<0,0,-1>,<0,0,1>,1
// scale 1.1
texture {
pigment {
color rgbf <1,1,1,1>
}
finish {
ambient 0.15
diffuse 1 }
}
hollow
interior {
media {
intervals 10
scattering { 1, rgb <3,1.5,0.4>} // Make a brown color for areas that
// are lit
absorption rgb <2,2,2> // This is the key to making "solid" 3-D textures.
// Set this so all areas of the density that are
// in shadow are black.
samples 1, 2
confidence 0.600
variance 1/600
ratio 0.600
density {
Fur_Cyl
turbulence 0.05
}
}
}
scale <0.4, 0.3, 0.3>
translate <0.0, -0.183012, 2.045046>
}
cylinder { // SuperQ001
<0,0,-1>,<0,0,1>,1
// scale 1.1
texture {
pigment {
color rgbf <1,1,1,1>
}
finish {
ambient 0.15
diffuse 1 }
}
hollow
interior {
media {
intervals 10
scattering { 1, rgb <3,1.5,0.4>} // Make a brown color for areas that
// are lit
absorption rgb <2,2,2> // This is the key to making "solid" 3-D textures.
// Set this so all areas of the density that are
// in shadow are black.
samples 1, 2
confidence 0.600
variance 1/600
ratio 0.600
density {
Fur_Cyl
turbulence 0.05
}
}
}
scale <0.3, 0.15, 0.225>
rotate 30.0*y
translate <-0.630364, -0.183012, 2.927556>
}
cylinder { // SuperQ001
<0,0,-1>,<0,0,1>,1
// scale 1.1
texture {
pigment {
color rgbf <1,1,1,1>
}
finish {
ambient 0.15
diffuse 1 }
}
hollow
interior {
media {
intervals 10
scattering { 1, rgb <3,1.5,0.4>} // Make a brown color for areas that
// are lit
absorption rgb <2,2,2> // This is the key to making "solid" 3-D textures.
// Set this so all areas of the density that are
// in shadow are black.
samples 1, 2
confidence 0.600
variance 1/600
ratio 0.600
density {
Fur_Cyl
turbulence 0.05
}
}
}
scale <0.3, 0.15, 0.225>
rotate -30.0*y
translate <0.629381, -0.183012, 2.927556>
}
cylinder { // SuperQ001
<0,0,-1>,<0,0,1>,1
texture {
pigment {
color rgbf <1,1,1,1>
}
finish {
ambient 0.15
diffuse 1 }
}
hollow
interior {
media {
intervals 10
scattering { 1, rgb <3,1.5,0.4>} // Make a brown color for areas that
// are lit
absorption rgb <2,2,2> // This is the key to making "solid" 3-D textures.
// Set this so all areas of the density that are
// in shadow are black.
samples 1, 2
confidence 0.600
variance 1/600
ratio 0.600
density {
Fur_Cyl
turbulence 0.05
}
}
}
scale 0.2
translate <0.0, -0.527326, 2.612778>
}
sphere { // Sphere3
<0,0,0>,1
texture {
EyesNose
}
scale 0.07
translate <0.0, -0.728236, 2.612778>
}
sphere { // Sphere4
<0,0,0>,1
texture {
EyesNose
}
scale <0.1, 0.07, 0.1>
translate <-0.303631, -0.513759, 2.864727>
}
sphere { // Sphere5
<0,0,0>,1
texture {
EyesNose
}
scale <0.1, 0.07, 0.1>
translate <0.297603, -0.506127, 2.864727>
}
Post a reply to this message
|
|