mixed aviinfo($filename)

array returned:

   int v_scale		I can't remember exactly what this is.  The number of frames per avi block or something.  It's mostly useless unless implementing a video codec/player.   
   int v_rate		Related to v_scale somehow.  The two together determine the framerate.  It's probably safe to ignore this, but it's provided for completeness.
   float v_fps		Video framerate in frames per second
   int v_frames		The number of frames in the clip
   int duration		Rounded length of the clip, in seconds
   int v_width		Width of the clip, in pixels
   int v_height		Height of the clip, in pixels
   string v_codec	Full video codec name
   string v_4cc		MS 4CC code for this video format (can be used if the codec name isn't in the library in this function).
   string a_codec	Full audio codec name
   int a_format		Audio codec index number.  Similar to 4CC, but numeric.
   int a_chans		Number of audio channels
   string a_mode	Audio mode (Mono, Stereo, or Nch where N is the equal to a_chans)
   float a_brate	Audio bitrate.  Average, rounded to 1 decimal place.
   float a_srate	Audio sample rate.  Absolute, rounded to 1 decimal place.
   float v_ar		Video aspect ratio.  This is the width/height calculation, popularly referred to as 'apsect ratio'.  The value returned is the left side of the 2.35:1 style of representation.  For display, add :1 to this.

I lost most of the documentation for this in a disk crash, so all I'm going to provide is the basics:

This function gathers basic information from an AVI format file.  It's poorly coded and does no real error checking, so be careful that the file exists and is readable before calling the function.  It should return NULL on failure (though it would have to read the entire file to do so, so it would be slow), and will return an associative array on success.  Unknown values will be NULL, 0 or "Unknown" (more code fixing is needed...).

I provide no guarantees.  Feel free to contact me with questions, though you probably know about as much as I do about this code at this point.  At some point in time I may feel like going through and cleaning this up, but as I don't use it, it's rather unlikely.