RwSetPolygonOpacity(RwPolygon3d *polygon, RwReal opacity);
Sets the opacity of the polygons material.
polygon Pointer to the polygon.
opacity Opacity in the range CREAL(0.0) to CREAL(1.0).
The argument polygon if successful, and NULL otherwise.
An opacity of CREAL(1.0) yields an entirely opaque polygon. An opacity of CREAL(0.0) yields an entirely transparent polygon.
RenderWare optimizes memory usage by sharing materials across multiple polygons. Setting a polygon material property with this function will cause the polygon to have its own copy of the material, not shared by any other polygons. Unless this is the desired effect, it is more memory efficient to use the corresponding material function RwSetMaterialOpacity() to change the underlying polygon material. This change will then be propagated to all polygons which use the material. The following line of code demonstrates how this is achieved: