[FFmpeg-devel] [PATCH] asf-format doesn't work as stream for XBox360

Baptiste Coudurier baptiste.coudurier
Mon Oct 15 11:24:23 CEST 2007


Hi

Patric Stout wrote:
> Vladimir Pantelic schreef:
>> Patric Stout wrote:
>>
>>   
>>> I tried to change all the other fields that showed up on the diff 
>>> between a streamed wmv and a stored wmv, no other field did anything
>>> for the good. This is the only field that makes it to work, or breaks
>>> it. So I am pretty sure this is what the Xbox expects.
>>>     
>> IIRC asf "live" streams have the broadcast flag = 1, seekable = 0 and
>> the *size* is not 0 but the size of the ASF header plus the data header,
>> so everything up to the first packet.
>>
>>   
> You are almost correct ;) The only other allowed number which my XBox
> accepted, besides the very big value, is 50, which is exactly the
> current size after writing the header - asf->data_offset. Basicly, all
> bytes written after the data_offset at that time (so not including the
> ASF header). This is identical with the way the data-chunk-size is later
> on in the code patched up for stored asfs.
> 
> Also, because the url is streamed, the broadcast flag already was set to
> 1 correctly.
> 
> 
> So, in a third attempt, here is the patch setting the data-chunk-size to
> 50 by default. I had a bit of trouble getting a good comment line, feel
> free to edit it to something better ;)
> It has to be noted that this can't really damage anything, as for
> example mplayer ignores this value when reading a stream, and both
> Windows Media Player as XBox360 play this perfectly. And all stored asfs
> get this value overridden anyway.
> 

Did you try not setting seekable flag ?

Specs clearly says:
"Object Size

Specifies the size of the Data Object. Valid values are at least 50
bytes. Note that if the Broadcast Flag bit of the Flags field is set on
the File Properties Object, then the Object Size field may be 0. This is
a special case that indicates the size of the Data Object is unknown. It
is not valid to have a value of 0 for the Object Size field if the
Broadcast Flag is not set."

-- 
Baptiste COUDURIER                              GnuPG Key Id: 0x5C1ABAAA
SMARTJOG S.A.                                    http://www.smartjog.com
Key fingerprint                 8D77134D20CC9220201FC5DB0AC9325C5C1ABAAA
Phone: +33 1 49966312




More information about the ffmpeg-devel mailing list