Difference between revisions of "Povray"

From BRL-CAD
 
(11 intermediate revisions by the same user not shown)
Line 8: Line 8:
  
 
= Primitives that are working properly =  
 
= Primitives that are working properly =  
 +
= Arbitrary convex polyhedra =
 +
== ARB8 ==
 +
This primitive is formed in POV-Ray using mesh.The mesh object can be used to efficiently store large numbers of triangles.
 +
Example:
 +
    mesh{triangle{a,b,c}triangle{a,c,d}triangle{a,d,f}
 +
    triangle{g,h,c}triangle{e,f,g}triangle{e,g,h}}
 +
 +
== ARBN ==
 +
An arbn record is specified by N sets of intersecting planes, each defined by four coefficients:
 +
 +
* the {X, Y, Z} coefficients of the plane's normal vector pointing outward from the center of the arbn shape, and
 +
*the perpendicular distance of that plane from the origin.
 +
Its exported in POV-Ray by using intersection of Planes.
 +
Example:
 +
    intersection{ plane{<x, y, z coefficients>, normal} .... }
 +
 +
 +
= Ellipsoids =
 +
== ELL ==
 +
This primitive is named as spheroid in POV-Ray. It is having
 +
Center Vector, Radius Vector
 +
Example:
 +
      Spheroid(<-1.50,3.00,-2.00>,<2.0,1.2,2.5> )
 +
 +
== ELLG, ELL1 ==
 +
These primitives are exported under Ell
 +
 +
== EHY ==
 +
Elliptical Hyperboloid of BRL-CAD can be formed by POV-Ray.
 +
Currently its coordinates are exported successfully and is done by using quadric equartions of POV-Ray
 +
 +
== EPA ==
 +
Elliptical Paraboloid in BRL-CAD. Its coordinates are exported successfully and is done by using quadric equartions of POV-Ray
 +
 
== Sphere ==
 
== Sphere ==
 
Sphere is formed by
 
Sphere is formed by
Line 14: Line 48:
 
       sphere { Center, Radius [OBJECT_MODIFIERS...]}
 
       sphere { Center, Radius [OBJECT_MODIFIERS...]}
  
== Torus ==
+
 
Torus is created using
+
= Cones and Cylinders =
major radius and minor radius
+
== Truncated General Cone ==
 +
This primitive of BRL-CAD is formed by using Supercone of POV-Ray.
 
Example:
 
Example:
     torus { 4, 1 pigment { Green }}
+
     Supercone( //point A, axis Ax, axis Az:<0.0,0.0,0.0>, 0.5, 1.0,
 +
                // point B, axis Bx, axis Bz:<0.0,1.5,0.0>, 0.7, 0.4)}
  
 
== Cone ==
 
== Cone ==
Line 26: Line 62:
 
Example:
 
Example:
 
       cone {<0, 1, 0>, 0.3  <1, 2, 3>, 1.0 texture { T_Stone25 scale 4 }}
 
       cone {<0, 1, 0>, 0.3  <1, 2, 3>, 1.0 texture { T_Stone25 scale 4 }}
 +
 +
== TEC ==
 +
Its also exported under TGC.
 +
 +
== REC ==
 +
Its exported nuder TGC.
 +
 +
== TRC ==
 +
Its also under TGC
  
 
== Cylender ==
 
== Cylender ==
Line 33: Line 78:
 
       cylinder { <0, 1, 0>,<1, 2, 3>,0.5 }}
 
       cylinder { <0, 1, 0>,<1, 2, 3>,0.5 }}
  
== Ellipsoids ==
+
== RHC ==
This primitive is named as spheroid in POV-Ray. It is having
+
Right Hyperbolic Cylinder in BRL-CAD. Coordinates are exported successfully. It can be formed by using function
Center Vector, Radius Vector
+
      function { pow(x,2) + y }
Example:
+
of POV-Ray.
      Spheroid(<-1.50,3.00,-2.00>,<2.0,1.2,2.5> )
+
 
 +
== RPC ==
 +
Right Parabolic Cylinder in BRL-CAD. Coordinates are exported successfully. It also formed by the using functions of POV-Ray.
 +
 
 +
= Other Solids =
  
== ARB8 ==
+
== Torus ==
This primitive is formed in POV-Ray using mesh.The mesh object can be used to efficiently store large numbers of triangles.
+
Torus is created using
 +
major radius and minor radius
 
Example:
 
Example:
     mesh{triangle{a,b,c}triangle{a,c,d}triangle{a,d,f}
+
     torus { 4, 1 pigment { Green }}
    triangle{g,h,c}triangle{e,f,g}triangle{e,g,h}}
 
  
 
== Particle ==
 
== Particle ==
Line 52: Line 101:
 
     // point B, radius B:<0,1,0>, 0.40,)
 
     // point B, radius B:<0,1,0>, 0.40,)
  
== Truncated General Cone ==
+
== half ==
This primitive of BRL-CAD is formed by using Supercone of POV-Ray.  
+
Half primitive of BRL-CAD is export into POV-Ray as Plane.
 
Example:
 
Example:
    Supercone( //point A, axis Ax, axis Az:<0.0,0.0,0.0>, 0.5, 1.0,
+
      plane { <Normal>, Distance }
                // point B, axis Bx, axis Bz:<0.0,1.5,0.0>, 0.7, 0.4)}
+
 
 +
== BOT ==
 +
Bag of triangles in BRL-CAD. Its exported by using triangles in POV-Ray.
 +
 
  
 
= Primitives that are under progress =
 
= Primitives that are under progress =
Line 64: Line 116:
 
       f_torus(x,y,z,1*(y+0.4),0.1 )
 
       f_torus(x,y,z,1*(y+0.4),0.1 )
  
== EHY ==
+
== extrude ==
Elliptical Hyperboloid of BRL-CAD can be formed by POV-Ray.
+
Currently, data of extrude is exported successfully. Remaining part is how to export sketch and relate it with extrude.
Currently its coordinates are exported successfully but ehy is not working
 
 
 
== EPA ==
 
Elliptical Paraboloid in BRL-CAD. Its coordinates are exported successfully but ehy is not working yet.
 
 
 
== RHC ==
 
Right Hyperbolic Cylinder in BRL-CAD. Coordinates are exported successfully. It can be formed by using function
 
      function { pow(x,2) + y }
 
of POV-Ray but its not working well. Its under discussion with POV-Ray community
 
 
 
== RPC ==
 
Right Parabolic Cylinder in BRL-CAD. Coordinates are exported successfully. It also formed by the using functions of POV-Ray but under work.
 
  
 
= Primitives that are not under work yet =
 
= Primitives that are not under work yet =
 
== Arbitrary convex polyhedra ==
 
 
=== ARBN ===
 
 
== Ellipsoids ==
 
 
=== ELLG ===
 
=== ELL1 ===
 
 
== Cones and Cylinders ==
 
 
=== TEC ===
 
=== TRC ===
 
  
 
== derived from 2d ==
 
== derived from 2d ==
  
=== extrude ===
 
 
=== revolve ===
 
=== revolve ===
 
=== dsp ===
 
=== dsp ===
Line 111: Line 136:
 
=== spline ===
 
=== spline ===
 
=== vol ===
 
=== vol ===
=== bot ===
 
 
=== poly ===
 
=== poly ===
 +
=== hrt ===
  
 
== Other ==
 
== Other ==
Line 118: Line 143:
 
=== Sketch ===
 
=== Sketch ===
 
=== grip ===
 
=== grip ===
=== half ===
 
 
=== binunif ===
 
=== binunif ===
 
=== submodel ===
 
=== submodel ===

Latest revision as of 13:43, 15 August 2015

This article provides knowledge about different types of geometric primitive objects that can be exported from BRL-CAD to POV-Ray geometry file. Their properties, functions used for them, parameters are discussed in section below.

To Know more about POV-Ray, here are some links below:

Below is the list of primitives that are working/exported correctly, partially and not touched yet.

Primitives that are working properly[edit]

Arbitrary convex polyhedra[edit]

ARB8[edit]

This primitive is formed in POV-Ray using mesh.The mesh object can be used to efficiently store large numbers of triangles. Example:

    mesh{triangle{a,b,c}triangle{a,c,d}triangle{a,d,f}
    triangle{g,h,c}triangle{e,f,g}triangle{e,g,h}}

ARBN[edit]

An arbn record is specified by N sets of intersecting planes, each defined by four coefficients:

  • the {X, Y, Z} coefficients of the plane's normal vector pointing outward from the center of the arbn shape, and
  • the perpendicular distance of that plane from the origin.

Its exported in POV-Ray by using intersection of Planes. Example:

    intersection{ plane{<x, y, z coefficients>, normal} .... }


Ellipsoids[edit]

ELL[edit]

This primitive is named as spheroid in POV-Ray. It is having Center Vector, Radius Vector Example:

     Spheroid(<-1.50,3.00,-2.00>,<2.0,1.2,2.5> )

ELLG, ELL1[edit]

These primitives are exported under Ell

EHY[edit]

Elliptical Hyperboloid of BRL-CAD can be formed by POV-Ray. Currently its coordinates are exported successfully and is done by using quadric equartions of POV-Ray

EPA[edit]

Elliptical Paraboloid in BRL-CAD. Its coordinates are exported successfully and is done by using quadric equartions of POV-Ray

Sphere[edit]

Sphere is formed by Center and Radius Example:

     sphere { Center, Radius [OBJECT_MODIFIERS...]}


Cones and Cylinders[edit]

Truncated General Cone[edit]

This primitive of BRL-CAD is formed by using Supercone of POV-Ray. Example:

    Supercone( //point A, axis Ax, axis Az:<0.0,0.0,0.0>, 0.5, 1.0,
               // point B, axis Bx, axis Bz:<0.0,1.5,0.0>, 0.7, 0.4)}

Cone[edit]

This primitive of BRL-CAD is named as Cone in POV-Ray. It is formed as Center and radius of one end Center and radius of other end Example:

     cone {<0, 1, 0>, 0.3  <1, 2, 3>, 1.0 texture { T_Stone25 scale 4 }}

TEC[edit]

Its also exported under TGC.

REC[edit]

Its exported nuder TGC.

TRC[edit]

Its also under TGC

Cylender[edit]

This is formed by Cylender of POV-Ray. center_of_one_end, center_of_other_end and Radius Example:

     cylinder { <0, 1, 0>,<1, 2, 3>,0.5 }}

RHC[edit]

Right Hyperbolic Cylinder in BRL-CAD. Coordinates are exported successfully. It can be formed by using function

     function { pow(x,2) + y }

of POV-Ray.

RPC[edit]

Right Parabolic Cylinder in BRL-CAD. Coordinates are exported successfully. It also formed by the using functions of POV-Ray.

Other Solids[edit]

Torus[edit]

Torus is created using major radius and minor radius Example:

    torus { 4, 1 pigment { Green }}

Particle[edit]

This primitives of BRL-CAD is formed in POV-Ray by using Round_Cone2 of POV-Ray. Example:

    Round_Cone2(
    //point A, radius A: <0,0,0>,0.70,
    // point B, radius B:<0,1,0>, 0.40,)

half[edit]

Half primitive of BRL-CAD is export into POV-Ray as Plane. Example:

     plane { <Normal>, Distance }

BOT[edit]

Bag of triangles in BRL-CAD. Its exported by using triangles in POV-Ray.


Primitives that are under progress[edit]

ETO[edit]

Elliptical torus of BRL-CAD can be formed by using some methods. One of them is by using function i.e. f_torus Example:

     f_torus(x,y,z,1*(y+0.4),0.1 )

extrude[edit]

Currently, data of extrude is exported successfully. Remaining part is how to export sketch and relate it with extrude.

Primitives that are not under work yet[edit]

derived from 2d[edit]

revolve[edit]

dsp[edit]

ebm[edit]

hf[edit]

Other solids[edit]

pipe[edit]

ars[edit]

metaball[edit]

nurb[edit]

spline[edit]

vol[edit]

poly[edit]

hrt[edit]

Other[edit]

Sketch[edit]

grip[edit]

binunif[edit]

submodel[edit]