.mp4 - out of sync (Zarx264gui)...

User avatar
rei.andrea
Joined: Thu Oct 23, 2003 4:57 am
Location: Italy
Org Profile

.mp4 - out of sync (Zarx264gui)...

Post by rei.andrea » Thu Mar 22, 2007 5:27 am

I have a problem for audio sync when create a .mp4 with "Zarx264gui".
this is the script:

Code: Select all

BePipe.exe --script
"import(^D:\Production_Anime.avs^).Normalize()"
| neroAacEnc_SSE2.exe -br 128000 -ignorelength -if - -of "D:\Production_Anime-temp.m4a"
x264.exe --crf 20 --ref 8 --mixed-refs --bframes 3 --b-pyramid --b-rdo --bime --weightb --direct auto --subme 6 --me hex --progress --no-psnr --no-ssim --output "D:\Production_Anime-temp.264" "D:\Production_Anime.avs"
MP4Box.exe -fps 29,97003 -add "D:\Production_Anime-temp.264" -add "D:\Production_Anime-temp.m4a" -new "D:\Production_Anime.mp4"
The .avs have a lot filter: Deen, fluxsmooth, etcc..

-fps 29,97003 :?:

any idea ??
Image
Image

User avatar
Zarxrax
Joined: Sun Apr 01, 2001 6:37 pm
Contact:
Org Profile

Post by Zarxrax » Thu Mar 22, 2007 9:14 am

What problem do you have exactly with audio sync?

Are you sure your input file is synced? If you encode to some other format instead of x264 is it in sync?

User avatar
rei.andrea
Joined: Thu Oct 23, 2003 4:57 am
Location: Italy
Org Profile

Post by rei.andrea » Thu Mar 22, 2007 9:36 am

Zarxrax wrote:What problem do you have exactly with audio sync?

Are you sure your input file is synced? If you encode to some other format instead of x264 is it in sync?
the audio arrives before the video...

I encode the .avs file with virtualdub in XviD/Mp3 avi file and there is no problem.
the video is in perfect sync..

The video resolution is 848x480
I play .mp4 with last VLC, my PC is 3.4 Ghz (VLC at max 50% CPU time when play the video)

I have another .mp4 file at 848x480 downloaded from the Org and there is no playback problem for that file..
Image
Image

User avatar
rei.andrea
Joined: Thu Oct 23, 2003 4:57 am
Location: Italy
Org Profile

Post by rei.andrea » Thu Mar 22, 2007 10:13 am

I have just encoded the .avs (without filter) with "MeGui.NET" and there is no problem
:shock:

I try to encode this clean .avs file with "Zarx264gui"...
Image
Image

User avatar
Zarxrax
Joined: Sun Apr 01, 2001 6:37 pm
Contact:
Org Profile

Post by Zarxrax » Thu Mar 22, 2007 10:17 am

Ok, I suppose there are a few things that could be wrong, and we should try and narrow down the problem.

1. The framerate of the mp4 is wrong. If you encode an xvid, does it end up at a similar framerate? Are the running times of the 2 files the same?

2. Maybe part of the video isnt being encoded?

3. the speed of the audio is changing, or the audio is being offset. Try extracting the mp3 audio out of your xvid encode, and load that audio into zarx264gui and see if there is any difference.

User avatar
rei.andrea
Joined: Thu Oct 23, 2003 4:57 am
Location: Italy
Org Profile

Post by rei.andrea » Thu Mar 22, 2007 10:36 am

Zarxrax wrote:Ok, I suppose there are a few things that could be wrong, and we should try and narrow down the problem.

1. The framerate of the mp4 is wrong. If you encode an xvid, does it end up at a similar framerate? Are the running times of the 2 files the same?

2. Maybe part of the video isnt being encoded?

3. the speed of the audio is changing, or the audio is being offset. Try extracting the mp3 audio out of your xvid encode, and load that audio into zarx264gui and see if there is any difference.
Using zarx264gui the resulting framerate for .mp4 is 29,0000 :( (audio bitrate is 124, i dont't think is important)

Using Megui.NET the resulting framerate is 29,9700 :D (audio bitrate is 146)

.... :?
Image
Image

User avatar
Zarxrax
Joined: Sun Apr 01, 2001 6:37 pm
Contact:
Org Profile

Post by Zarxrax » Thu Mar 22, 2007 11:16 am

Well that doesn't make much sense, because in the script you posted it shows 29.97003 :?:
How are you checking the framerate of the encoded file?

User avatar
rei.andrea
Joined: Thu Oct 23, 2003 4:57 am
Location: Italy
Org Profile

Post by rei.andrea » Thu Mar 22, 2007 11:21 am

Zarxrax wrote:Well that doesn't make much sense, because in the script you posted it shows 29.97003 :?:
How are you checking the framerate of the encoded file?
I checking the framerate with VLC (view-->stream and media info-->advanced information) and Mplayer output...
Image
Image

User avatar
Zarxrax
Joined: Sun Apr 01, 2001 6:37 pm
Contact:
Org Profile

Post by Zarxrax » Thu Mar 22, 2007 12:36 pm

Try saving the batch file and run that.
What operating system are you using? Is it 32-bit or 64-bit?

User avatar
rei.andrea
Joined: Thu Oct 23, 2003 4:57 am
Location: Italy
Org Profile

Post by rei.andrea » Fri Mar 23, 2007 4:22 am

Zarxrax wrote:Try saving the batch file and run that.
What operating system are you using? Is it 32-bit or 64-bit?
I try tu run the batch file, this is the output ( (...) path of the file)...

Code: Select all

c:\programmi\totalcmd\App\_Video\H264 Tools>"(...)BePipe.exe" --script "import(^(...)Filtered_RGB.avs^)" | neroAacEnc_SSE2.exe -br 128000 -ignorelength
 -if - -of "(...)Filtered_RGB-temp.m4a"
*************************************************************
*                                                           *
*  Nero Digital Audio Reference MPEG-4 & 3GPP Audio Encoder *
*  Copyright (C) 2006 Nero AG                               *
*  All Rights Reserved Worldwide                            *
*                                                           *
*  Package build date: Feb 12 2007                          *
*                                                           *
*  See -help for a complete list of available parameters.   *
*                                                           *
*************************************************************

***************************************
 BePipe by dimzon
***************************************
Script used:
# BEGIN
import("(..)Filtered_RGB.avs")
# END


Scanning for Audio Stream...
Found Audio Stream
Channels=2, BitsPerSample=16, SampleRate=44100Hz
Writing Header...
Writing Data...
Done!                   Processed 73 seconds...


c:\programmi\totalcmd\App\_Video\H264 Tools>"(...)x264.exe" --crf 20 --ref 8 --mixed-refs --bframes 3 --b-pyramid --b-rdo
 --bime --weightb --direct auto --subme 6 --me hex --progress --no-psnr --no-ssi
m --output "(...)Filtered_RGB-temp.264" "(...)Filtered_RGB.avs"

avis [info]: 848x480 @ 29.97 fps (2196 frames)
x264 [info]: using cpu capabilities MMX MMXEXT SSE SSE2
x264 [info]: slice I:62    Avg QP:16.13  size: 1844800:00
x264 [info]: slice P:1323  Avg QP:17.68  size:  7586
x264 [info]: slice B:811   Avg QP:20.08  size:  1521
x264 [info]: mb I  I16..4: 50.3%  0.0% 49.7%
x264 [info]: mb P  I16..4: 25.4%  0.0% 12.2%  P16..4: 29.2%  5.9%  1.9%  0.0%  0
.0%    skip:25.5%
x264 [info]: mb B  I16..4:  0.1%  0.0%  0.2%  B16..8: 14.6%  0.5%  1.1%  direct:
 2.6%  skip:80.9%
x264 [info]: direct mvs  spatial:91.2%  temporal:8.8%
x264 [info]: ref P  78.9%  7.6%  5.8%  1.9%  2.1%  1.6%  1.4%  0.7%
x264 [info]: ref B  53.6% 16.1% 11.9%  7.9%  4.0%  2.2%  3.0%  1.2%
x264 [info]: kb/s:1355.4

encoded 2196 frames, 1.90 fps, 1355.61 kb/s

(....)MP4Box.exe" -fps 29,97003 -add "(...)Filtered_RGB-temp.264" -add "(...)Filtered_RGB-temp.m4a"
 -new "(..)Filtered_RGB.mp4"
AVC-H264 import - frame size 848 x 480 at 29.000 FPS
Import results: 2196 samples - Slices: 62 I 1323 P 811 B - 1 SEI - 29 IDR
        Stream uses B-slice references - max frame delay 2
IsoMedia import - track ID 1 - Audio (SR 44100 - 2 channels)
Saving (...)Filtered_RGB.mp4: 0.
500 secs Interleaving
The problem seems caused for that line

Code: Select all

AVC-H264 import - frame size 848 x 480 at 29.000 FPS 
why 29.000 :?:

PS: I have a windows XP SP2 32 bit
Image
Image

Locked

Return to “Video & Audio Help”