The taxation of income for H-1B employees depends on their tax residency: whether they are categorized as Resident Aliens or Non Resident Aliens for tax purposes.
The tax residency can be determined based on the "substantial presence test".
If the substantial presence test indicates that the H-1B visa holder is a resident, then income taxation is like any other US person and may be filed using Form 1040 and the necessary schedules. Otherwise the visa holder must file as a non-resident alien using tax form 1040NR; he or she may claim benefit from Tax Treaties if they exist between the US and the visa holder's country of citizenship.
Persons who are in their first year within the US may choose to be considered a resident for taxation purposes for the entire year, and must pay taxes on their worldwide income for that year. This "First Year Choice" is described in IRS Publication 519 and can only be made once in a person's lifetime.
A spouse, regardless of visa status, must have a valid ITIN or Social Security Number in order to be included on a joint tax return with the H-1B holder.