Possible issue with asf muxer

classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|

Possible issue with asf muxer

Massimo Battistel
Hello,
you can download sample from here:

http://www.datafilehost.com/d/c466f4ad

This file plays fine with ffplay.

Now I try to convert it to raw asf:

ffmpeg -i intermission.wmv  -vcodec rawvideo -pix_fmt yuv420p -acodec
pcm_s16le -ac 2 -ar 48000 -f  asf intermission2.asf

ffmpeg version N-61570-gaa86ccc Copyright (c) 2000-2014 the FFmpeg
developers
  built on Mar 17 2014 22:04:13 with gcc 4.8.2 (GCC)
  configuration: --disable-static --enable-shared --enable-gpl
--enable-version3 --disable-w32threads --enable-avisynth --enable-bzlib
--enable-fontconfig --enable-frei0r --enable-gnutls --enable-iconv
--enable-libass --enable-libbluray --enable-libcaca --enable-libfreetype
--enable-libgsm --enable-libilbc --enable-libmodplug --enable-libmp3lame
--enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg
--enable-libopus --enable-librtmp --enable-libschroedinger --enable-libsoxr
--enable-libspeex --enable-libtheora --enable-libtwolame
--enable-libvidstab --enable-libvo-aacenc --enable-libvo-amrwbenc
--enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libx264
--enable-libx265 --enable-libxavs --enable-libxvid --enable-zlib
  libavutil      52. 67.100 / 52. 67.100
  libavcodec     55. 52.102 / 55. 52.102
  libavformat    55. 34.101 / 55. 34.101
  libavdevice    55. 11.100 / 55. 11.100
  libavfilter     4.  3.100 /  4.  3.100
  libswscale      2.  5.101 /  2.  5.101
  libswresample   0. 18.100 /  0. 18.100
  libpostproc    52.  3.100 / 52.  3.100
Guessed Channel Layout for  Input Stream #0.0 : stereo
Input #0, asf, from 'D:\Video\media\intermission.wmv':
  Metadata:
    WMFSDKNeeded    : 0.0.0.0000
    DeviceConformanceTemplate: MP@LL
    WM/WMADRCPeakReference: 32767
    WM/WMADRCAverageReference: 6698
    WMFSDKVersion   : 9.00.00.2925
    IsVBR           : 0
  Duration: 00:00:40.00, start: 0.000000, bitrate: 229 kb/s
    Stream #0:0(eng): Audio: wmav2 (a[1][0][0] / 0x0161), 48000 Hz, stereo,
fltp, 64 kb/s
    Stream #0:1(eng): Video: wmv3 (Main) (WMV3 / 0x33564D57), yuv420p,
320x240, 300 kb/s, 30 tbr, 1k tbn, 1k tbc
Output #0, asf, to 'intermission2.asf':
  Metadata:
    WMFSDKNeeded    : 0.0.0.0000
    DeviceConformanceTemplate: MP@LL
    WM/WMADRCPeakReference: 32767
    WM/WMADRCAverageReference: 6698
    WMFSDKVersion   : 9.00.00.2925
    IsVBR           : 0
    WM/EncodingSettings: Lavf55.34.101
    Stream #0:0(eng): Video: rawvideo (I420 / 0x30323449), yuv420p,
320x240, q=2-31, 200 kb/s, 1k tbn, 30 tbc
    Stream #0:1(eng): Audio: pcm_s16le ([1][0][0][0] / 0x0001), 48000 Hz,
stereo, s16, 1536 kb/s
Stream mapping:
  Stream #0:1 -> #0:0 (wmv3 -> rawvideo)
  Stream #0:0 -> #0:1 (wmav2 -> pcm_s16le)
Press [q] to stop, [?] for help
frame= 1008 fps=0.0 q=0.0 size=   83504kB time=00:00:33.60
bitrate=20359.1kbits/s dup=1 drop=0
[wmav2 @ 0240e940] nb_frames is 0
Error while decoding stream #0:0: Invalid data found when processing input
frame= 1200 fps=0.0 q=0.0 Lsize=  144086kB time=00:00:40.01
bitrate=29496.2kbits/s dup=1 drop=0
video:135000kB audio:7512kB subtitle:0 data:0 global headers:0kB muxing
overhead 1.104240%


The output file has lots of issue with ffplay: a/v sync, bad audio, ...



Now I try to convert it to raw avi (only muxer is changed from previous cmd
line):

ffmpeg -i intermission.wmv  -vcodec rawvideo -pix_fmt yuv420p -acodec
pcm_s16le -ac 2 -ar 48000 -f  avi intermission2.avi

ffmpeg version N-61570-gaa86ccc Copyright (c) 2000-2014 the FFmpeg
developers
  built on Mar 17 2014 22:04:13 with gcc 4.8.2 (GCC)
  configuration: --disable-static --enable-shared --enable-gpl
--enable-version3 --disable-w32threads --enable-avisynth --enable-bzlib
--enable-fontconfig --enable-frei0r --enable-gnutls --enable-iconv
--enable-libass --enable-libbluray --enable-libcaca --enable-libfreetype
--enable-libgsm --enable-libilbc --enable-libmodplug --enable-libmp3lame
--enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg
--enable-libopus --enable-librtmp --enable-libschroedinger --enable-libsoxr
--enable-libspeex --enable-libtheora --enable-libtwolame
--enable-libvidstab --enable-libvo-aacenc --enable-libvo-amrwbenc
--enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libx264
--enable-libx265 --enable-libxavs --enable-libxvid --enable-zlib
  libavutil      52. 67.100 / 52. 67.100
  libavcodec     55. 52.102 / 55. 52.102
  libavformat    55. 34.101 / 55. 34.101
  libavdevice    55. 11.100 / 55. 11.100
  libavfilter     4.  3.100 /  4.  3.100
  libswscale      2.  5.101 /  2.  5.101
  libswresample   0. 18.100 /  0. 18.100
  libpostproc    52.  3.100 / 52.  3.100
Guessed Channel Layout for  Input Stream #0.0 : stereo
Input #0, asf, from 'D:\Video\media\intermission.wmv':
  Metadata:
    WMFSDKNeeded    : 0.0.0.0000
    DeviceConformanceTemplate: MP@LL
    WM/WMADRCPeakReference: 32767
    WM/WMADRCAverageReference: 6698
    WMFSDKVersion   : 9.00.00.2925
    IsVBR           : 0
  Duration: 00:00:40.00, start: 0.000000, bitrate: 229 kb/s
    Stream #0:0(eng): Audio: wmav2 (a[1][0][0] / 0x0161), 48000 Hz, stereo,
fltp, 64 kb/s
    Stream #0:1(eng): Video: wmv3 (Main) (WMV3 / 0x33564D57), yuv420p,
320x240, 300 kb/s, 30 tbr, 1k tbn, 1k tbc
Output #0, avi, to 'intermission2.avi':
  Metadata:
    WMFSDKNeeded    : 0.0.0.0000
    DeviceConformanceTemplate: MP@LL
    WM/WMADRCPeakReference: 32767
    WM/WMADRCAverageReference: 6698
    WMFSDKVersion   : 9.00.00.2925
    IsVBR           : 0
    ISFT            : Lavf55.34.101
    Stream #0:0(eng): Video: rawvideo (I420 / 0x30323449), yuv420p,
320x240, q=2-31, 200 kb/s, 30 tbn, 30 tbc
    Stream #0:1(eng): Audio: pcm_s16le ([1][0][0][0] / 0x0001), 48000 Hz,
stereo, s16, 1536 kb/s
Stream mapping:
  Stream #0:1 -> #0:0 (wmv3 -> rawvideo)
  Stream #0:0 -> #0:1 (wmav2 -> pcm_s16le)
Press [q] to stop, [?] for help
frame= 1189 fps=0.0 q=0.0 size=  103870kB time=00:00:39.66
bitrate=21451.4kbits/s
[wmav2 @ 0252e940] nb_frames is 0
Error while decoding stream #0:0: Invalid data found when processing input
frame= 1199 fps=0.0 q=0.0 Lsize=  142443kB time=00:00:40.01
bitrate=29160.2kbits/s
video:134888kB audio:7512kB subtitle:0 data:0 global headers:0kB muxing
overhead 0.030529%


Everything is fine.

I suppose something is wrong with asf muxer.



Thanks,
MB
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: Possible issue with asf muxer

Carl Eugen Hoyos
Massimo Battistel <battistel <at> gmail.com> writes:

> ffmpeg -i intermission.wmv  -vcodec rawvideo -pix_fmt yuv420p
> -acodec pcm_s16le -ac 2 -ar 48000 -f  asf intermission2.asf

Do you have any indication that rawvideo and / or
rawaudio are supported in asf?
Do you have a sample or did you test the output
with WMP?

Carl Eugen

_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: Possible issue with asf muxer

Massimo Battistel
>
>
> Do you have any indication that rawvideo and / or
> rawaudio are supported in asf?
>

Don't know if there is official doc about this, but I often do that with no
problems. Only the file I provided gives me issues.


> Do you have a sample or did you test the output
> with WMP?
>

The sample can be downloaded from here:
http://www.datafilehost.com/d/c466f4ad

Running the script I provided, you can generate the output file.

I've tested the output with ffplay and vlc 2.1.2. Both have problems with
asf and both are fine with avi, but with this sample only.


Another interesting information:
If you just remux to asf the output generated by script, you fix the issue:

ffmpeg -i intermission2.asf -c copy intermission3.asf

Output file (intermission3.asf) plays fine both on ffplay and vlc 2.1.2.


thanks,
MB
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: Possible issue with asf muxer

Carl Eugen Hoyos
In reply to this post by Massimo Battistel
Massimo Battistel <battistel <at> gmail.com> writes:

> ffmpeg -i intermission.wmv  -vcodec rawvideo -pix_fmt yuv420p
> -acodec pcm_s16le -ac 2 -ar 48000 -f  asf intermission2.asf

I tested this command line (without -ac 2 -ar 48000 -f asf)
with your sample and the output file plays fine with WMP
(and vlc) afaict.

How does converting the output file with ffmpeg work?

Carl Eugen

_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: Possible issue with asf muxer

Massimo Battistel
>
> I tested this command line (without -ac 2 -ar 48000 -f asf)
> with your sample and the output file plays fine with WMP
> (and vlc) afaict.
>

I've tested the same command line (the one without -ac 2 -ar 48000 -f asf)
with latest ffmpeg Zeranoe builds and vlc and I still see the issue (both
ffplay and vlc 2.1.3, wmp is fine).
Video freezes for the first 8 seconds.
My platform is Windows 7 64bit.


How does converting the output file with ffmpeg work?


I don't understand. Can you elaborate?


Thanks,
MB
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: Possible issue with asf muxer

Massimo Battistel
I'd like to know if you've been able to reproduce the issue.

Additional information: I've seen that intermission2.asf has a very bad
interleaving, something like:

(V=video packet, A=audio packet)
VVVVVVVVVVVVVVVVVVVVVVVV...AAAAAAAAAAAAAAAAAAAAAAA...and so on for more
than half of file. Then in the end it turn into normality VAVAVAVA....

Remuxing the file into asf again reorders packets correctly.
(VAVAVAVAV...till the end).

ffmpeg -i intermission2.asf -c copy intermission3.asf


let me know,
thanks,
MB



2014-04-03 18:34 GMT+02:00 Massimo Battistel <[hidden email]>:

> I tested this command line (without -ac 2 -ar 48000 -f asf)
>> with your sample and the output file plays fine with WMP
>> (and vlc) afaict.
>>
>
> I've tested the same command line (the one without -ac 2 -ar 48000 -f asf)
> with latest ffmpeg Zeranoe builds and vlc and I still see the issue (both
> ffplay and vlc 2.1.3, wmp is fine).
> Video freezes for the first 8 seconds.
> My platform is Windows 7 64bit.
>
>
> How does converting the output file with ffmpeg work?
>
>
> I don't understand. Can you elaborate?
>
>
> Thanks,
> MB
>



--
Massimo Battistel.
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: Possible issue with asf muxer

Carl Eugen Hoyos
Massimo Battistel <battistel <at> gmail.com> writes:

> I'd like to know if you've been able to reproduce the issue.

I opened ticket #3555
Thank you for being insistent, I originally misunderstood
the issue!

For future reports: Please remember that top-posting is
strongly discouraged here and please fix your quoting.

Carl Eugen

_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: Possible issue with asf muxer

Carl Eugen Hoyos
In reply to this post by Massimo Battistel
Massimo Battistel <battistel <at> gmail.com> writes:

> The output file has lots of issue with ffplay:
> a/v sync, bad audio, ...

This should be fixed in current FFmpeg git head,
thank you for the report!

Carl Eugen

_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user
Reply | Threaded
Open this post in threaded view
|

Re: Possible issue with asf muxer

Massimo Battistel
>
> This should be fixed in current FFmpeg git head,
> thank you for the report!
>
>
thanks a lot!
Now It works much better.

MB
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user