This scenario has an environmental temperature profile based on a surface temperature of 20 C, a dewpoint around 8 C, no capping inversion and a well mixed boundary layer. The black line represents the temperature a parcel lifted from the surface would have. The pollutants are being emitted from a smokestack with a height around 300 m with a temperature around 22 C. I've also assumed no water vapor coming out of the smokestacks. In this case the air from the smokestack (red) is always warmer than the environment and it escapes the boundary layer and rises well above the surface. This pollution is not trapped.
This scenario has a capping inversion between 900 and 850 mb but is otherwise the same as the previous example (same surface temperature and dewpoint). The pollutants have the same properties as the first scenario. In this case, however, due to the temperature inversion there is a height where the environment becomes warmer than the pollutants. If the pollutant ties to rise any higher it will be negatively buoyant and will oscillate around the height of neutral buoyancy (see Brunt–Väisälä frequency). In this case the pollution will be trapped around 860 mb, which is around 1250 m. This isn't too close to the ground but in a well mixed boundary layer this pollution eventually will be mixed throughout the boundary layer. This pollution is trapped.
Both of these scenarios are on warm well-mixed days. Bigger problems tend to happen at night or early morning and in the cold season. In these cases deep inversions that start at the surface tend to form and if smokestacks are not very tall this can cause pollution to be trapped very close to the ground. This kind of temperature structure will cause the pollutant to spread out at low heights. In places where these type of inversions are frequent it is important that smokestacks are built tall enough to emit pollution above the inversion height. The picture below demonstrates how this kind of pollution trapping can look.
Image by JohanTheGhost, wikimedia commons. https://commons.wikimedia.org/wiki/File:SmokeCeilingInLochcarron.jpg