News:

--

Main Menu

Sony XAVC S audio problem

Started by MikeHarding, January 05, 2017, 01:07:57 AM

Previous topic - Next topic

eumagga0x2a

Quote from: mean on January 11, 2017, 08:35:39 PM
It's not an endianness issue
It's a timestamp issue

The clock is advancing at 2x the normal pace, and it swallows half of the audio track

Thank you very much, confirming also that the playback of the sample from http://avidemux.org/smif/index.php/topic,17148.0.html is fixed now.

Aspirant

Works for me too.

Any chance to use "copy" audio for trimming the video files in near future? Now I'm forced to recode to aac/ac3/mp3?

MikeHarding

Thank you very much for looking at the issue. Unfortunately there is still a timing problem.

Take a look at:

http://bit.ly/2jeNw8P

C0002.mp4 - 133MB

This is a test video shot on XAVC S from my Sony camcorder.

It shows a kitchen timer and me doing a commentary for the duration of the video - VLC plays the video correctly.

Whilst Avidemux now plays the audio correctly it appears to double the length of the video. Like much of my life... it's all a bit confusing :)

20C and humid here in Melbourne and the cicadas are damn noisy.

dosdan

#18
Quote from: MikeHarding on January 13, 2017, 10:11:08 AM

Whilst Avidemux now plays the audio correctly it appears to double the length of the video.


Not on my machine.

MediaInfo shows durations in C0002.MP4 of:

General: 20.160s
Video: 20.160s
Audio: 20.160s

Now I load it into ADM.
ADM's File | Information shows a Video Total Duration of 20.160s  @50fps  and an Audio Total Duration of 20.149s.
The timeline shows a 20.160s duration.
The sound goes all the way to the end and does not sound rushed.
The timer on screen shows 20s at the end of the clip.
My own stopwatch shows that the clip plays for 20s.

Tested with ADM 2.6.18 Win 64 nightly builds 170112 (12 Jan 2017) & 170113. Using Video:Copy, Audio:Copy, MP4v2 Muxer.

I also changed the audio to AAC (FDK) and resaved it as C0002_AAC.MP4.  MediaInfo shows durations in the new clip of:

General: 20.160s
Video: 20.160s
Audio: 20.139s

If I reload this AAC version, ADM's File | Information shows the original video duration, but the audio duration has now dropped to 20.117s.

Dan.

MikeHarding

Hi Dan

I agree with all your numbers from both MediaInfo and Avidemux.

However, on my 32 bit system the video takes a real 36s to complete with the audio stopping at a real 20s. It is quite clear that both the kitchen timer and Avidemux's own running time counter are incrementing at closer to 2s than to 1s.

Producing a copy using your settings above produces the same incorrect result time.

Iam using:
http://www.avidemux.org/nightly/win32/avidemux_2.6.18_r170113_win32.exe
on Windows 7 Pro.



dosdan

#20
Quote from: MikeHarding on January 13, 2017, 08:40:32 PM
However, on my 32 bit system the video takes a real 36s to complete with the audio stopping at a real 20s.
Iam using:
http://www.avidemux.org/nightly/win32/avidemux_2.6.18_r170113_win32.exe
on Windows 7 Pro.


I installed the 32-bit version of 170113 on my Win 10 64-bit system. It did not have this problem.

What video frame rate is ADM's File | Information reporting? Mine shows 50fps. Hence, the 1008 video frames in this clip take 20.16s to play at 50fps. If the video is taking 36s to play in your ADM, that's an effective video playback rate of 28fps.

Dan.

MikeHarding

Hi Dan

My ADM's "File/Information" report shows the same as yours; 20.16s at 50fps.

Further real time measurements using a manual stopwatch and averaged over six runs indicate a video duration of 35.70s which at 21.60s at 50fps does indeed equate to a frame rate of 28?

Just to confirm both VLC and WMP play the video correctly and produce the expected stopwatch time.

eumagga0x2a

Quote from: MikeHarding on January 13, 2017, 10:11:08 AM
Unfortunately there is still a timing problem.

Take a look at:

http://bit.ly/2jeNw8P

C0002.mp4 - 133MB

This is a test video shot on XAVC S from my Sony camcorder.

It shows a kitchen timer and me doing a commentary for the duration of the video - VLC plays the video correctly.

This video is played perfectly in Avidemux built from [mp4/demux] Handle LPCM like PCM on Linux using the VDPAU as decoder and as video output driver.

Which video decoder and output are you using? Could you please compress (with 7zip or zip) and attach the admlog.txt file from Avidemux loading and playing the video?

MikeHarding

The video decoder is; Lavcodec RGB - this seems to be selected automatically and I cannot see a way to change that.
Video output = Copy
Audio output = Copy
Output format = Dummy muxer

Changing the above does not make a difference.

I can paste the log file in-line but it doesn't look very useful:
----
*************************
  Avidemux v (ADM_SUBVERSION)
*************************
http://www.avidemux.org
Code      : Mean, JSC, Gruntster
GFX       : Nestor Di , nestordi@augcyl.org
Design    : Jakub Misak
FreeBSD   : Anish Mistry, amistry@am-productions.biz
Audio     : Mihail Zenkov
MacOsX    : Kuisathaverat
Win32     : Gruntster

Compiler: GCC 4.9.4
Build Target: Microsoft Windows (x86)
Operating System: Microsoft Windows 7 Business (6.1.7600; 32-bit)
Initializing WinSock
WinSock ok
Directory C:\Users\Ford Prefect\AppData\Roaming\avidemux\ exists.Good.
Using C:\Users\Ford Prefect\AppData\Roaming\avidemux\ as base directory for prefs, jobs, etc.
[jobInit] 01:00:05-250 Initializing database (C:\Users\Ford Prefect\AppData\Roaming\avidemux\jobs.sql)
[ADM_jobCheckVersion] 01:00:05-250 Db version 3, our version 3
[ADM_jobCheckVersion] 01:00:05-250 Same version, continuing..
[jobInit] 01:00:05-250 Successfully connected to jobs database..
[createBindAndAccept] 01:00:05-265 Binding on 127.0.0.1:31135192
[createBindAndAccept] 01:00:05-265 Socket bound to port 5592
[jobWindow] 01:00:05-265 Socket bound to 5592
[refreshList] 01:00:05-281 Found 0 jobs
[close] 01:00:08-666 [ADMSocket]Error when socket shutdown  -1 (socket 272)
Normal exit
Cleaning up
[jobShutDown] 01:00:08-666 Shutting down jobs database
[onexit] 01:00:08-666
Goodbye...
----

Aspirant

OK Mike, I can confirm the audio plays faster in your video. Guys hear what he is talking about in his video...

PS interestingely, if u start at e.g. 18s the sound starts there correct...

I also checked my dogs (4k 30fps 100mbits) video and she starts to bark far earlier than the video shows it...

BTW I repeat my question: any chance to get copy audio feature for these files in the near future?

dosdan

#25
Quote from: MikeHarding on January 14, 2017, 01:11:22 AM
The video decoder is; Lavcodec RGB - this seems to be selected automatically and I cannot see a way to change that.

I can't replicate your problem, running the 32-bit version under Win 10 64-bit.

The only way I can get ADM to show "Lavcodec RGB" with that clip is to select "Qt" for the video display. 

Instead, see if you can use my settings which shows "DXVA2 DXVA2". This requires:
1. Video Display set to "DXVA2 (best)"
2. HW Accel | tick box "Decode video using DXVA2 (windows)"

Perhaps DXVA2 isn't available under Win 7?

Dan.




MikeHarding

Hi Dan

It was set to Qt, probably from my previous camera - an option to return all settings to default would be useful.

>1. Video Display set to "DXVA2 (best)"
>2. HW Accel | tick box "Decode video using DXVA2 (windows)"

Done - no difference. I also tried opengl and one other.

Via the Windows control panel I deleted Avidemux and its directory. I then re-installed the latest nightly 32 bit build but it seems Avidenux has some settings stored in the Windows registry or somewhere as it picked up my previous settings.


Jan Gruuthuse

#27
Use file manager and search for config2, config3 and defaultSettings.py. Delete these, if found in a avidemux related folder!
Before doing so, you better you take note of your Avidemux: Edit: Preferences: [Audio], [Display] and [HW Accel]. You have to set your Preferences again.

eumagga0x2a

#28
I can confirm that on my outdated hardware, any decoder other than DXVA2* is uncapable to decode (and thus Avidemux uncapable to play) this 1080p video in real time on Windows 7. The video output driver is not that crucial in this case (choosing DXVA2 is better, of course).

Tested on Windows 7 with 32bit Avidemux cross-compiled from the current trunk for Windows.

*) edit: In other words, the sample plays perfectly in sync in Avidemux 32bit on Windows 7 (64bit) as far as the decoding via DXVA2 is available and enabled. Of course, DXVA2 is supported on Windows 7.


Jan Gruuthuse

Quote from: MikeHarding on January 14, 2017, 01:11:22 AM
>8 >8
Output format = Dummy muxer

Dummy Muxer is not producing any file output! You should use MKV muxer, MP4v2 muxer, ...