problems w/ asfrecorder

Scott I. Remick scott at
Sun Mar 7 22:40:44 PST 2004

I'm trying to use net/asfrecorder to capture a stream, and am having some

My adventure started here:

My goal is the "Careful" video. If you click on it, you get a popup box
that would normally play the video via a plug-in. The box uses Javascript
to disable the right-click context menus, so I had to turn that off to get
the ASX URL from the page source:

If you look at that ASX file, you find what should be the main ASF file
between two promo clips:

ASFrecorder would choke on that though with "unknown content-type" because
it was handing out the MIME type. So I patched
asfrecorder.c to add that MIME type to the list of "prerecorded content"
MIME types. asfrecorder got a bit further, then complained again about
application/x-mms-framed so I added that to the list too. The relevant
part of the source now looked like:

                /* Determine whether this is live content or not */
                if ((!stricmp(ContentType, "application/octet-stream")) ||
                    (!stricmp(ContentType, "application/")) ||
                    (!stricmp(ContentType, "application/x-mms-framed")) )
                    if (strstr(Features, "broadcast"))
                        hi->contenttype = live_content;                     
                        hi->contenttype = prerecorded_content;

At that point I could save the stream and got a 28MB file. However mplayer
doesn't detect the video stream:

ASF file format detected.
============ ASF Stream group == START ===
 object size = 74
 stream count=[0x8][8]
   stream id=[0x1][1]
   max bitrate=[0xcdb7][52663]
   stream id=[0x2][2]
   max bitrate=[0xd2b8][53944]
   stream id=[0x3][3]
   max bitrate=[0xcf25][53029]
   stream id=[0x4][4]
   max bitrate=[0x1ba16][113174]
   stream id=[0x5][5]
   max bitrate=[0xcf25][53029]
   stream id=[0x6][6]
   max bitrate=[0x400d0][262352]
   stream id=[0x7][7]
   max bitrate=[0xcf25][53029]
   stream id=[0x8][8]
   max bitrate=[0x6ff75][458613]
============ ASF Stream group == END ===
ASF: No video stream found.

The audio plays fine.

I feel I've gotten so close... what step(s) have I missed? Thanks

More information about the freebsd-multimedia mailing list