.inc files for POV-ray Tutorial part 2
The second part of my tutorial is on inc files for Toribash
Creds go to Nokturnal for the glossy.inc file i will refer to
First a little refresher and information to those who know or those who dont
most of us know that pressing f8 gives us a screenshot in .pov format
if we open that up we see alot of coordinates that were recorded when you took that screenshot
if we create a new .inc file it has to be in the Include folder in the POV-ray directory
or in the folder containing the .pov you will edit.
create a new file in notepad called "demo.inc"
start by adding the background into the file
since this is a .inc it uses the same language as the POV's
background {color rgb <10/255, 10/255, 10/255>}
this sets the background color to a greyish color
now we will set it so it imports the camera view from the .pov file and sets the light source
#macro Camera(xpos, ypos, zpos, lookatx, lookaty, lookatz) //takes the information and sets it to the denoted name
camera {
location <xpos, -ypos, zpos>
look_at <lookatx, -lookaty, lookatz>
}
light_source { <xpos, -ypos, 3> rgb<1,1,1> } //sets color of light source
#end
if you read my first tutorial on pov-ray you should have no trouble with this
we can work on the joints too
it also takes information from the pov file and sets attributes in that language
so if you wanted to make the joints square, you could but you have to have the correct syntax
you could also make the texture a wood grain look
etc.
#macro Joint(xpos,ypos,zpos,Radius)
sphere { <xpos, -ypos, zpos>, Radius
pigment { color rgb <10/255, 235/255, 10/255> }
finish {
reflection 0.5
diffuse .1
specular 1
diffuse .1
}
}
#end
the blood
#macro Blood (xpos, ypos, zpos, Radius)
threshold 0.1 //the largness of the blobs of blood
sphere {<xpos, -ypos, zpos>, Radius*3, 0.1
pigment { color rgb <0, 0, 1 > } //you can put textures here with the texture tag
finish {
ambient .1
diffuse .1
specular 1
roughness .001
metallic
reflection { .75 metallic }
}
}
#end
i really dont know to much about the other parts and that will soon come out in future versions of this..
i hope this helped a wee bit...