LIMITATIONS OF RAY-CASTING
Ray casting is fast because it utilizes some geometric constraints. In most cases, walls are always at 90 degrees angle with the floor. (Note that we are not talking about the angle between walls and another walls, but the angle between walls and floor.)
Thus, a limitation that almost exists on a ray-casting game is that the viewpoint cannot be rotated along the Z axis (Figure 5). If this is allowed, then walls could be slanted and the benefit of drawing in vertical slices will be lost. This inability to rotate along the Z axis is one of the reason of why ray-casting environment is not regarded as a true three dimensional environment.
RAY-CASTING STEP 1: CREATING A WORLDTo illustrate the process of ray-casting, we will create a maze world that has the following geometric constraints:
2. Walls are made of cubes that have the same size.
3. Floor is always flat.
Such a world is illustrated in Figure 6.
Before continuing, we will define our coordinate system so that there
is no confusion. The coordinate system that we use is illustrated in