Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > General > Audio encoding

Reply
 
Thread Tools Search this Thread Display Modes
Old 18th July 2006, 11:27   #341  |  Link
Robot
Registered User
 
Join Date: Jun 2006
Posts: 19
I re-installed Avisynth and restarted. I get the same error. I exported the script.

Quote:
########################################
#Created by BeHappy v0.1.5.526
#Creation timestamp: 7/18/2006 6:25:24 AM
########################################
#Source FileName:C:\Documents and Settings\J\Desktop\NTS\johnlennon\theusvsjohnlennon_h720p_track2.aac
#Target FileName:C:\Documents and Settings\J\Desktop\NTS\johnlennon\theusvsjohnlennon_h720p_track2.ac3
########################################

########################################
# [Source: AviSynth]
########################################
Import("C:\Documents and Settings\J\Desktop\NTS\johnlennon\theusvsjohnlennon_h720p_track2.aac")

EnsureVBRMP3Sync() # Some black magic to avoid desync

########################################
# [Encoder: ffmpeg AC3 @ 448 kbps]
########################################
6==Audiochannels(last)?GetChannel(last,1,3,2,5,6,4):last
Thanks
Robot is offline   Reply With Quote
Old 18th July 2006, 15:03   #342  |  Link
dimzon
BeHappy/MeGUI developer
 
dimzon's Avatar
 
Join Date: Oct 2003
Location: Moscow, Russia
Posts: 1,727
Robot
Wich OS did You use?
Are you able to play obtained script via mplayerc?
dimzon is offline   Reply With Quote
Old 18th July 2006, 19:38   #343  |  Link
alwa
Registered User
 
Join Date: May 2006
Posts: 29
Quote:
[Source: AviSynth]
How is that possible? It's an aac-file, not an avs-file...
Try to use DierectShowSource or BassAudio, then it should work properly.
alwa is offline   Reply With Quote
Old 18th July 2006, 20:54   #344  |  Link
Robot
Registered User
 
Join Date: Jun 2006
Posts: 19
Quote:
Originally Posted by dimzon
Robot
Wich OS did You use?
Are you able to play obtained script via mplayerc?
I use Windows XP

and I have no idea what the next thing means.
I'm a novice.
Robot is offline   Reply With Quote
Old 19th July 2006, 00:13   #345  |  Link
tebasuna51
Moderator
 
tebasuna51's Avatar
 
Join Date: Feb 2005
Location: Spain
Posts: 6,915
In BeHappy [1] Source you must select DirectShowSource instead AviSynth after the input file.
tebasuna51 is offline   Reply With Quote
Old 19th July 2006, 01:00   #346  |  Link
dimzon
BeHappy/MeGUI developer
 
dimzon's Avatar
 
Join Date: Oct 2003
Location: Moscow, Russia
Posts: 1,727
Quote:
Originally Posted by tebasuna51
In BeHappy [1] Source you must select DirectShowSource instead AviSynth after the input file.
And don't forget about AAC splitter
dimzon is offline   Reply With Quote
Old 19th July 2006, 01:05   #347  |  Link
dimzon
BeHappy/MeGUI developer
 
dimzon's Avatar
 
Join Date: Oct 2003
Location: Moscow, Russia
Posts: 1,727

Aften support (not tested yet, please report)
dimzon is offline   Reply With Quote
Old 19th July 2006, 06:02   #348  |  Link
Robot
Registered User
 
Join Date: Jun 2006
Posts: 19
I'm lost. No matter what I do, I get this error:

Quote:
Starting job theusvsjohnlennon_h720p_track2.aac->theusvsjohnlennon_h720p_track2.ac3
Error: BeHappy.AviSynthException: Required Avisynth 2.5
at BeHappy.AviSynthClip..ctor(String func, String arg, AviSynthColorspace forceColorspace, AviSynthScriptEnvironment env)
at BeHappy.Encoder.encode()
Robot is offline   Reply With Quote
Old 19th July 2006, 06:07   #349  |  Link
nfm
MAGIK
 
Join Date: Feb 2006
Posts: 54
Can somebody compile this app into one package with all plugins etc. I don't even know where to begin, everything is all over the place.
nfm is offline   Reply With Quote
Old 19th July 2006, 06:54   #350  |  Link
thuongshoo
Registered User
 
Join Date: Mar 2006
Posts: 197
@nfm : I often install K-lite codec pack , and plugin which is need for Behappy is at gotdotnet
thuongshoo is offline   Reply With Quote
Old 19th July 2006, 11:03   #351  |  Link
tebasuna51
Moderator
 
tebasuna51's Avatar
 
Join Date: Feb 2005
Location: Spain
Posts: 6,915
Quote:
Originally Posted by dimzon
Aften support (not tested yet, please report)
Code:
Starting job Bueno.wav->Bueno_t2.ac3
Found Audio Stream
Channels=6, BitsPerSample=16, SampleRate=48000Hz
Aften.exe -v 0 -b 448 -m 1 -s 0 -cmix 1 -smix 2 -dsur 0 -dnorm 26 - "D:\Internet\AudioTest\aften\Bueno_t2.ac3"
Writing RIFF header to encoder's StdIn
Writing PCM data to encoder's StdIn
Error: System.IO.IOException:
Bitrate must be: -b 448000

Edit: Valid values for bitrate only exact:
32, 40, 48, 56, 64, 80, 96, 112, 128, 160, 192, 224, 256, 320, 384, 448, 512, 576, 640 Kb/s

Last edited by tebasuna51; 19th July 2006 at 11:15.
tebasuna51 is offline   Reply With Quote
Old 19th July 2006, 12:02   #352  |  Link
dimzon
BeHappy/MeGUI developer
 
dimzon's Avatar
 
Join Date: Oct 2003
Location: Moscow, Russia
Posts: 1,727
Quote:
Originally Posted by tebasuna51
Code:
Starting job Bueno.wav->Bueno_t2.ac3
Found Audio Stream
Channels=6, BitsPerSample=16, SampleRate=48000Hz
Aften.exe -v 0 -b 448 -m 1 -s 0 -cmix 1 -smix 2 -dsur 0 -dnorm 26 - "D:\Internet\AudioTest\aften\Bueno_t2.ac3"
Writing RIFF header to encoder's StdIn
Writing PCM data to encoder's StdIn
Error: System.IO.IOException:
Bitrate must be: -b 448000

Edit: Valid values for bitrate only exact:
32, 40, 48, 56, 64, 80, 96, 112, 128, 160, 192, 224, 256, 320, 384, 448, 512, 576, 640 Kb/s
Ok, will be fixed tonight
dimzon is offline   Reply With Quote
Old 19th July 2006, 18:22   #353  |  Link
marnix88
Registered User
 
Join Date: Sep 2004
Posts: 40
Is there a way to run BeHappy with commandline parameters or run FFmpeg with AviSynth without Behappy?

Don't get me wrong, Behappy does exacty what I need, but I'm creating a frontend for AVI to DVD and FFmpeg can't encode 5.1 channels correctly just by itself. If I have to use BeHappy to do the work, then it's going to take tons of 'SendKeys' to control it.

I thought I had figured it out with FFmpeg, but I don't. If I encode 5.1 channel 448kbps AC3 to 5.1 channel 384kbps AC3, then the center channel is moved to the front right channel.

What is BeHappy exactly doing to keep all the channels correct? I know it's using FFmpeg and AviSynth, but how is FFmpeg executed with the script to keep the channels in the correct place?

This is the AviSynth script Behappy gives me.

Code:
########################################
#Created by BeHappy v0.1.8.35345
#Creation timestamp: 19-7-2006 18:20:49
########################################
#Source FileName:D:\TestAudio.ac3
#Target FileName:D:\TestAudioEncoded.ac3
########################################

########################################
# [Source: NicAc3Source]
########################################
NicAc3Source("D:\TestAudio.ac3")

EnsureVBRMP3Sync() # Some black magic to avoid desync

########################################
# [Encoder: ffmpeg AC3 @ 384 kbps]
########################################
6==Audiochannels(last)?GetChannel(last,1,3,2,5,6,4):last
marnix88 is offline   Reply With Quote
Old 19th July 2006, 19:58   #354  |  Link
tebasuna51
Moderator
 
tebasuna51's Avatar
 
Join Date: Feb 2005
Location: Spain
Posts: 6,915
Quote:
Originally Posted by marnix88
What is BeHappy exactly doing to keep all the channels correct? I know it's using FFmpeg and AviSynth, but how is FFmpeg executed with the script to keep the channels in the correct place?
Code:
NicAc3Source("D:\TestAudio.ac3")
6==Audiochannels(last)?GetChannel(last,1,3,2,5,6,4):last
First line decode the ac3 to wav in correct wav order (L,R,C,LFE,SL,SR).

Last line, if there are 6 channels, re-order the channels from (L,R,C,LFE,SL,SR) to (L,C,R,SL,SR,LFE)

You can use Bepipe instead BeHappy with this command line:

Code:
Bepipe --script "NicAc3Source(^D:\TestAudio.ac3^).GetChannel(1,3,2,5,6,4)" | ffmpeg  -i - -y -acodec ac3 -ab 384 "D:\TestAudioEncoded.ac3"
Or with new Aften encoder
Code:
Bepipe --script "NicAc3Source(^D:\TestAudio.ac3^)" | Aften -b 384000 - "D:\TestAudioEncoded.ac3"

Last edited by tebasuna51; 19th July 2006 at 20:02.
tebasuna51 is offline   Reply With Quote
Old 19th July 2006, 21:01   #355  |  Link
marnix88
Registered User
 
Join Date: Sep 2004
Posts: 40
That works great!

Thank you very much, tebasuna51
marnix88 is offline   Reply With Quote
Old 22nd July 2006, 20:31   #356  |  Link
BigDid
Actually in reserve
 
Join Date: Oct 2004
Posts: 1,605
Quote:
Originally Posted by tebasuna51
Code:
Error: System.IO.IOException:
Same for me here, waiting for an update
Dimzon, Thanks in advance.

Quote:
Edit: Valid values for bitrate only exact:
32, 40, 48, 56, 64, 80, 96, 112, 128, 160, 192, 224, 256, 320, 384, 448, 512, 576, 640 Kb/s
@Tebasuna
Valid values in what sense? Regarding Dolby specs? or non-compliant for soft players? SAP players?
I would like to DRC/Normalize AC3-6ch with a lower bitrate than original; ie: 352 or 288 ...actually limited to 320 or 256 with ffmpeg ...?
Thanks for the info.

Did
__________________
Having a problem with AutoGK? Read & use the FAQ & MORE FAQ first
Want to exchange on AutoGK? try doom10.org
In reserve (inactive) for an undefined period of time.
BigDid is offline   Reply With Quote
Old 22nd July 2006, 21:07   #357  |  Link
tebasuna51
Moderator
 
tebasuna51's Avatar
 
Join Date: Feb 2005
Location: Spain
Posts: 6,915
@BigDid, bitrate must be discrete values, see 5.4.1.4 frmsizecod and Table 5.18 at: ATSC Standard: Digital Audio Compression (AC-3), Revision A

Edit: Each ac3 frame (32 msec. if 48 KHz) must have a discrete value, the VBR method is obtained with different bitrate frames. This method is not well supported.

Last edited by tebasuna51; 22nd July 2006 at 21:19.
tebasuna51 is offline   Reply With Quote
Old 22nd July 2006, 22:39   #358  |  Link
BigDid
Actually in reserve
 
Join Date: Oct 2004
Posts: 1,605
Quote:
Originally Posted by tebasuna51
@BigDid, bitrate must be discrete values, see 5.4.1.4 frmsizecod and Table 5.18 at: ATSC Standard: Digital Audio Compression (AC-3), Revision A
So it's in the specs.

Quote:
Edit: Each ac3 frame (32 msec. if 48 KHz) must have a discrete value, the VBR method is obtained with different bitrate frames. This method is not well supported.
I'll try to reformulate: Not being a "discrete value"(aka one one the supported bitrate from the specs) a Vbr resulting ac3 stream should not be well supported ...
Is it correct?
BTW I was speaking of CBR, not VBR but I suppose same conclusions applies.
Sorry to be dumb but I am not so... performant in audio matters
Thanks.

Did
__________________
Having a problem with AutoGK? Read & use the FAQ & MORE FAQ first
Want to exchange on AutoGK? try doom10.org
In reserve (inactive) for an undefined period of time.
BigDid is offline   Reply With Quote
Old 26th July 2006, 03:38   #359  |  Link
Sakuya
Registered User
 
Sakuya's Avatar
 
Join Date: Dec 2002
Posts: 218
I was wondering if anyone has achieved good results when converting from 6ch AAC to 6ch AC3 using BeHappy?

I converted my AAC file to a 6ch WAV file using audio2wav. Right now, I'm pondering whether I should add BeHappy's Digital Signal Processing. If I keep to the original, it won't change a thing and directly convert that to AC3 am I right?
Sakuya is offline   Reply With Quote
Old 26th July 2006, 12:35   #360  |  Link
tebasuna51
Moderator
 
tebasuna51's Avatar
 
Join Date: Feb 2005
Location: Spain
Posts: 6,915
Quote:
Originally Posted by Sakuya
I was wondering if anyone has achieved good results when converting from 6ch AAC to 6ch AC3 using BeHappy?
Without problems using DirectShowSource and ffdshow Audio decoder properly configured.
Quote:
Originally Posted by Sakuya
I converted my AAC file to a 6ch WAV file using audio2wav. Right now, I'm pondering whether I should add BeHappy's Digital Signal Processing. If I keep to the original, it won't change a thing and directly convert that to AC3 am I right?
I don't understand your question.
If you use faad decoder (audio2wav) the 6ch wav (with WAVE_FORMAT_EXTENSIBLE header) can be converted directly to ac3 with Aften encoder.
If you want open the 6ch wav in BeHappy you need BassAudio
because WAVE_FORMAT_EXTENSIBLE header.

Last edited by tebasuna51; 26th July 2006 at 12:41.
tebasuna51 is offline   Reply With Quote
Reply

Tags
behappy

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 01:24.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.