<< ついったー始める 戻る STANDARD PROCEDURAL DATABASES >>

XRT renderer その2

checkerシェーダーを再コンパイル。立方体にはshinyを割り当てる。
box_checkjpg.JPG
レイトレーシングしています。

#box_check.pyg
Output ("box_check.tif", "tiff", "rgb", "camera", "float gain", 1, "float gamma",
1, "string filter", "gaussian", "float[2] filterwidth", (2, 2))
Attribute ("float shadingquality",1.2)
Attribute ("string projection", "perspective")
Attribute ("float fov", 20)
Attribute ("int[2] resolution", (640, 480))
#placecam 10 5 -10 0 0 0
Rotate (-19.47, 1.00, 0.00, 0.00)
Rotate (45.00, 0.00, 1.00, 0.00)
Translate (-10.00, -5.00, 10.00)

#Attribute ( "int ray:shadows", 0 )
Attribute ("string geometryset", "+shadows")
Attribute ("string geometryset", "+reflection")

World ()
Light ("light1", "pointlight", "float intensity", 400, "point from", (-10, 10, -10),"string shadowname", "shadows")
Light ("light2", "pointlight", "float intensity", 400, "point from", (10, 10, -10),"string shadowname", "shadows")

PushTransform ()
Attribute ("color C", (0.2, 0.4, 0.75))
Sphere (100, -100, 100, 360)
PopTransform ()

for i in range(5):
PushTransform ()
Attribute ("color C", (1, 1, 1))
Shader ( "surface", "shiny", "float Kd", 0, "float Kr", 0.75, "float roughness", 0 )
#Shader ("surface", "plastic")
i=1.2*i
Translate ( 0, 0.5, i-2)
Input ("BoxGeom.rib")
PopTransform ()


Attribute ("color C", (1, 1, 1))
Rotate (90.00, 1.00, 0.00, 0.00)
ShaderGroupBegin ()
Shader ("surface", "checker","float frequency",10,"color blackcolor",(0, 0, 0))
#Shader ("surface", "plastic", "layer2")
#ConnectShaders ("layer1", "Cout", "layer2", "C")
ShaderGroupEnd ()
Input("PlaneGeom.rib")
Render()

ありがとうございます。さらに勉強します。
  • -
  • -

<< ついったー始める 戻る STANDARD PROCEDURAL DATABASES >>