To meet the ever increasing global demand for abundant renewable energy, it is crucial for us to design solar cells that are as effective as possible outside laboratories, where the illumination conditions are very far from ideal. From the optical point of view, various methods of light management can be employed to achieve high performance of solar cells, among which the application of antireflective layers is of utmost importance. Plasma-deposited silicon nitride (a-SiNx:H, or briefly, SiNx) is nowadays a very popular antireflection coating for crystalline silicon solar cells. In laboratories and industry, the optimal thickness of the SiNx antireflective layer is determined under perpendicular or constant oblique illumination conditions, using a solar simulator with AM1.5 spectrum. However, when PV modules are integrated into buildings, the solar spectrum, the incident power density and the angle of incidence are constantly changing with the position of the Sun. In our contribution we developed three methods that enable complete optical simulation of arbitrarily oriented PV module exposed to realistic varying illumination conditions. Using the methods, we determined the optimal SiNx layer thicknesses for different types of building integration application of the module (roofing and curtainwalls - vertical glass). The gained optimal values were compared with the optimums gained under perpendicular or constant oblique illumination conditions. The methods were also evaluated and compared with each other.