Thanks Andrey. I did try it with ffmpeg, and I received the same results. The [I1] (ashowinfo @...A80) input data is periodically left in the source buffer. [See n=20 below).

>> ./ffmpeg.exe -f lavfi -i "amovie=../../Sessions/scenarios.mpg, aresample=44100, ashowinfo, aconvert=s16:stereo [med]; amovie=../../Sessions/training.avi, ashowinfo, aconvert=s16:stereo [cap]; [med] [cap] amerge, aconvert=s16:stereo" -y "../../NetworkExport/output.avi"

ffmpeg version N-38622-g1eabd71 Copyright (c) 2000-2012 the FFmpeg developers
  built on Mar  7 2012 00:19:36 with gcc 4.6.2
configuration: --disable-static --enable-shared --enable-gpl --enable-version3 --disable-w32threads --enable-runtime-cpudetect --enable-avisynth --enable-bzlib --enable-frei0r --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libfreetype --enable-libgsm --enable-libmp3lame --enable-libopenjpeg --enable-librtmp --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvo-aacenc --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libxavs --enable-libxvid --enable-zlib
  libavutil      51. 42.100 / 51. 42.100
  libavcodec     54. 10.100 / 54. 10.100
  libavformat    54.  2.100 / 54.  2.100
  libavdevice    53.  4.100 / 53.  4.100
  libavfilter     2. 63.100 /  2. 63.100
  libswscale      2.  1.100 /  2.  1.100
  libswresample   0.  7.100 /  0.  7.100
  libpostproc    52.  0.100 / 52.  0.100
[amovie @ 013D7F00] seek_point:0 format_name:(null) file_name:../../Sessions/scenarios.mpg stream_index:1 [amovie @ 01D01280] seek_point:0 format_name:(null) file_name:../../Sessions/training.avi stream_index:1
[amerge @ 01A80940] Inputs overlap: output layout will be meaningless
[aresample @ 013D7DE0] r:48000Hz -> r:44100Hz
[aconvert @ 013E0DA0] fmt:s16 cl:stereo planar:0 -> fmt:s16 cl:stereo planar:0 [aconvert @ 013E32C0] fmt:s16 cl:stereo planar:0 -> fmt:s16 cl:stereo planar:0
[amerge @ 01A80940] in1:stereo + in2:stereo -> out:4.0
[aconvert @ 01D01200] fmt:s16 cl:4.0 planar:0 -> fmt:s16 cl:stereo planar:0
[ashowinfo @ 013E0A80] n:0 pts:17643 pts_time:0.400068 pos:4110 fmt:s16 chlayout:stereo nb_samples:1049 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:0 pts:0 pts_time:0 pos:1362952 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:72FFE706 plane_checksum[72FFE706]
[lavfi @ 013D7220] Estimating duration from bitrate, this may be inaccurate
Input #0, lavfi, from 'amovie=../../Sessions/scenarios.mpg, aresample=44100, ashowinfo, aconvert=s16:stereo [med]; amovie=../../Sessions/training.avi, ashowinfo, aconvert=s16:stereo [cap]; [med] [cap] amerge, aconvert=s16:stereo':
  Duration: N/A, start: 0.400068, bitrate: 1411 kb/s
    Stream #0:0: Audio: pcm_s16le, 44100 Hz, stereo, s16, 1411 kb/s
Output #0, avi, to '../../NetworkExport/output.avi':
  Metadata:
    ISFT            : Lavf54.2.100
    Stream #0:0: Audio: mp3 (U[0][0][0] / 0x0055), 44100 Hz, stereo, s16
Stream mapping:
  Stream #0:0 -> #0:0 (pcm_s16le -> libmp3lame)
Press [q] to stop, [?] for help
[ashowinfo @ 01401F60] n:1 pts:1024 pts_time:0.02322 pos:1367048 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:CB67FD2A plane_checksum[CB67FD2A] [ashowinfo @ 013E0A80] n:1 pts:19627 pts_time:0.445057 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:2 pts:2048 pts_time:0.0464399 pos:1371144 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:93DAEE5A plane_checksum[93DAEE5A] [ashowinfo @ 013E0A80] n:2 pts:21612 pts_time:0.490068 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:3 pts:3072 pts_time:0.0696599 pos:1375240 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:9BDEF3E2 plane_checksum[9BDEF3E2] [ashowinfo @ 013E0A80] n:3 pts:23596 pts_time:0.535057 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:4 pts:4096 pts_time:0.0928798 pos:1379336 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:20030CC6 plane_checksum[20030CC6] [ashowinfo @ 013E0A80] n:4 pts:25581 pts_time:0.580068 pos:251918 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:5 pts:5120 pts_time:0.1161 pos:1383432 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:2042BA79 plane_checksum[2042BA79] [ashowinfo @ 013E0A80] n:5 pts:27565 pts_time:0.625057 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:6 pts:6144 pts_time:0.13932 pos:1387528 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:280F9C2E plane_checksum[280F9C2E] [ashowinfo @ 013E0A80] n:6 pts:29550 pts_time:0.670068 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:7 pts:7168 pts_time:0.16254 pos:1391624 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:BD63982C plane_checksum[BD63982C] [ashowinfo @ 013E0A80] n:7 pts:31534 pts_time:0.715057 pos:260110 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:8 pts:8192 pts_time:0.18576 pos:1395720 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:D3FAB985 plane_checksum[D3FAB985] [ashowinfo @ 013E0A80] n:8 pts:33519 pts_time:0.760068 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:9 pts:9216 pts_time:0.20898 pos:1399816 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:EAECE1FC plane_checksum[EAECE1FC] [ashowinfo @ 013E0A80] n:9 pts:35503 pts_time:0.805057 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:10 pts:10240 pts_time:0.2322 pos:1403912 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:1B80E183 plane_checksum[1B80E183] [ashowinfo @ 013E0A80] n:10 pts:37488 pts_time:0.850068 pos:331790 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:11 pts:11264 pts_time:0.25542 pos:1408008 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:D178E6F8 plane_checksum[D178E6F8] [ashowinfo @ 013E0A80] n:11 pts:39472 pts_time:0.895057 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:12 pts:12288 pts_time:0.278639 pos:1412104 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:57C4CE5A plane_checksum[57C4CE5A] [ashowinfo @ 013E0A80] n:12 pts:41457 pts_time:0.940068 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:13 pts:13312 pts_time:0.301859 pos:1416200 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:B87EC992 plane_checksum[B87EC992] [ashowinfo @ 013E0A80] n:13 pts:43441 pts_time:0.985057 pos:403470 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:14 pts:14336 pts_time:0.325079 pos:1420296 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:70FCD358 plane_checksum[70FCD358] [ashowinfo @ 013E0A80] n:14 pts:45426 pts_time:1.03007 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:15 pts:15360 pts_time:0.348299 pos:1424392 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:D5A92B09 plane_checksum[D5A92B09] [ashowinfo @ 013E0A80] n:15 pts:47410 pts_time:1.07506 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:16 pts:16384 pts_time:0.371519 pos:1428488 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:8A1AA587 plane_checksum[8A1AA587] [ashowinfo @ 013E0A80] n:16 pts:49395 pts_time:1.12007 pos:479246 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:17 pts:17408 pts_time:0.394739 pos:1432584 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:4E684C76 plane_checksum[4E684C76] [ashowinfo @ 013E0A80] n:17 pts:51379 pts_time:1.16506 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:18 pts:18432 pts_time:0.417959 pos:1436680 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:FF14DA89 plane_checksum[FF14DA89] [ashowinfo @ 013E0A80] n:18 pts:53364 pts_time:1.21007 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:19 pts:19456 pts_time:0.441179 pos:1440776 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:CFB99FDB plane_checksum[CFB99FDB] [ashowinfo @ 013E0A80] n:19 pts:55348 pts_time:1.25506 pos:546830 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:20 pts:20480 pts_time:0.464399 pos:1444872 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:AB467A3B plane_checksum[AB467A3B] [ashowinfo @ 013E0A80] n:20 pts:57333 pts_time:1.30007 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:21 pts:21504 pts_time:0.487619 pos:1448968 fmt:s16 chlayout:stereo nb_samples:546 rate:44100 planar:0 checksum:E22FBFC2 plane_checksum[E22FBFC2] [ashowinfo @ 01401F60] n:22 pts:22050 pts_time:0.5 pos:3763208 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:1277853A plane_checksum[1277853A] [ashowinfo @ 013E0A80] n:21 pts:59317 pts_time:1.34506 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:23 pts:23074 pts_time:0.52322 pos:3767304 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:9564318C plane_checksum[9564318C] [ashowinfo @ 013E0A80] n:22 pts:61302 pts_time:1.39007 pos:614414 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:24 pts:24098 pts_time:0.54644 pos:3771400 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:6CE0F731 plane_checksum[6CE0F731] [ashowinfo @ 013E0A80] n:23 pts:63286 pts_time:1.43506 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:25 pts:25122 pts_time:0.56966 pos:3775496 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:4FBB7809 plane_checksum[4FBB7809] [ashowinfo @ 013E0A80] n:24 pts:65271 pts_time:1.48007 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:26 pts:26146 pts_time:0.59288 pos:3779592 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:28EA635E plane_checksum[28EA635E] [ashowinfo @ 013E0A80] n:25 pts:67255 pts_time:1.52506 pos:681998 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:27 pts:27170 pts_time:0.6161 pos:3783688 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:DCF2DB9A plane_checksum[DCF2DB9A] [ashowinfo @ 013E0A80] n:26 pts:69240 pts_time:1.57007 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:28 pts:28194 pts_time:0.63932 pos:3787784 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:DD3FD822 plane_checksum[DD3FD822] [ashowinfo @ 013E0A80] n:27 pts:71224 pts_time:1.61506 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:29 pts:29218 pts_time:0.66254 pos:3791880 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:CAACC73A plane_checksum[CAACC73A] [ashowinfo @ 013E0A80] n:28 pts:73209 pts_time:1.66007 pos:753678 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000] [ashowinfo @ 01401F60] n:30 pts:30242 pts_time:0.68576 pos:3795976 fmt:s16 chlayout:stereo nb_samples:1024 rate:44100 planar:0 checksum:643EB023 plane_checksum[643EB023] [ashowinfo @ 013E0A80] n:29 pts:75193 pts_time:1.70506 pos:-1 fmt:s16 chlayout:stereo nb_samples:1058 rate:44100 planar:0 checksum:00000000 plane_checksum[00000000]

On 4/6/2012 1:39 AM, Andrey Utkin wrote:
2012/4/5 Bryan Stewart<[email protected]>:
I am trying to merge two audio streams with different sample rates in to a
single s16 stereo stream:

  -lavfi "[I1] aresample=44100, ashowinfo, aconvert=s16:stereo [L1];
          [I2] aresample=44100, ashowinfo, aconvert=s16:stereo [L2];
          [L1] [l2] amerge, aconvert=s16:stereo [out]"

Did you try it with ffmpeg utility? Just to check that it's not ffmpeg
internal problem.


--
#-----------------------------------------------------------------#
#  Bryan C. Stewart                   Email: [email protected] #
#                                     Web:   www.ais-sim.com      #
#  Advanced Interactive Systems, Inc. Phone: (831)655-0440        #
#  8 Harris Ct, Suite B5,             Fax:   (831)655-0885        #
#  Monterey, CA 93940                                             #
#-----------------------------------------------------------------#

*
*
CONFIDENTIALITY NOTICE
----------------------
This message, together with any attachments, may be legally privileged and is confidential information intended only for the use of the individual or entity to which it is addressed. It is exempt from disclosure under applicable law including court orders. If you are not the intended recipient, you are hereby notified that any use, dissemination, distribution or copy of this message, or any attachment, is strictly prohibited. If you have received this message in error, please notify the original sender and delete this message, along with
any attachments, from your computer.
In addition, Data contained in this email may be subject to the International Traffic in Arms Regulation (ITAR) or the Export Administration Regulation (EAR) of 1979. Regulated data may not be exported, released, or disclosed to foreign nationals inside or outside the United States without obtaining the prior written approval of Advanced Interactive Systems, Inc. and licenses as required by the U.S. Department of State.
_______________________________________________
Libav-user mailing list
[email protected]
http://ffmpeg.org/mailman/listinfo/libav-user

Reply via email to