IVCON - 3D Graphics File Conversion
IVCON can read and write a small variety of 3D graphics file
formats, converting from one to the other. This is by no means a
perfect or even correct program! It was home-grown, and developed,
as needed, to handle a particular set of files. It can make mistakes,
or crash, rather more often than software you pay for, written by
someone who knows what they're doing.
The supported formats include:
The program can be used in command line form, as in:
ivcon input.iv output.stl
or can be used in an interactive mode, in which input and output
files can be read or converted in any order.
Graphics file formats are poorly documented; hence this program
was written primarily by examining typical files and struggling
to interpret them. Particularly in the case of Inventor and DXF
files, the program is not able to handle all the subtleties of
the file format, and may mangle data, or even crash.
Helpful corrections to the 3DS reader were supplied by John F Flanagan.
The GMOD reader and writer were written and supplied by
Zik Saleeba.
Improvements to the DXF routines to handle polygon oriented files
were supplied by Zik Saleeba. The 3DS reader is based on a program
by Martin van Velsen, with the help of Gert van der Spoel.
IVCON is a C version of the FORTRAN
IVREAD program.
Source code files you may copy include:
Data files you may copy include:
-
box.3ds, a sample 3DS file;
-
cube.ase, a sample ASE file;
-
cube.byu, a sample BYU file;
-
diamond.dxf, a sample DXF file;
-
cube.hrc, a sample HRC file;
-
materials.iv, a sample Inventor file;
-
cube.obj, a sample OBJ file;
-
cube.pov, a sample POV file;
-
cube_face.smf, a sample SMF file;
-
magnolia.stl, a sample STL file;
-
cube.tec, a sample TECPLOT file;
-
cube.tria, a sample ASCII triangle file;
-
diamond.vla, a sample VLA file;
-
cube.xgl, a sample XGL file;
The list of routines includes:
-
MAIN is the main program for converting graphics files.
-
ASE_READ reads an AutoCAD ASE file.
-
ASE_WRITE writes graphics information to an AutoCAD ASE file.
-
BYU_READ reads graphics information from a Movie.BYU file.
-
BYU_WRITE writes graphics information to a Movie.BYU file.
-
CHR_INDEX_LAST reports the last occurrence of a character in a string.
-
CHAR_PAD "pads" a character in a string with a blank on either side.
-
COMMAND_LINE carries out a command-line session of file conversion.
-
COR3_NORMAL_SET computes node normal vectors.
-
COR3_RANGE reports the range of the graphics data.
-
DATA_CHECK checks the input data.
-
DATA_INIT initializes the internal graphics data.
-
DATA_READ reads a file into internal graphics data.
-
DATA_REPORT gives a summary of the contents of the data file.
-
DATA_WRITE writes the graphics data to the output file.
-
DXF_READ reads an AutoCAD DXF file.
-
DXF_WRITE writes graphics information to an AutoCAD DXF file.
-
EDGE_NULL_DELETE deletes face edges with zero length.
-
FACE_AREA_SET sets the area of faces.
-
FACE_NORMAL_AVE sets face normals as average of face vertex normals.
-
FACE_NULL_DELETE deletes faces of order less than 3.
-
FACE_PRINT prints out information about a face.
-
FACE_SUBSET selects a subset of the current faces as the new object.
-
FACE_TO_LINE converts face information to line information.
-
FACE_TO_VERTEX_MAT extends face material definitions to vertices.
-
FILE_EXT picks out the extension in a file name.
-
GMOD_ARCH_CHECK inquires into some features of the computer architecture.
-
GMOD_READ reads graphics information from a Golgotha GMOD file.
-
GMOD_READ_FLOAT reads a float from a Golgotha GMOD file.
-
GMOD_READ_W16 reads a 16 bit word from a Golgotha GMOD file.
-
GMOD_READ_W32 reads a 32 bit word from a Golgotha GMOD file.
-
GMOD_WRITE writes graphics data to a Golgotha GMOD file.
-
GMOD_WRITE_FLOAT writes a float to a Golgotha GMOD file.
-
GMOD_WRITE_W16 writes a 16 bit word to a Golgotha GMOD file.
-
GMOD_WRITE writes a 32 bit word to a Golgotha GMOD file.
-
HELLO prints an explanatory header message.
-
HELP prints a list of the interactive commands.
-
HRC_READ reads graphics information from a SoftImage HRC file.
-
HRC_WRITE writes graphics data to an HRC SoftImage file.
-
INIT_PROGRAM_DATA initializes the internal program information.
-
INTERACT carries on an interactive session with the user.
-
IV_READ reads graphics information from an Inventor file.
-
IV_WRITE writes graphics information to an Inventor file.
-
IVEC_MAX returns the maximum element in an integer array.
-
LEQI compares two strings for equality, disregarding case.
-
NEWS reports the program change history.
-
NODE_TO_VERTEX_MAT extends node material definitions to vertices.
-
OBJ_READ reads a Wavefront OBJ file.
-
OBJ_WRITE writes graphics information to a WaveFront OBJ file.
-
POV_WRITE writes graphics information to a POV file.
-
RCOL_FIND finds if a vector occurs in a table.
-
REVERSE_BYTES_FLOAT reverses byte data representing a float.
-
RGB_TO_HUE converts (R,G,B) colors to a hue value between 0 and 1.
-
SMF_READ reads an SMF file.
-
SMF_WRITE writes an SMF file.
-
STLA_READ reads an ASCII STL StereoLithography file.
-
STLA_WRITE writes an ASCII STL StereoLithography file.
-
STLB_READ reads a binary STL StereoLithography file.
-
STLB_WRITE writes a binary STL StereoLithography file.
-
TDS_READ reads a 3D Studio Max 3DS file.
-
TDS_WRITE writes a 3D Studio Max 3DS file.
-
TEC_WRITE writes the graphics data to a TECPLOT file.
-
TMAT_INIT initializes the geometric transformation matrix.
-
TMAT_MXM multiplies two geometric transformation matrices.
-
TMAT_MXP multiplies a geometric transformation matrix times a point.
-
TMAT_MXP2 multiplies a geometric transformation matrix times N points.
-
TMAT_MXV multiplies a geometric transformation matrix times a vector.
-
TMAT_ROT_AXIS applies an axis rotation to the geometric transformation matrix.
-
TMAT_ROT_VECTOR applies a rotation about a vector to the geometric transformation matrix.
-
TMAT_SCALE applies a scaling to the geometric transformation matrix.
-
TMAT_SHEAR applies a shear to the geometric transformation matrix.
-
TMAT_TRANS applies a translation to the geometric transformation matrix.
-
TRIA_READ reads the graphics data from an ASCII triangle file.
-
TRIA_WRITE writes the graphics data to an ASCII triangle file.
-
TRIB_READ reads the graphics data from a binary triangle file.
-
TRIB_WRITE writes the graphics data to a binary triangle file.
-
TXT_WRITE writes the graphics data to a text file.
-
UCD_WRITE writes graphics data to an AVS UCD file.
-
VERTEX_NORMAL_SET recomputes the face vertex normal vectors.
-
VERTEX_TO_FACE_MAT extends vertex material definitions to faces.
-
VERTEX_TO_NODE_MAT extends vertex material definitions to nodes.
-
VLA_READ reads a VLA file.
-
VLA_WRITE writes a VLA file.
-
WRL_WRITE writes graphics data to a WRL file.
-
XGL_WRITE writes graphics data to an XGL file.
Back to the graphics software page.
Last revised on 17 September 2001.