-
Notifications
You must be signed in to change notification settings - Fork 396
Audio not working #20
Comments
Can you give more details? Which tutorial, using which movie, what platform? |
Tutorial 07 sound is distorted on most video files downloaded from YouTube. The sound plays ok in linux, but in Windows the sound plays distorted. |
Same for me for Tutorial 07 and 04. Sean On Fri, Feb 21, 2014 at 8:56 AM, solarstrings [email protected]:
|
What about tutorials 5 and 6? Do they work? On 22 February 2014 09:19, mrglobal [email protected] wrote:
|
Sorry for delay in reply 04 on windows using MSVC2010 does not work for me (I just used the latest tut05 does not compile Error 5 error C2440: '=' : cannot convert from 'int (__cdecl Line is :
Be that as it may, I don't think 05 would work too (07 does not also). By the way, I use : "#define rint ceil" as there is no rint in MSVC2010 Thanks Sean On Sat, Feb 22, 2014 at 1:46 AM, Michael Penkov [email protected]:
|
Which version of ffmeg are you using?
|
Zeranoe's ffmpeg-20130706-git-63d7684-win32-dev Sean On Thu, Mar 6, 2014 at 6:33 PM, Michael Penkov [email protected]:
|
That looks a bit old. It could be a version compatibility issue. Could you
|
@mpenkov The issue is also happening here. All examples output a high pitched audio.
My ffmpeg:
|
I had been using an earlier version of FFMPEG and kept moving to latest. Sean On Thu, Mar 6, 2014 at 7:56 PM, Michael Penkov [email protected]:
|
@edufelipe Can you provide a sample video that people can use to reproduce this behavior? |
I've debugged it a bit, and it looks like only stereo audio is affected. For some reason avcoded_decode_audio4() puts garbage in 2nd half of the buffer for files with stereo audio. Use this youtube video (download it with youtube-dl) as a sample: https://www.youtube.com/watch?v=FKJXtXvl-HQ |
On 2nd thought it looks like smaller buffer is allocated somewhere in ffmpeg internals for frame->data[0]. Insert a memset(frame.data[0], 0, data_size) after memcpy() in audio_decode_frame() and you'll get a segfault. |
Got it: code can't deal neither with planar audio formats nor with sample format mismatch. |
@chelyaev i got the same high pitch problem. @edufelipe was your problem solved? my output is : Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '/home/hemant/Videos/Burn.mp4': my ffmpeg version is : ffmpeg version 2.6.3 Copyright (c) 2000-2015 the FFmpeg developers |
@Aman5692, have you resolved the audio problem? I've the same problem with the audio. My ffmpeg version is: ffmpeg version N-73365-g72cad80 Copyright (c) 2000-2015 the FFmpeg developers |
@anarsoul Thank you very much. I shall go through yours. I tried @pprahul (his fix) is to change sample format.
It works for mp2 audio even though it is stereo channel. @anarsoul Can you please guide me a bit of how I can fix tutorial03 to work with h264+aac in mp4 container? |
Was able to play a mp4 video with audio whose codecs appear below. Based on http://dranger.com/ffmpeg/ and updates from https://github.com/illuusio/ffmpeg-tutorial, it runs Windows x64, Visual Studio 2015, SDL2, ffmpeg 4.0 and C++. Input #0, mov,mp4,m4a,3gp,3g2,mj2, from ‘crawl.mp4’: |
@MilaCridlig it seems that is expected since you used mono audio. From this comment above it is related to stereo audio |
Used your latest. Video works fine but Audio is scratchy and high pitched. Can you provide any guidance on this ?
Thanks
Sean
The text was updated successfully, but these errors were encountered: