Depends on the file type. Normally, a video file has several formats:
- A video format, like divx or xvid or h264, for pretty images.
- An audio format like mp3 or ogg, for sound.
- Sometimes, a subtitle format like ssa or vobsub.
- A container format like avi or mkv that contains all the audio and video and subtitle streams.
What you want to do is get the audio stream from the file. How you do this depends on the container format.