What does an OFF file look like?


An OFF file description and various examples can be found in the WebOOGL manual.

DX2Web outputs a color OFF file (heading COFF) with rgb color values per vertex. If no colors are specified, the default value is set to white.


Specifically DX2Web outputs a COFF file similar to the following one:

# off file with per vertex colors
COFF
8 6 12
     1.0 1.0 1.0 	.05 .8 .1 .75
     1.0 1.0 -1.0	.2 .05 .8 .75 
     1.0 -1.0 1.0	.9 .9 .02 .75 
     1.0 -1.0 -1.0 	.0 .7 .4 .75
     -1.0 1.0 1.0 	.1 .4 .7 .75
     -1.0 1.0 -1.0 	.7 .7 0 .75
     -1.0 -1.0 1.0 	0. 0. 0. .75
     -1.0 -1.0 -1.0 	1. 1. 1. .75	
     4 0 2 3 1  
     4 4 5 7 6  
     4 0 4 6 2  
     4 1 3 7 5  
     4 0 1 5 4  
     4 2 6 7 3  

The header is COFF notifying WebOOGL that a color polylist follows. The following line tells us the

The number of edges is currently (5/18/95) unimplemented in WebOOGL.

Following the object description numbers are the vertice positions [X, Y, Z], the RGB value of that vertices [Red, Green, Blue] and finally a number specifying the opacity of the object. For DX2Web objects opacity has not been implemented and the default value is 1 (fully opaque).