次の include文で、ここで示しているすべてのものを使用することができる。

#include "colors.inc" #include "textures.inc" #include "Woods.inc" #include "stones.inc" #include "glass.inc" #include "metals.inc" #include "skies.inc" #include "stars.inc" #include "chars.inc" #include "shapes.inc" #include "shapes2.inc" #include "shapes3.inc"


▷ 前の「14.11 形状3a」へ


14.11 形状3b

POV-Rayでは、プリミティブとしてさまざまな形状が用意されているが、インクルードファイルには違った形状が定義されている。ここでは、shapes3.inc に含まれている主なもの(b)を示す。

形状3a/3b を使うために必要なインクルード文

#include "shapes3.inc"

ここには次の形状がある。

 ▷ 14.11-9 丸ピラミッド[Round_Pyramid_N_out]
 ▷ 14.11-10 チューブ[Round_Cylinder_Tube]
 ▷ 14.11-11 バスタブ1[Half_Hollowed_Rounded_Cylinder1]
 ▷ 14.11-12 バスタブ2[Half_Hollowed_Rounded_Cylinder2]
 ▷ 14.11-13 ナス型リング[Round_Conic_Torus]
 ▷ 14.11-14 ナス型柱[Round_Conic_Prism]
 ▷ 14.11-15 チューブ正多角形[Round_N_Tube_Polygon]


14.11-9 丸ピラミッド[Round_Pyramid_N_out]

丸ピラミッドは、角の丸い正角錘または正角錐台である。

図14.11-9a 丸ピラミッド[Round_Pyramid_N_out]

下図14.11-9b に示すように、丸ピラミッドはA点とB点で指定する位置に生成される。

図14.11-9b 丸ピラミッドの位置座標

//--------------- Fig.14.11-9a Round_Pyramid_N_out #version 3.7 #include "colors.inc" #include "textures.inc" #include "Woods.inc" #include "stones.inc" #include "glass.inc" #include "metals.inc" #include "skies.inc" #include "stars.inc" #include "chars.inc" #include "shapes.inc" #include "shapes2.inc" #include "shapes3.inc" global_settings { assumed_gamma 2.2 } //-----------------------------camera - light camera{ location <0,-14,8> sky <0, 0, 1> right <-image_width/image_height,0,0> look_at <0, 0, 0> angle 25 } light_source{<100,-400,500> color rgb 1.5 parallel point_at 0 } //================================ Round_Pyramid_N_out #declare T1=texture{T_Copper_4A normal{agate 1 scale 0.2} } #declare T2=texture {T_Wood11 finish{ phong 1} } object{ Round_Pyramid_N_out( 8,<0,0,0>,1.3,<0,0,1.5>,1, 0.1,0,0 ) texture{T1} scale 1 translate<-1.3,-3,1> } object{ Round_Pyramid_N_out( 12,<0,0,0>,1,<0,0,2>,0.6, 0.05,1, 0 ) texture{T2} scale 1 translate<1.3,-3,1> } //---------------------------------floor #declare CA1=rgb<0.85,0.85,0.8>; #declare CA2=rgb<0.85,0.85,0.8>*1.2; plane{ z, 0 pigment{ checker color CA1, color CA2 scale 0.3 } } //----------------sky sky_sphere{ pigment{ wrinkles color_map{ [ 0.3 SkyBlue] [ 0.9 White ] } scale <1, 0.2, 0.2> } }
//--------------- Fig.14.11-9b Round_Pyramid_N_out #version 3.7 #include "colors.inc" #include "textures.inc" #include "Woods.inc" #include "stones.inc" #include "glass.inc" #include "metals.inc" #include "skies.inc" #include "stars.inc" #include "chars.inc" #include "shapes.inc" #include "shapes2.inc" #include "shapes3.inc" global_settings { assumed_gamma 2.2 } //-----------------------------camera - light camera{ location <60,60,10> sky <0, 0, 1> right <-image_width/image_height,0,0> look_at <0, 0, 0.2> angle 5.8 } light_source{ <200,400,300> color rgb 1.5} background {color rgb<1,1,0.9>*0.9 } //============================ Round_Pyramid_N_out object{ Round_Pyramid_N_out( 8, <0,-1,-0.5>,1.5, <0,2,2>,0.6,0.07,0,0) pigment{rgbf<0.7,1,1,0.5>*1.1} finish{phong 1} } sphere {<0,-1,-0.5> 0.1 pigment{ rgbf<1,0.6,>*0.8} } sphere {<0,2,2> 0.1 pigment{ rgbf<1,0.6,>*0.8} }

< Round_Pyramid_N_out の構文 >

object{ Round_Pyramid_N_out ( N_Sides, <A_Point> , A_Radius , <B_Point> , B_Radius , Border_Radius , Filled , UseMerge ) [ OBJECT_MODIFIERS... ] }
object 物体のキーワード
Round_Pyramid_N_out 丸ピラミッド
N_Sides ピラミッドの辺数
<A_Point> A点の x,y,z 座標
A_Radius A点の半径(外接円の半径)
<B_Point> B点の x,y,z 座標
B_Radius B点の半径(外接円の半径)
Border_Radius ワイヤーフレーム円柱の半径
Filled 面スイッチ:ワイヤーフレーム 0 、面の生成 1
UseMerge マージの使用: 無 0 、有 1
OBJECT_MODIFIERS... 物体の変形・テクスチャなどの設定

 


14.11-10 チューブ[Round_Cylinder_Tube]

円柱形のチューブで、端部が丸くなっている。

図14.11-10a チューブ[Round_Cylinder_Tube]

下図14.11-10b に示すように、正20面体はA点とB点で指定する位置に生成される。

図14.11-10b チューブの位置座標

//---------------- Fig.14.11-10a Round_Cylinder_Tube #version 3.7 #include "colors.inc" #include "textures.inc" #include "Woods.inc" #include "stones.inc" #include "glass.inc" #include "metals.inc" #include "skies.inc" #include "stars.inc" #include "chars.inc" #include "shapes.inc" #include "shapes2.inc" #include "shapes3.inc" global_settings { assumed_gamma 2.2 } //-----------------------------camera - light camera{ location <0,-14,8> sky <0, 0, 1> right <-image_width/image_height,0,0> look_at <0, 0, 0> angle 25 } light_source{<100,-400,500> color rgb 1.5 parallel point_at 0 } //=================================== Round_Cylinder_Tube #declare T1=texture{T_Gold_1C} #declare T2=texture{T_Gold_5C normal{agate 1 scale 0.2} } object{ Round_Cylinder_Tube(<0,0,0>,<0,0,2>,0.9,0.1,0,0) texture{T1} translate<-1.3,-3,1> } object{ Round_Cylinder_Tube(<0,0,0>,<0,0,1.2>,1.2, 0.4,0,0) texture{T2} translate<1.3,-3,1> } //---------------------------------floor #declare CA1=rgb<0.85,0.85,0.8>; #declare CA2=rgb<0.85,0.85,0.8>*1.2; plane{ z, 0 pigment{ checker color CA1, color CA2 scale 0.3 } } //----------------sky sky_sphere{ pigment{ wrinkles color_map{ [ 0.3 SkyBlue] [ 0.9 White ] } scale <1, 0.2, 0.2> } }
//---------------- Fig.14.11-10b Round_Cylinder_Tube #version 3.7 #include "colors.inc" #include "textures.inc" #include "Woods.inc" #include "stones.inc" #include "glass.inc" #include "metals.inc" #include "skies.inc" #include "stars.inc" #include "chars.inc" #include "shapes.inc" #include "shapes2.inc" #include "shapes3.inc" global_settings { assumed_gamma 2.2 } //-----------------------------camera - light camera{ location <60,60,10> sky <0, 0, 1> right <-image_width/image_height,0,0> look_at <-0.2, 0, 0.7> angle 5.8 } light_source{ <200,400,300> color rgb 1.5} background {color rgb<1,1,0.9>*0.9 } //============================= Round_Cylinder_Tube object{ Round_Cylinder_Tube( <0,-1,-0.5>,<0,2.5,2.5>, 1.2, 0.2, 0, 0 ) pigment{rgbf<0.7,1,1,0.5>*1.1} finish{phong 1} } sphere {<0,-1,-0.5> 0.1 pigment{ rgbf<1,0.6,>*0.8} } sphere {<0,2.5,2.5> 0.1 pigment{ rgbf<1,0.6,>*0.8} }

< Round_Cylinder_Tube の構文 >

object{ bb>Round_Cylinder_Tube ( <A_Point> , <B_Point> , Out_Radius , Border_Radius , Filled , UseMerge ) [ OBJECT_MODIFIERS... ] }
object 物体のキーワード
Round_Cylinder_Tube チューブ
<A_Point> , <B_Point> A点、B点の x,y,z 座標
Out_Radius チューブ外側の半径
Border_Radius 端部の丸み半径(チューブの厚さ)
Filled 端部面の生成: 無 0 、有 1
UseMerge マージの使用: 無 0 、有 1
OBJECT_MODIFIERS... 物体の変形・テクスチャなどの設定

※ 端部の面があると、角の丸い円柱になる。

 


14.11-11 バスタブ1[Half_Hollowed_Rounded_Cylinder1]

バスタブのような形状で、チューブと球をマージして半分に切ったような形である。

図14.11-11a バスタブ1[Half_Hollowed_Rounded_Cylinder1]

バスタブ1は、下図14.11-11b のような位置に生成される。チューブの中心は x 軸である。

図14.11-11b バスタブ1の生成位置

//------------ Fig.14.11-11a Half_Hollowed_Rounded_Cylinder1 #version 3.7 #include "colors.inc" #include "textures.inc" #include "Woods.inc" #include "stones.inc" #include "glass.inc" #include "metals.inc" #include "skies.inc" #include "stars.inc" #include "chars.inc" #include "shapes.inc" #include "shapes2.inc" #include "shapes3.inc" global_settings { assumed_gamma 2.2 } //-----------------------------camera - light camera{ location <0,-14,10> sky <0, 0, 1> right <-image_width/image_height,0,0> look_at <0, 0, 0> angle 25 } light_source{<100,-400,500> color rgb 1.5 parallel point_at 0 } //========================== Half_Hollowed_Rounded_Cylinder1 #declare T1=texture {T_Gold_1C} #declare T2=texture{T_Grnt9 scale 0.5 finish{ phong 1} } object { Half_Hollowed_Rounded_Cylinder1(5,1,0.2,1,0) texture{T1} scale 1 rotate <90,0,90> translate<-1.3,0,1> } object { Half_Hollowed_Rounded_Cylinder1(4,1,0.2,1,0) texture { T2} scale 1 rotate <90,0,90> translate<1.3,-2,1> } //---------------------------------floor #declare CA1=rgb<0.85,0.85,0.8>; #declare CA2=rgb<0.85,0.85,0.8>*1.2; plane{ z, 0 pigment{ checker color CA1, color CA2 scale 0.3 } } //----------------sky sky_sphere{ pigment{ wrinkles color_map{ [ 0.3 SkyBlue] [ 0.9 White ] } scale <1, 0.2, 0.2> } }
//------------ Fig.14.11-11b Half_Hollowed_Rounded_Cylinder1 #version 3.7 #include "colors.inc" #include "textures.inc" #include "Woods.inc" #include "stones.inc" #include "glass.inc" #include "metals.inc" #include "skies.inc" #include "stars.inc" #include "chars.inc" #include "shapes.inc" #include "shapes2.inc" #include "shapes3.inc" global_settings { assumed_gamma 2.2 } //-----------------------------camera - light camera{ location <60,60,10> sky <0, 0, 1> right <-image_width/image_height,0,0> look_at <0, 0, 0.7> angle 5.8 } light_source{ <200,400,300> color rgb 1.5 } background {color rgb<1,1,0.9>*0.9 } //========================== Half_Hollowed_Rounded_Cylinder1 object { Half_Hollowed_Rounded_Cylinder1(4,1.2,0.3,1,0) texture{pigment{rgbf<1,1,0,0.3>} finish{phong 1} } } //--------------------------------coordinate axis #declare SX=4.5; #declare SY=3.5; #declare SZ=3.2; #declare SC=0.7; union{ union{ cylinder{x*-5,x*(SX-0.5),0.05} cone{x*(SX-0.5),0.1,x*(SX+0.1),0} text{ttf "cyrvetic.ttf","X",0.1,0 scale SC rotate<90,0,-30> translate <SX+0.4, 0, -0.5> } pigment{color rgb<0.2,1,0.2>} } union{ cylinder{y*-5,y*(SY+0.5),0.05} cone{y*(SY+0.5),0.1,y*(SY+1.1),0} text{ttf "cyrvetic.ttf","Y",0.1,0 scale SC rotate<90,0,-30> translate <-0.1,SY+2,-0.5> } pigment{color rgb<0.2,0.2,1.0>} } union{ cylinder{z*-5,z*(SZ-0.5),0.05} cone{z*(SZ-0.5),0.1,z*(SZ+0.1),0} text{ttf "cyrvetic.ttf","Z",0.1,0 scale SC rotate<90,0,120> translate <-0.2,0.2,SZ-0.2> } pigment{color rgb<1.0,0.2,0.2>} } }

< Half_Hollowed_Rounded_Cylinder1 の構文 >

object{ Half_Hollowed_Rounded_Cylinder1 ( Length , Out_Radius , Border_Radius , BorderScale , UseMerge ) [ OBJECT_MODIFIERS... ] }
object 物体のキーワード
Half_Hollowed_Rounded_Cylinder1 バスタブ1
Length バスタブの長さ
Out_Radius バスタブ外側の半径
Border_Radius バスタブふちの半径(バスタブの厚さ)
BorderScale バスタブふちの形状調整 ( 0 以上の数値)
0 で平坦、1 で丸い形状、1 以上は鋭くなる。
UseMerge マージの使用: 無 0 、有 1
OBJECT_MODIFIERS... 物体の変形・テクスチャなどの設定

 


14.11-12 バスタブ2[Half_Hollowed_Rounded_Cylinder2]

バスタブのような形状で、ドラム缶を半分に切った形である。

図14.11-12a バスタブ2[Half_Hollowed_Rounded_Cylinder2]

バスタブ2は、下図14.11-12b のような位置に生成される。チューブの中心は x 軸である。

図14.11-12b バスタブ2の生成位置

//------------ Fig.14.11-12a Half_Hollowed_Rounded_Cylinder2 #version 3.7 #include "colors.inc" #include "textures.inc" #include "Woods.inc" #include "stones.inc" #include "glass.inc" #include "metals.inc" #include "skies.inc" #include "stars.inc" #include "chars.inc" #include "shapes.inc" #include "shapes2.inc" #include "shapes3.inc" global_settings { assumed_gamma 2.2 } //-----------------------------camera - light camera{ location <0,-14,8> sky <0, 0, 1> right <-image_width/image_height,0,0> look_at <0, 0, 0> angle 25 } light_source{<100,-400,500> color rgb 1.5 parallel point_at 0 } //========================== Half_Hollowed_Rounded_Cylinder2 #declare T1= texture{ pigment{ spiral1 5 color_map{ [0.0 Red] [0.6 White] } scale 0.1 } finish{phong 1} } #declare T2= texture{ pigment{ waves color_map{ [0.0 color rgb<0.5,0.8,0.3>*1.2] [0.6 color rgb 1] } frequency 2 scale 0.2 } } object { Half_Hollowed_Rounded_Cylinder2(5,0.9,0.3,0.1,1,0) texture{T1} scale 1 rotate <90,0,90> translate<-1.3,0,1> } object { Half_Hollowed_Rounded_Cylinder2(5,0.9,0.5,0.15,1,0) texture{T2} scale 1 rotate <90,0,90> translate<1.3,-1.5,1> } //---------------------------------floor #declare CA1=rgb<0.85,0.85,0.8>; #declare CA2=rgb<0.85,0.85,0.8>*1.2; plane{ z, 0 pigment{ checker color CA1, color CA2 scale 0.3 } } //----------------sky sky_sphere{ pigment{ wrinkles color_map{ [ 0.3 SkyBlue] [ 0.9 White ] } scale <1, 0.2, 0.2> } }
//------------ Fig.14.11-12b Half_Hollowed_Rounded_Cylinder2 #version 3.7 #include "colors.inc" #include "textures.inc" #include "Woods.inc" #include "stones.inc" #include "glass.inc" #include "metals.inc" #include "skies.inc" #include "stars.inc" #include "chars.inc" #include "shapes.inc" #include "shapes2.inc" #include "shapes3.inc" global_settings { assumed_gamma 2.2 } //-----------------------------camera - light camera{ location <60,60,10> sky <0, 0, 1> right <-image_width/image_height,0,0> look_at <0, 0, 0.7> angle 5.8 } light_source{ <200,400,300> color rgb 1.5} background {color rgb<1,1,0.9>*0.9 } //========================== Half_Hollowed_Rounded_Cylinder2 object{ Half_Hollowed_Rounded_Cylinder2(4,1.2,0.3,0.1,1,0) texture { pigment{rgbf<1,1,0,0.3>} finish{phong 1} } } //--------------------------------coordinate axis #declare SX=4.5; #declare SY=3.5; #declare SZ=3.2; #declare SC=0.7; union{ union{ cylinder{x*-5,x*(SX-0.5),0.05} cone{x*(SX-0.5),0.1,x*(SX+0.1),0} text{ttf "cyrvetic.ttf","X",0.1,0 scale SC rotate<90,0,-30> translate <SX+0.4, 0, -0.5> } pigment{color rgb<0.2,1,0.2>} } union{ cylinder{y*-5,y*(SY+0.5),0.05} cone{y*(SY+0.5),0.1,y*(SY+1.1),0} text{ttf "cyrvetic.ttf","Y",0.1,0 scale SC rotate<90,0,-30> translate <-0.1,SY+2,-0.5> } pigment{color rgb<0.2,0.2,1.0>} } union{ cylinder{z*-5,z*(SZ-0.5),0.05} cone{z*(SZ-0.5),0.1,z*(SZ+0.1),0} text{ttf "cyrvetic.ttf","Z",0.1,0 scale SC rotate<90,0,120> translate <-0.2,0.2,SZ-0.2> } pigment{color rgb<1.0,0.2,0.2>} } }

< Half_Hollowed_Rounded_Cylinder2 の構文 >

object{ Half_Hollowed_Rounded_Cylinder2 ( Length , Out_Radius , Corner_Radius , Border_Radius , BorderScale, UseMerge ) [ OBJECT_MODIFIERS... ] }
object 物体のキーワード
Half_Hollowed_Rounded_Cylinder2 バスタブ2
Length バスタブの長さ
Out_Radius バスタブ外側の半径
Corner_Radius バスタブ角の丸み半径
Border_Radius バスタブふちの半径(バスタブの厚さ)
BorderScale バスタブふちの形状調整 ( 0 以上の数値)
0 で平坦、1 で丸い形状、1 以上は鋭くなる。
UseMerge マージの使用: 無 0 、有 1
OBJECT_MODIFIERS... 物体の変形・テクスチャなどの設定

 


14.11-13 ナス型リング[Round_Conic_Torus]

2つのトーラスを繋ぎ合わせたような形で、ナスの形をしたトーラスである。

図14.11-13a ナス型リング[Round_Conic_Torus]

ナス型リングは、xy 平面上にある2つのトーラスが基本である。原点に第1トーラス、y 軸上に第2トーラスを設定し、それら2つのトーラスを繋ぎ合わせた形状である。

図14.11-13b ナス型リングの生成位置

//------------------ Fig.14.11-13a Round_Conic_Torus #version 3.7 #include "colors.inc" #include "textures.inc" #include "Woods.inc" #include "stones.inc" #include "glass.inc" #include "metals.inc" #include "skies.inc" #include "stars.inc" #include "chars.inc" #include "shapes.inc" #include "shapes2.inc" #include "shapes3.inc" global_settings { assumed_gamma 2.2 } //-----------------------------camera - light camera{ location <0,-14,8> sky <0, 0, 1> right <-image_width/image_height,0,0> look_at <0, 0, 0> angle 25 } light_source{<100,-400,500> color rgb 1.5 parallel point_at 0 } //=================================== Round_Conic_Torus #declare T1=texture {T_Gold_1C} #declare T2=texture {Silver1} object{ Round_Conic_Torus(2, 0.6,1, 0.2,0) texture{T1} scale 0.6 rotate <90,0,0> translate<-1,-3,1.5> } object{ Round_Conic_Torus(1.8, 1.2,0.8, 0.12,0) texture{T2} scale 0.8 rotate <0,0,90> translate<1.3,-3,1.5> } //---------------------------------floor #declare CA1=rgb<0.85,0.85,0.8>; #declare CA2=rgb<0.85,0.85,0.8>*1.2; plane{ z, 0 pigment{ checker color CA1, color CA2 scale 0.3 } } //----------------sky sky_sphere{ pigment{ wrinkles color_map{ [ 0.3 SkyBlue] [ 0.9 White ] } scale <1, 0.2, 0.2> } }
//------------------ Fig.14.11-13b Round_Conic_Torus #version 3.7 #include "colors.inc" #include "textures.inc" #include "Woods.inc" #include "stones.inc" #include "glass.inc" #include "metals.inc" #include "skies.inc" #include "stars.inc" #include "chars.inc" #include "shapes.inc" #include "shapes2.inc" #include "shapes3.inc" global_settings { assumed_gamma 2.2 } //-----------------------------camera - light camera{ location <60,60,50> sky <0, 0, 1> right <-image_width/image_height,0,0> look_at <0, 0, 0.3> angle 5 } light_source{ <200,400,300> color rgb 1.5} background {color rgb<1,1,0.9>*0.9 } //=================================== Round_Conic_Torus object{ Round_Conic_Torus(1.5, 1.2,0.8, 0.17,0) texture{pigment{rgbf<1,1,0,0.3>} finish{phong 1} } } //--------------------------------coordinate axis #declare SX=4.5; #declare SY=3.5; #declare SZ=3.2; #declare SC=0.7; union{ union{ cylinder{x*-5,x*(SX-0.5),0.05} cone{x*(SX-0.5),0.1,x*(SX+0.1),0} text{ttf "cyrvetic.ttf","X",0.1,0 scale SC rotate<90,0,-50> translate <SX+0.4, 0, -0.5> } pigment{color rgb<0.2,1,0.2>} } union{ cylinder{y*-5,y*(SY+0.5),0.05} cone{y*(SY+0.5),0.1,y*(SY+1.1),0} text{ttf "cyrvetic.ttf","Y",0.1,0 scale SC rotate<90,0,-50> translate <-0.1,SY+2,-0.5> } pigment{color rgb<0.2,0.2,1.0>} } union{ cylinder{z*-5,z*(SZ-0.5),0.05} cone{z*(SZ-0.5),0.1,z*(SZ+0.1),0} text{ttf "cyrvetic.ttf","Z",0.1,0 scale SC rotate<90,0,140> translate <-0.2,0.2,SZ-0.2> } pigment{color rgb<1.0,0.2,0.2>} } }

< Round_Conic_Torus の構文 >

object{ Round_Conic_Torus ( Distance , Major2_Radius , Major1_Radius , Minor_Radius , UseMerge ) [ OBJECT_MODIFIERS... ] }
object 物体のキーワード
Round_Conic_Torus ナス型リング
Distance 原点から第2トーラス中心までの距離
Major2_Radius 第2トーラスの大半径(大きさ)
Major1_Radius 第1トーラスの大半径(大きさ)
Minor_Radius トーラスの小半径(太さ)
UseMerge マージの使用: 無 0 、有 1
OBJECT_MODIFIERS... 物体の変形・テクスチャなどの設定

※ 第1トーラスは中心が原点にあり、第2トーラスは中心が y 軸上にある。

 


14.11-14 ナス型柱[Round_Conic_Prism]

ナス型柱は、ナス型リングを柱状にしたものである。

図14.11-14a ナス型柱[Round_Conic_Prism]

ナス型柱は、ナス型リングを z 軸のマイナス方向へ引き延ばして生成される。

図14.11-14b ナス型柱の生成位置

//------------------ Fig.14.11-14a Round_Conic_Prism #version 3.7 #include "colors.inc" #include "textures.inc" #include "Woods.inc" #include "stones.inc" #include "glass.inc" #include "metals.inc" #include "skies.inc" #include "stars.inc" #include "chars.inc" #include "shapes.inc" #include "shapes2.inc" #include "shapes3.inc" global_settings { assumed_gamma 2.2 } //-----------------------------camera - light camera{ location <0,-14,8> sky <0, 0, 1> right <-image_width/image_height,0,0> look_at <0, 0, 0> angle 25 } light_source{<100,-400,500> color rgb 1.5 parallel point_at 0 } //=================================== Round_Conic_Prism #declare T1=texture {New_Penny} #declare T2=texture{pigment{YellowGreen} finish{phong 1} normal{ spotted 2 scale 0.1} } object{ Round_Conic_Prism(8, 1.5,1.5, 2,0.2,0) texture {T1} scale 0.5 rotate <0,0,-30> translate<-1.7,-3,1.5> } object{ Round_Conic_Prism(1.6, 1.3,1, 5,0.2,0) texture {T2} scale 0.5 translate<1.5,-4,3.3> } //---------------------------------floor #declare CA1=rgb<0.85,0.85,0.8>; #declare CA2=rgb<0.85,0.85,0.8>*1.2; plane{ z, 0 pigment{ checker color CA1, color CA2 scale 0.3 } } //----------------sky sky_sphere{ pigment{ wrinkles color_map{ [ 0.3 SkyBlue] [ 0.9 White ] } scale <1, 0.2, 0.2> } }
//------------------ Fig.14.11-14b Round_Conic_Prism #version 3.7 #include "colors.inc" #include "textures.inc" #include "Woods.inc" #include "stones.inc" #include "glass.inc" #include "metals.inc" #include "skies.inc" #include "stars.inc" #include "chars.inc" #include "shapes.inc" #include "shapes2.inc" #include "shapes3.inc" global_settings { assumed_gamma 2.2 } //-----------------------------camera - light camera{ location <60,60,50> sky <0, 0, 1> right <-image_width/image_height,0,0> look_at <0, 0, 0.3> angle 5 } light_source{ <200,400,300> color rgb 1.5} background {color rgb<1,1,0.9>*0.9 } //============================== Round_Conic_Prism object{ Round_Conic_Prism(1.5, 1.2,0.8, 1.5,0.2,0) texture { pigment{rgbf<1,1,0,0.3>} finish{phong 1} } } //--------------------------------coordinate axis #declare SX=4.5; #declare SY=3.5; #declare SZ=3.2; #declare SC=0.7; union{ union{ cylinder{x*-5,x*(SX-0.5),0.05} cone{x*(SX-0.5),0.1,x*(SX+0.1),0} text{ttf "cyrvetic.ttf","X",0.1,0 scale SC rotate<90,0,-50> translate <SX+0.4, 0, -0.5> } pigment{color rgb<0.2,1,0.2>} } union{ cylinder{y*-5,y*(SY+0.5),0.05} cone{y*(SY+0.5),0.1,y*(SY+1.1),0} text{ttf "cyrvetic.ttf","Y",0.1,0 scale SC rotate<90,0,-50> translate <-0.1,SY+2,-0.5> } pigment{color rgb<0.2,0.2,1.0>} } union{ cylinder{z*-5,z*(SZ-0.5),0.05} cone{z*(SZ-0.5),0.1,z*(SZ+0.1),0} text{ttf "cyrvetic.ttf","Z",0.1,0 scale SC rotate<90,0,140> translate <-0.2,0.2,SZ-0.2> } pigment{color rgb<1.0,0.2,0.2>} } }

< Round_Conic_Prism の構文 >

object{ Round_Conic_Prism ( Distance , Major2_Radius , Major1_Radius , Z_Length , Minor_Radius , UseMerge ) [ OBJECT_MODIFIERS... ] }
object 物体のキーワード
Round_Conic_Prism ナス型柱
Distance 原点から第2トーラスまでの距離
Major2_Radius 第2トーラス大半径(大きさ):y 軸上
Major1_Radius 第1トーラス大半径(大きさ):原点
Z_Length 柱の長さ(z 軸 マイナス方向の長さ)
Minor_Radius 柱端部の丸み(トーラスの小半径)
UseMerge マージの使用: 無 0 、有 1
OBJECT_MODIFIERS... 物体の変形・テクスチャなどの設定

 


14.11-15 チューブ正多角形[Round_N_Tube_Polygon]

この形状は、辺がチューブで構成された正多角形である。

図14.11-15a チューブ正多角形[Round_N_Tube_Polygon]

チューブの正多角形は、原点を中心に xz 平面上に生成される。

図14.11-15b チューブ正多角形の生成位置

//--------------- Fig.14.11-15a Round_N_Tube_Polygon #version 3.7 #include "colors.inc" #include "textures.inc" #include "Woods.inc" #include "stones.inc" #include "glass.inc" #include "metals.inc" #include "skies.inc" #include "stars.inc" #include "chars.inc" #include "shapes.inc" #include "shapes2.inc" #include "shapes3.inc" global_settings { assumed_gamma 2.2 } //-----------------------------camera - light camera{ location <0,-14,8> sky <0, 0, 1> right <-image_width/image_height,0,0> look_at <0, 0, .4> angle 25 } light_source{<100,-400,500> color rgb 1.5 parallel point_at 0 } //============================ Round_N_Tube_Polygon #declare T1=texture{T_Gold_1C} #declare T2=texture{pigment{MediumTurquoise} finish{phong 1} } object{ Round_N_Tube_Polygon (6,0.3,2.5,0.3,1,0) texture{T1} scale 0.5 rotate x*90 translate<-0.5,-2,1.7> } object{ Round_N_Tube_Polygon (8,0.2,1.8,0.3,0,0) texture {T2} scale 0.5 rotate x*90 translate<0.5,-3,1.5> } //---------------------------------floor #declare CA1=rgb<0.85,0.85,0.8>; #declare CA2=rgb<0.85,0.85,0.8>*1.2; plane{ z, 0 pigment{ checker color CA1, color CA2 scale 0.3 } } //----------------sky sky_sphere{ pigment{ wrinkles color_map{ [ 0.3 SkyBlue] [ 0.9 White ] } scale <1, 0.2, 0.2> } }
//--------------- Fig.14.11-15b Round_N_Tube_Polygon #version 3.7 #include "colors.inc" #include "textures.inc" #include "Woods.inc" #include "stones.inc" #include "glass.inc" #include "metals.inc" #include "skies.inc" #include "stars.inc" #include "chars.inc" #include "shapes.inc" #include "shapes2.inc" #include "shapes3.inc" global_settings { assumed_gamma 2.2 } //-----------------------------camera - light camera{ location <60,60,10> sky <0, 0, 1> right <-image_width/image_height,0,0> look_at <0, 0, 0.7> angle 5.8 } light_source{ <200,400,300> color rgb 1.5} background {color rgb<1,1,0.9>*0.9 } //============================ Round_N_Tube_Polygon object{ Round_N_Tube_Polygon ( 8,0.3,2,0.3,0,0) texture{pigment{rgbf<1,1,0,0.3>} finish{phong 1} } scale 0.6 rotate x*90 } //--------------------------------coordinate axis #declare SX=4.5; #declare SY=3.5; #declare SZ=3.2; #declare SC=0.7; union{ union{ cylinder{x*-5,x*(SX-0.5),0.05} cone{x*(SX-0.5),0.1,x*(SX+0.1),0} text{ttf "cyrvetic.ttf","X",0.1,0 scale SC rotate<90,0,-30> translate <SX+0.4, 0, -0.5> } pigment{color rgb<0.2,1,0.2>} } union{ cylinder{y*-5,y*(SY+0.5),0.05} cone{y*(SY+0.5),0.1,y*(SY+1.1),0} text{ttf "cyrvetic.ttf","Y",0.1,0 scale SC rotate<90,0,-30> translate <-0.1,SY+2,-0.5> } pigment{color rgb<0.2,0.2,1.0>} } union{ cylinder{z*-5,z*(SZ-0.5),0.05} cone{z*(SZ-0.5),0.1,z*(SZ+0.1),0} text{ttf "cyrvetic.ttf","Z",0.1,0 scale SC rotate<90,0,120> translate <-0.2,0.2,SZ-0.2> } pigment{color rgb<1.0,0.2,0.2>} } }

< Round_N_Tube_Polygon の構文 >

object{ Round_N_Tube_Polygon ( N_Sides , Tube_Radius , N_Radius , Edge_Radius , Filled , UseMerge ) [ OBJECT_MODIFIERS... ] }
object 物体のキーワード
Round_N_Tube_Polygon チューブ正多角形
N_Sides 多角形の辺数
Tube_Radius チューブの半径
N_Radius 多角形の半径(内接円の半径)
Edge_Radius 多角形の丸み半径
Filled 多角形の面生成: 無 0 、有 1
UseMerge マージの使用: 無 0 、有 1
OBJECT_MODIFIERS... 物体の変形・テクスチャなどの設定

 

 


(End) 14.11 形状3b