- Home
- Non Sequential Ray Tracing
- Objects
- Creating Polygon Objects in ZEMAX
Assigning Surfaces of the Polygon Object to Different Face Groups
Currently, our defined polygon object has one face group. In other words, any coating and/or scattering properties that we apply to the cube will be placed on all six faces (or surfaces) of the cube. Under the Coat/Scatter tab of the Object Properties dialog, only Face 0 is present, which represents all faces of the cube.
Using the Object Viewer (select the “View Object” button as shown in the dialog above), all of the faces are highlighted as Face 0 is chosen.
We may assign each face to a different face group in the .POB file. Then, we may apply different coating and scattering properties to the various faces of our object.
The name and number of each face is first defined using the C symbol within the definition of our POB object. The face name symbol C requires the following syntax:
C facenumber “any name here”
The facenumber is just an integer used for reference in the rectangle or triangle commands. Face groups can also be given any name which may be helpful in distinguishing which surface(s) the face group corresponds to.
In the current example, let’s edit our polygon object to distinguish the front, back and side faces of the cube (Edit > Edit Object from the NSC Editor). Before the vertex definitions, let’s define 3 unique face groups: one for the front face, one for the back face, and one for the four side faces of the cube. To do so, 3 face commands are required:
Remember that each rectangle definition had a face flag, which corresponds to the face group number previously defined in the POB file. So, we need to modify this flag for each rectangle definition to distinguish which face(s) relate to which face group or face number.
The rectangle describing the front face will be given a face number of 1, since that is the face group describing the “Front Face.” All of the rectangles defining the side faces of the cube will be left with the face number of 0. And lastly, a face group number of 2 will be applied to the back face rectangle:
Once the appropriate flags have been set, Save the file from Notepad and reload the object in ZEMAX (Edit > Reload Object).
Now, there are three distinct face groups:
Thus, any coating and/or scattering property that is chosen for face group 0, Side Faces, will be applied to all of the side faces of the cube (each of the side faces of the POB file defined in notepad pointed to a face number of 0). Similarly, if a different face number is chosen (1, Front Face for example), then a separate set of coating/scattering properties may be applied to the front face of the cube.
The Object Viewer also helps distinguish the surfaces of the object which correspond to the selected face group number. Note that those surfaces which correspond to the selected face group are highlighted in red:

