Playing video in OpenGL

I’ve made an Intro for a game i’m writing and it’s in the avi- format. How can I play the file using API- code?