# Class ___Exporter

java.lang.Object
org.jmol.export.___Exporter

Direct Known Subclasses:
  `__CartesianExporter, _PovrayExporter, _TachyonExporter`

public abstract class ___Exporter extends Object

## Field Summary

Fields
Modifier and Type
Field
Description
`protected float`
`apertureAngle`
`protected short`
`backgroundColix`
`protected float`
`cameraDistance`
`protected P3`
`cameraPosition`
`protected final P3`
`center`
`protected String`
`commandLineOptions`
`protected String`
`commentChar`
`protected static final double`
`degreesPerRadian`
`protected int`
`depthZ`
`protected JmolRendererInterface`
`export3D`
`protected float`
`exportScale`
`protected String`
`fileName`
`protected P3`
`fixedRotationCenter`
`protected GData`
`gdata`
`protected V3`
`lightSource`
`short`
`lineWidthMad`
`protected OC`
`out`
`protected double`
`privateKey`
`protected P3`
`referenceCenter`
`protected float`
`scalePixelsPerAngstrom`
`protected int`
`screenHeight`
`protected int`
`screenWidth`
`protected int`
`slabZ`
`protected boolean`
`solidOnly`
`protected final P3`
`tempP1`
`protected final P3`
`tempP2`
`protected final P3`
`tempP3`
`protected final V3`
`tempV1`
`protected final V3`
`tempV2`
`protected TransformManager`
`tm`
`protected Viewer`
`vwr`

## Constructor Summary

Constructors
Constructor
Description
`___Exporter()`

## Method Summary

Modifier and Type
Method
Description
`protected abstract void`
`fillTriangle(short colix, T3 ptA0, T3 ptB0, T3 ptC0, boolean twoSided)`
`protected String`
`finalizeOutput()`
`protected String`
`finalizeOutput2()`
`protected int`
`fixScreenZ(int z)`
`protected int`
`getByteCount()`
`protected Lst<Short>`
`getColorList(int i00, short[] colixes, int nVertices, BS bsSelected, Map<Short,Integer> htColixes)`
input an array of colixes; returns a Vector for the color list and a HashTable for correlating the colix with a specific color index
`protected static MeshSurface`
`getConeMesh(P3 centerBase, M3 matRotateScale, short colix)`
`protected String`
`getExportDate()`
`protected String`
`getJmolPerspective()`
`protected M3`
`getRotationMatrix(P3 pt1, P3 pt2, float radius)`
`protected M3`
`getRotationMatrix(P3 pt1, P3 ptZ, float radius, P3 ptX, P3 ptY)`
`protected String`
`getTriad(T3 t)`
`protected String`
`getTriadC(T3 t)`
`protected boolean`
`initOutput(Viewer vwr, double privateKey, GData g3d, Map<String,Object> params)`
`protected static String`
`opacityFractionalFromArgb(int argb)`
`protected static String`
`opacityFractionalFromColix(short colix)`
`protected void`
`output(String data)`
`protected abstract void`
`output(T3 pt)`
`protected void`
`outputComment(String comment)`
`protected void`
`outputFooter()`
`protected abstract void`
`outputHeader()`
`protected void`
`outputJmolPerspective()`
`protected void`
`outputSurface(T3[] vertices, T3[] normals, short[] colixes, int[][] indices, short[] polygonColixes, int nVertices, int nPolygons, int nTriangles, BS bsPolygons, int faceVertexMax, short colix, Lst<Short> colorList, Map<Short,Integer> htColixes, P3 offset)`
`protected void`
`outputVertex(T3 pt, T3 offset)`
`protected void`
`outputVertices(T3[] vertices, int nVertices, T3 offset)`
`protected String`
`rgbFractionalFromArgb(int argb)`
`protected String`
`rgbFractionalFromColix(short colix)`
`protected static String`
`round(double number)`
`protected static String`
`round(T3 pt)`
`protected static void`
`setTempVertex(T3 pt, T3 offset, T3 ptTemp)`
`protected static String`
`translucencyFractionalFromColix(short colix)`

### Methods inherited from class Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Field Details

### solidOnly

protected boolean solidOnly

### vwr

protected Viewer vwr

### tm

protected TransformManager tm

### privateKey

protected double privateKey

### export3D

protected JmolRendererInterface export3D

### out

protected OC out

### fileName

protected String fileName

### commandLineOptions

protected String commandLineOptions

### gdata

protected GData gdata

### backgroundColix

protected short backgroundColix

### screenWidth

protected int screenWidth

### screenHeight

protected int screenHeight

### slabZ

protected int slabZ

### depthZ

protected int depthZ

### lightSource

protected V3 lightSource

### fixedRotationCenter

protected P3 fixedRotationCenter

### referenceCenter

protected P3 referenceCenter

### cameraPosition

protected P3 cameraPosition

### cameraDistance

protected float cameraDistance

### apertureAngle

protected float apertureAngle

### scalePixelsPerAngstrom

protected float scalePixelsPerAngstrom

### exportScale

protected float exportScale

### degreesPerRadian

protected static final double degreesPerRadian

See Also:
  - Constant Field Values

### tempP1

protected final P3 tempP1

### tempP2

protected final P3 tempP2

### tempP3

protected final P3 tempP3

### center

protected final P3 center

### tempV1

protected final V3 tempV1

### tempV2

protected final V3 tempV2

### commentChar

protected String commentChar

### lineWidthMad

public short lineWidthMad

## Constructor Details

### ___Exporter

public ___Exporter()

## Method Details

### initOutput

protected boolean initOutput(Viewer vwr, double privateKey, GData g3d, Map<String,Object> params)

### outputHeader

protected abstract void outputHeader()

### output

protected void output(String data)

### getByteCount

protected int getByteCount()

### outputComment

protected void outputComment(String comment)

### setTempVertex

protected static void setTempVertex(T3 pt, T3 offset, T3 ptTemp)

### outputVertices

protected void outputVertices(T3[] vertices, int nVertices, T3 offset)

### outputVertex

protected void outputVertex(T3 pt, T3 offset)

### output

protected abstract void output(T3 pt)

### outputJmolPerspective

protected void outputJmolPerspective()

### getJmolPerspective

protected String getJmolPerspective()

### outputFooter

protected void outputFooter()

### finalizeOutput

protected String finalizeOutput()

### finalizeOutput2

protected String finalizeOutput2()

### getExportDate

protected String getExportDate()

### rgbFractionalFromColix

protected String rgbFractionalFromColix(short colix)

### getTriadC

protected String getTriadC(T3 t)

### getTriad

protected String getTriad(T3 t)

### rgbFractionalFromArgb

protected String rgbFractionalFromArgb(int argb)

### translucencyFractionalFromColix

protected static String translucencyFractionalFromColix(short colix)

### opacityFractionalFromColix

protected static String opacityFractionalFromColix(short colix)

### opacityFractionalFromArgb

protected static String opacityFractionalFromArgb(int argb)

### round

protected static String round(double number)

### round

protected static String round(T3 pt)

### getColorList

protected Lst<Short> getColorList(int i00, short[] colixes, int nVertices, BS bsSelected, Map<Short,Integer> htColixes)
input an array of colixes; returns a Vector for the color list and a HashTable for correlating the colix with a specific color index

Parameters:
  `i00` -
  `colixes` -
  `nVertices` -
  `bsSelected` -
  `htColixes` -
Returns:
  Vector and HashTable

### getConeMesh

protected static MeshSurface getConeMesh(P3 centerBase, M3 matRotateScale, short colix)

### getRotationMatrix

protected M3 getRotationMatrix(P3 pt1, P3 pt2, float radius)

### getRotationMatrix

protected M3 getRotationMatrix(P3 pt1, P3 ptZ, float radius, P3 ptX, P3 ptY)

### outputSurface

protected void outputSurface(T3[] vertices, T3[] normals, short[] colixes, int[][] indices, short[] polygonColixes, int nVertices, int nPolygons, int nTriangles, BS bsPolygons, int faceVertexMax, short colix, Lst<Short> colorList, Map<Short,Integer> htColixes, P3 offset)

Parameters:
  `vertices` - generally unique vertices [0:nVertices)
  `normals` - one per vertex
  `colixes` - one per vertex, or null
  `indices` - one per triangular or quad polygon; may have additional elements beyond vertex indices if faceVertexMax = 3 triangular if faceVertexMax == 3; 3 or 4 if face VertexMax = 4
  `polygonColixes` - face-based colixes
  `nVertices` - vertices[nVertices-1] is last vertex
  `nPolygons` - indices[nPolygons - 1] is last polygon
  `nTriangles` - number of triangular faces required
  `bsPolygons` - number of polygons (triangles or quads)
  `faceVertexMax` - (3) triangles only, indices[][i] may have more elements (4) triangles and quads; indices[][i].length determines
  `colix` - overall (solid) color index
  `colorList` - list of unique color IDs
  `htColixes` - map of color IDs to colorList
  `offset` -

### fillTriangle

protected abstract void fillTriangle(short colix, T3 ptA0, T3 ptB0, T3 ptC0, boolean twoSided)

### fixScreenZ

protected int fixScreenZ(int z)