This function tells D-Type Direct Color Rasterizer which filling rule to respects when rasterizing vectorial shapes: the Nonzero Winding Number rule or the Odd-Even rule. When the Odd-Even rule is selected, the direction of contours used to build vectorial shapes is ignored. When the Nonzero Winding Number rule is selected, the direction of contours is respected. Depending on the construction of the vectorial shape (i.e. whether it has any overlapping contours), these two rules may yield different rasterization results.
The default filling rule is the Nonzero Winding Number rule. This filling rule is more versatile than the Odd-Even rule and, consequently, very suitable for fonts and user defined shapes. In some cases, however, applications may want to call this function to utilize the simpler Odd-Even filling rule.
Parameter | Description |
---|---|
dcr |
Handle of the previously created D-Type Direct Color Rasterizer instance. |
fill_rule |
0 (DV_NZW_OFF) — Use the Odd-Even filling rule |
Both the Nonzero Winding Number rule and the Odd-Even rule and described in general computer graphics literature.