[FFmpeg-trac] #3720(avformat:open): Support decoding of Xunlei XV file

FFmpeg trac at avcodec.org
Tue Apr 28 01:02:38 CEST 2015


#3720: Support decoding of Xunlei XV file
-------------------------------------+------------------------------------
             Reporter:  ElDimentio   |                    Owner:
                 Type:  enhancement  |                   Status:  open
             Priority:  wish         |                Component:  avformat
              Version:  git-master   |               Resolution:
             Keywords:  flv          |               Blocked By:
             Blocking:               |  Reproduced by developer:  1
Analyzed by developer:  0            |
-------------------------------------+------------------------------------

Comment (by al3x):

 Replying to [comment:1 Timothy_Gu]:
 > There is a reverse engineered converter of xv -> flv (ugh) at
 https://gist.github.com/m13253/8298996

 I have checked out this converter and it is a funny one. It descrambles
 the actual FLV header way down in the file and replaces the header with an
 "unknown FLV chunk" (type 255) so it will be properly skipped.

 The file format starts with the magic XLVF, seems to have a 32 bit pointer
 to the actual data at position 8 (e.g. 0x00200000 in the two files). After
 that a URL to the original .flv follows and perhaps some index data.

 At the referenced position, the first 0x400 (1024) bytes have to be
 adjusted:

 {{{
 val = (val + 0x39) & 0xff
 }}}

 or

 {{{
 val = (val - 0xc7) & 0xff
 }}}

 After that, it can be read as an FLV file.

--
Ticket URL: <https://trac.ffmpeg.org/ticket/3720#comment:7>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list