Up
Next
off2pov - converts an OFF file to POV format
off2pov [options] input_files
Convert OFF files to POV format for display with POV-ray.
- input_files
- input files in OFF format, or if not given the program reads from standard input
- -h
- program help
- -v <rad>
- radius of vertex spheres (0 for no vertex sphere), or 'b' to have radius of
balls of the maximum size without overlap (default: ball_rad/8)
- -e <rad>
- radius of edge cylinders (default: vertex_rad/1.5)
- -x <elems>
- hide elements. The element string can include v, e and f
to hide, respectively, vertices, edges and faces
- -n
- show vertex numbers
- -O <type>
- output type, can be: a all in one POV file (default),
s separate files, o objects only,
t template only
- -I <fils>
- include files (separated by commas) in the POV scene file. Files
default_pov.inc and the name of the output file with '.'
changed to '_' and followed by .inc are always included.
- -i <fils>
- include files (separated by commas) in every POV geometry. Files
default_off.inc and the name of the output file with '.'
changed to '_' and followed by _off.inc are always included.
- -o <file>
- write output to file, if this option is not used
the program writes to standard output
Viewing Options
- -D <dist>
- distance to camera
- -C <cent>
- centre of points, in form "x_val,y_val,z_val" (default: calculated)
- -L <look>
- point to look at, in form "x_val,y_val,z_val" (default: points centre)
- -R <rot>
- rotate about axes through centre of points, in
form "x_val,y_val,z_val" (degrees)
- -P <pers>
- narrow the angle of perspective (range 0-100, default: 2 mono, 4 stereo)
- -W <shad>
- use lighting with shadows can be 0 (default) yes
for mono no for stereo, 1 yes, 2 no
- -S <ster>
- produce stereo output, val is 0 (default) mono,
1 stereo with one image file, 2 stereo with two image
files (use something like povrays +KFF2 option for
output), 3 mono with four views around the object
Precision Options
- -d <dgts>
- number of significant digits for output (default 17) or if
negative then the number of digits after the decimal point
- -t
- display type for faces 0 POV polygons, 1 (default)
flattened POV polygons, 2 triangulate polygons by joining
each edge to a centre point. (Incomplete solution to
rendering non-simple polygons. Will not render all
polygons correctly.)
Draw a ball pack as balls
off2pov -v b -o pack.pov pack.off
Draw the other side of it
off2pov -v b -R 0,180,0 -o pack.pov pack.off
Draw an icosahedron without its faces
unipoly icosahedron | off2pov -x f -o icosa.pov
Draw an icosahedron without its vertex or edge elements
unipoly icosahedron | off2pov -x ve -o icosa.pov
Draw an icosahedron with thin vertex and edge elements
unipoly icosahedron | off2pov -v 0.01 -e 0.008 -o icosa.pov
The output POV file is easy to edit in a text editor. Many of the program
options which are used when creating the file can also be set afterwards
by editing the file.
The elements are drawn using POV-ray macros. These may be overriden,
using an include file passed with option -i, allowing processing
and custom drawing of the elements.
Points coinciding, or very close together, may cause no elements to be
drawn for the vertices or edges if default sizes are used. Instead, a
value can be set with -v or -e.
Use -v b to draw ball packs.
Shapes with self-intersecting faces generally need the -t option,
otherwise they may be displayed with missing areas. However this option
may draw parts of the face outside of the edges.
POV-ray may not be able to display the output, or may display it
incorrectly. I have tried to make the generated file robust, but
precision issues could cause problems in apparently correct POV files.
Including files and making changes by hand may easily break some of
the basic functionality, for example vertex numbering and some stereo
options.
Up:
Programs and Documentation
Next:
off_color - adds colours to an OFF file
Packinon Documentation 16.12.2005 -
http://packinon.sourceforge.net/