At a lawful traffic stop, if you see evidence that the suspect may be armed and dangerous (such as visible guns, ammo, holsters, gun cases, knives, etc.), you may "pat down" the passenger compartment of the vehicle for weapons. This search is limited to areas, compartments and containers that could conceal a weapon. (Michigan v. Long) This limited weapons search may also be based on reliable information from identified citizens (Adams v. Williams) or from official channels. (U.S. v. Hensley)
Instrumentality
In certain kinds of crimes (hit-run, drive-by shooting, kidnap-rape, and assault/murder by vehicle, for example), the vehicle may be the implement the suspect uses to accomplish the crime. When the vehicle serves as an instrumentality of the crime, it may be seized (assuming no garage entry) and subjected to search and laboratory examination. (California v. Carney-child molestation occurred inside motor home; Cardwell v. Lewis-car used to push the victim's car over a cliff; Cooper v. California-car used to transport narcotics). This exception does not apply if the vehicle was merely used as transportation to and from the crime scene.
Inventory
Strictly speaking, an inventory is not a targeted search for contraband or evidence but is an administrative procedure used to account for personal property found inside a vehicle that is impounded or parked and locked at the scene of arrest. The purposes of the inventory are to safeguard valuables, to remove dangerous instrumentalities, and to protect the agency against false claims of loss. Evidence discovered during the course of an inventory conducted according to standard procedure is admissible under the "plain view" doctrine. (Colorado v. Bertine; Florida v. Wells)