If a binary mixture, confined by hard walls that prefer one component, is q
uenched from the one-phase region to the two-phase region, phase separation
near the wall is characterized by concentration waves with wavevectors ori
ented perpendicular to the walls. The dynamics of this surface-directed spi
nodal decomposition is investigated by numerical simulations. We consider c
ases with short-range and long-range forces due to the walls, with special
focus upon the interplay of this structure formation with the growth of wet
ting layers. Attention is also paid to the change of the equilibrium phase
diagram of the mixture as a result of confinement in the thin film geometry
, and the consequences that one expects for the dynamical behavior of phase
separation. While most of the numerical results concern systems at critica
l composition, some results on off-critical quenches are also presented.