I find rappers are almost always cast as criminals or thugs and are allowing themselves to be represented in the stereotypicle roles. The movie makers recognise the popularity and influence of hip hop culture on the youth and will milk it for what it's worth. If Eminem is selling however 10s of millions of albums and only half of those people pay to watch a movie in which he stars, you can be certain to make loads of money. I see it as just another attempt to exploit the popularity of hip hop, but it is not only resticted to hip hop, artists of all genres have been known to act in major films.