MPEGs

Also, you must specify a callback function which SMPEG will execute every time it's done drawing. This function can simply call SDL_UpdateRect() or SDL_Flip() to make the changes visible.

void callback(SDL_Surface * surf,
              Sint32 x, Sint32 y,
              Uint32 w, Uint32 h)
{
  SDL_UpdateRect(surf, x, y, w, h);
}
To actually start playing the MPEG, just call SMPEG_play():

SMPEG_play(mpeg);