SANTA CLARA, Calif. - Defensive end Marques Douglas agreed to a three-year contract with the San Francisco 49ers on Thursday, leaving the Baltimore Ravens after six seasons.

Douglas has spent all but a few months of his NFL career with the Ravens, where new 49ers coach Mike Nolan was his defensive coordinator for the last three years. He started 31 games for Baltimore over the past two seasons, getting 5½ sacks and 48 tackles last year.

Douglas should get a regular role on the 49ers' defensive line along with ends Andre Carter and John Engelberger. Stalwart defensive tackle Bryant Young also is expected to play end next season when the 49ers go to a 3-4 defense.