In an optical system (generally a lens), the entrance pupil is the optical image of the physical aperture, as 'seen' through the optical elements in front of the stop. The corresponding image of the aperture stop as seen through the optical elements behind it is called the exit pupil. The entrance pupil defines the cone of rays that can enter and pass through the optical system. Rays that fall outside of the entrance pupil will not pass through the system.
If there is no lens in front of the aperture (as in a pinhole camera), the entrance pupil's location and size are identical to those of the aperture. Optical elements in front of the aperture will produce a magnified or diminished image of the aperture that is displaced from the aperture location. The entrance pupil is usually a virtual image: it lies behind the first optical surface of the system.