Then read your employment contract that you may have signed. It often contains legal terms like "work for hire", etc. that have explicit definitions. Make sure you read your contract after understanding these definitions.
The portions that are not easily enforceable include the following:
You contract may state that the agreement will continue to apply up to six months or one year after you terminate your employment. This provision is generally included by employers so as to prevent employees from coming up with patentable ideas or creating copyrightable works (like software) and "then" terminating their employment pretending none of that happened. Under that scenario, the IP you generate does indeed belong to the company.
On the other hand, if you start your work and develop IP strictly after terminating your employment, court will not honor "non-compete" clauses. This are designed to protect employees who are most likely to continue working in areas of their expertise, which is likely the same as what they were working on while they were employed.
Reason for edit: Fixed some typos.
Under that scenario, the IP you generate does indeed belong to the company.
Only if the "IP" falls under very specific guidelines. Writing an MMORPG at home while working at Zynga? No, Zynga can't claim squat. You don't need to wait to terminate employment in order to work on projects at home.
California is one state where their policy is NOT enforceable as far as their ownership. They may fire you over it but they won't own your work.