| Author |
Message |
Pooja Mittal
Guest
|
Posted:
Tue Sep 14, 2004 3:31 pm Post subject:
ASF file writer source code |
|
|
I want to write RTP payload data in ASF file format.
Does any one have ASF file writer source code?
|
|
| Back to top |
|
 |
Jeremy Noring
Guest
|
Posted:
Thu Sep 16, 2004 12:30 am Post subject:
Re: ASF file writer source code |
|
|
There is no asf writer source code, nor are you going to find it anywhere.
You have two options if you want files in an ASF container:
1. Pass the samples to an instance of the Windows Media Writer from the
WMFSDK, and have it write stream samples rather than trying to compress the
frames. It will take entire frames, break them down into the asf
packetization scheme, and write you a valid header (assuming you pass it
valid data, that is).
2. Write your own ASF "writer" that takes complete frames and saves them
according to the ASF Specification. You can download the asf spec on
Microsoft's site (forget where, but it's there somewhere).
Personally, the first one is *much* easier since most of the components are
written for you (either in the WMFSDK, or using DirectShow) and the second
one isn't a trivial task. Although the ASF headers are fairly
straightforward, the packetization scheme is fairly incoherent and doesn't
lend itself very well to simplicity.
In my code, I use an RTP library as a network transport, and then reassemble
the RTP packets into full frames. The frames are passed on to either a
video renderer (if viewing is desired) or onto an instance of the WM Writer
to be saved to disk in an ASF Format. I'd check out the WMFSDK
(specifically the parts about saving compressed samples) for more
information on all of this.
--
Where am I going?
And why am I in this handbasket? |
|
| Back to top |
|
 |
Geoff Dunbar [MSFT]
Guest
|
Posted:
Mon Sep 20, 2004 10:52 pm Post subject:
Re: ASF file writer source code |
|
|
Jeremy's points are all correct. A small followup; you can find the ASF
Specification and some other stuff if you go to:
http://www.microsoft.com/asf
Geoff
--
This posting is provided "AS IS" with no warranties, and confers no rights.
"Jeremy Noring" <somewhere@thenet.com> wrote in message
news:uDW9NL2mEHA.3292@TK2MSFTNGP15.phx.gbl...
| Quote: | There is no asf writer source code, nor are you going to find it anywhere.
You have two options if you want files in an ASF container:
1. Pass the samples to an instance of the Windows Media Writer from the
WMFSDK, and have it write stream samples rather than trying to compress
the
frames. It will take entire frames, break them down into the asf
packetization scheme, and write you a valid header (assuming you pass it
valid data, that is).
2. Write your own ASF "writer" that takes complete frames and saves them
according to the ASF Specification. You can download the asf spec on
Microsoft's site (forget where, but it's there somewhere).
Personally, the first one is *much* easier since most of the components
are
written for you (either in the WMFSDK, or using DirectShow) and the second
one isn't a trivial task. Although the ASF headers are fairly
straightforward, the packetization scheme is fairly incoherent and doesn't
lend itself very well to simplicity.
In my code, I use an RTP library as a network transport, and then
reassemble
the RTP packets into full frames. The frames are passed on to either a
video renderer (if viewing is desired) or onto an instance of the WM
Writer
to be saved to disk in an ASF Format. I'd check out the WMFSDK
(specifically the parts about saving compressed samples) for more
information on all of this.
--
Where am I going?
And why am I in this handbasket?
|
|
|
| Back to top |
|
 |
|
|
|
|