View Full Version : WMCmd.vbs WME9 script update released - 10/11/07
buzzqw
12th April 2007, 21:36
dosbox running cscript wmcmd.vbs remain open after end encoding :confused: , usually it close itself... (again with new update, without using -a_input)
BHH
NHRaider
13th April 2007, 00:05
Yeah, that's normal when using .avs as sources.
Are you encoding the video and audio separately? If you're muxing them together in the .avs file, can you verify they are the same length?
WMcmd is just relying on DirectShow and WMP to report the correct lengh of the .avs source. If you can get it to play back in WMP - it will report the correct length in Wmcmd too.
Audio:
Directshowsource("audio_only.GRF", audio=true, video=false)
Video:
Directshowsource("video_only.GRF", fps=23.976, audio=false, seekzero=false, seek=true).trim(0,140000)
Audioandvideo Input File to script:
video = import("video_only.avs")
audio = import("audio_only.avs")
AudioDub(video,audio)
When I open the AudioandVideo.avs, VirtualDub it says video duration is 1:34:35 and the audio duration is 1:37:13.
The problem I have is that when I don't specify framecount or .trim the video, then it shows all the information about the duration, progress of encoding then final statistics, BUT the video seems to stop encoding around 50 minutes.
When I do use .trim in video, after it mentions the "cant' find duration", it doesn't detail any durations, etc... And when I play back, it doesn't show duration or allow Fast Forward...
Is there something wrong with how I need to specify the framecount in video.avs?
NHRaider
13th April 2007, 00:09
seems to be normal when you encode via Directshowsoucre ,that wmcmd use a alternative Method to load the Source..
Dont know what it means, but i have thge same Mesaage without Problems.
Your seeking Problem:
You can seek the output after the encode is finished cause the wmv index is complete. Then you have your duration and full seeking.
When you want to fix a aborted output , run it through WMStreameditor
I made a lot of HDDVD VC1 encodes with Directshowsource and SonicVideoDecoder.
WMcmd shows me the correct Source duration in seconds and after encoding the Stats have the correct Framecount with encoded frames and the Output is perfect
For example :
C:\Programme\Windows Media-Komponenten\Encoder>cmd /k cscript.exe C:\windows\wmc
md.vbs -input g:\Parfuem\Parfuem.avs -output g:\parfuem\parfuem.wmv -v_codec WVC
1 -videoonly -v_mode 0 -v_bitrate 7020000 -v_preset better -v_buffer 60000 -v_qu
ality 100
Microsoft (R) Windows Script Host, Version 5.6
Copyright (C) Microsoft Corporation 1996-2001. Alle Rechte vorbehalten.
Microsoft (R) Windows Media Encoder Command Line Script Utility
Copyright (C) Microsoft Corporation. All rights reserved.
Warning: Encoder failed to retrieve duration attribute from source plug-in.
Trying alternate method now......
Source duration retrieved: 8853,943 seconds.
Encoded: 8853,6s (100%) Elapsed: 17:14:02 Left: 00:00:02 [0,14x]
======== Encoding Completed ========
Video :
Codec: Windows Media Video 9 Advanced Profile
Expected bit rate: 7020000 bps
Average bit rate: 6719201 bps
Expected fps: 23,976
Dropped frame count: 0
Total coded frames: 212282
Average sample rate: 23,952
Dropped bytes: 0 bytes
Total bytes: 7436396454 bytes
Overall:
Encoding time: 62053 seconds
Average bit rate: 6719201 bps
File size: 7470570538 bytes
File duration: 8853,934 seconds
C:\Programme\Windows Media-Komponenten\Encoder>
Can you show me your video.avs so I can see how you represent the framecount? I don't get anything below "Trying alternate method now......" if I use .trim or framecount.
And the bigger problem is not being able so fast forward.
zambelli
13th April 2007, 00:36
just to report that the update version will crash cscript.exe using -a_input (on win 2003 server) BUT is ok on winxp pro...
Hmm, that's really strange. Same source? Same codecs used?
One more: seems that -v_percopt isn't use in your preset (at last looking inside wmvcmd.vbs), why ?
Because it's a perceptual optimization setting. It introduces a tradeoff in quality between certain areas. It's very subjective. It might work well on some content and poorly on others. I don't plan on using v_percopt or v_dquantoption in any of the presets. That should be up to the user to experiment with and add as necessary.
dosbox running cscript wmcmd.vbs remain open after end encoding , usually it close itself... (again with new update, without using -a_input)
Damn, I was hoping that wouldn't happen. What is your exact command line?
buzzqw
13th April 2007, 07:24
Hmm, that's really strange. Same source? Same codecs used?
exactly same source and same command line (but without using -a_input is ok on both)
Damn, I was hoping that wouldn't happen. What is your exact command line?
this is one
cscript.exe "C:\Programmi\PureBasic4\AutoMKV\exe\encoder\WMCmd.vbs" -input "C:\Programmi\PureBasic4\AutoMKV\test\temp\movie.avs" -output "C:\Programmi\PureBasic4\AutoMKV\test\temp\movie.wmv" -v_codec WMV7 -v_mode 3 -v_bitrate 531403 -s_config "C:\Programmi\PureBasic4\AutoMKV\test\temp\wmv_crb" -v_bframedist 1 -v_dquantoption 2 -v_lookahead 0 -v_mbmodecost 0 -v_mmatch 0 -v_msrange 0 -v_mvcoding 1 -v_mvcost 0 -v_bdeltaqp 1 -a_codec WMASTD -a_mode 0 -title "_aaa" -year 2007 -copyright "Done with AutoMKV! 0.80d" -a_setting 96_44_2
and
cscript.exe "C:\Programmi\PureBasic4\AutoMKV\exe\encoder\WMCmd.vbs" -input "C:\Programmi\PureBasic4\AutoMKV\test\temp\movie.avs" -output "C:\Programmi\PureBasic4\AutoMKV\test\temp\movie.wmv" -v_codec WVC1 -v_mode 3 -v_bitrate 437653 -s_config "C:\Programmi\PureBasic4\AutoMKV\test\temp\wmv_crb" -v_preset fast -v_bframedist 1 -v_dquantoption 3 -v_bdeltaqp 1 -a_codec wmapro -a_mode 0 -title "_aaa" -year 2007 -copyright "Done with AutoMKV! 0.80d" -a_setting 192_48_2_16
something gotta strange on my pcs, on winxp those script hang... and on win2003srv not hang!
i have installed same softwares (WMEncoder9.exe + wmfdist11.exe+wmp11) on both machine...
can i give more information for resolve ?
thanks!
BHH
NHRaider
13th April 2007, 12:12
seems to be normal when you encode via Directshowsoucre ,that wmcmd use a alternative Method to load the Source..
Dont know what it means, but i have thge same Mesaage without Problems.
Your seeking Problem:
You can seek the output after the encode is finished cause the wmv index is complete. Then you have your duration and full seeking.
When you want to fix a aborted output , run it through WMStreameditor
It's not what I anticipated but it works. When I use Sonic Video Decoder it says the movie is only 50 minutes and stops there. But it does show duration and the statistics post encode.
When I use Intervideo Video Decoder, it says the movie is 1:37, but it does NOT show any duration or statistics and the cmd window sort of stays open and does nothing. I have to check to see if the file has stopped growing to know it's competed. Then there is no Fast Forward!
So, I tried your WMStreameditor and it seems to work to put he duration back on the file..
Not sure why sonic thinks the movie is 1/2 as long as it should be...
ACrowley
13th April 2007, 13:02
DirectShowSource("G:\Bourne\Bourne.grf",fps=23.976,framecount=155992,seekzero=false,seek=true,audio=false)
On SonicCinemasterVideoDecoder 4.2 i never had any Problems
The avs shows correct runtime, all other apps, players or somewhat too
Have you demuxed the VC1 from evo properly ? I think you know, the encoding directly from evo is a Mistake ?
What graph are you using ?
The other Way would be to mux the Evo in mkv and use it for encoding.
So you need no Framecount etc..
NHRaider
13th April 2007, 13:19
DirectShowSource("G:\Bourne\Bourne.grf",fps=23.976,framecount=155992,seekzero=false,seek=true,audio=false)
On SonicCinemasterVideoDecoder 4.2 i never had any Problems
The avs shows correct runtime, all other apps, players or somewhat too
Have you demuxed the VC1 from evo properly ? I think you know, the encoding directly from evo is a Mistake ?
What graph are you using ?
The other Way would be to mux the Evo in mkv and use it for encoding.
So you need no Framecount etc..
Not sure what the problem is but SonicCinemasterVideoDecoder 4.2 seems to stop video at 50minutes.
I have demuxed to .vc1 and dts files and am using GraphEdit on those files.
I'm using MS DirectShow SDK Filter Graph Edit.
VC1 Source -> Sonic HD Demux -> Sonic Cinemaster Video Decoder 4.2 -> Null Render (on CC out)
When I run the batch file, I also get a bunch of warnings like:
ContextException thrown by BaseCertificate::GetField [.\BaseCertificate.cpp:903] with context
Field
SAR_FeatureValue
not found in certificate
C:\Program Files\Common Files\Roxio Shared\Certificates8\cp42ppg.rxc
NHRaider
13th April 2007, 13:24
DirectShowSource("G:\Bourne\Bourne.grf",fps=23.976,framecount=155992,seekzero=false,seek=true,audio=false)
How much buffer are you adding on framecount to the calculated frames from EVO demux?
buzzqw
13th April 2007, 13:39
@Zambelli
hi have substituted the function TerminateEncoderProcess() of new build (12/04/2007) with one of old build (22/03/2007 and the script close successfull :)
i will postpone my update to automkv till this issue ins't cleared, or you will allow me to change wmcmd.vbs
BHH
ACrowley
13th April 2007, 14:10
How much buffer are you adding on framecount to the calculated frames from EVO demux?
Buffer ? What for a Buffer ? latest version of Evodemux calculates the Frames 99,9% correct ,or waht do you mean ?
I use exactly the "calculated Framecount" from latest Evodemux
For encoding i use -v_buffer 60000
But i think i know what is your Error !
Use :
Filesource(async)-SoncHDDemuxer-SonicCinemasterVideoDecoder
Not VC1 Source Filter! I dont think it will work properly, with Filesource you have no Problems
No Wonder why you have wrong values .
zambelli
13th April 2007, 17:17
hi have substituted the function TerminateEncoderProcess() of new build (12/04/2007) with one of old build (22/03/2007 and the script close successfull :)
i will postpone my update to automkv till this issue ins't cleared, or you will allow me to change wmcmd.vbs
Hi Buzzqw,
Yeah, that function is the culprit, but I need to figure out what's making it not match the process command-line correctly. It matches the process on my machine correctly, so this must be some weird OS issue it's running into.
In the meantime, feel free to use your modified WMCmd.vbs version with the new AutoMKV release. I'll try to figure out what's causing the hang in the meantime.
Could you also provide the a_input command-line that's making your cscript crash, along with a description of what kind of audio is being sourced (i.e. stereo, 44100 Hz, etc)? Thanks.
buzzqw
13th April 2007, 18:02
cscript.exe "C:\Programmi\PureBasic4\AutoMKV\exe\encoder\WMCmd.vbs" -input "C:\Programmi\PureBasic4\AutoMKV\test\temp\movie.avs" -output "C:\Programmi\PureBasic4\AutoMKV\test\temp\movie.wmv" -v_codec WVC1 -v_mode 3 -v_bitrate 437653 -s_config "C:\Programmi\PureBasic4\AutoMKV\test\temp\wmv_crb" -v_preset fast -v_bframedist 1 -v_dquantoption 3 -v_percopt 1 -v_bdeltaqp 1 -a_input "C:\Programmi\PureBasic4\AutoMKV\test\temp\audio.wav" -a_codec wmapro -a_mode 0 -title "_aaa" -year 2007 -copyright "Done with AutoMKV! 0.80d" -a_setting 192_48_2_16
and this is the audio.wav (4.5mb) http://www.64k.it/andres/data/a/audio.wav
just one info: if i create an avs like this (say audio.avs)
directshowsource("audio.wav")
and feed the wmcmd.vbs, substituting the -a_input "C:\Programmi\PureBasic4\AutoMKV\test\temp\audio.wav"
with -a_input "C:\Programmi\PureBasic4\AutoMKV\test\temp\audio.avs"
the cscript don't crash... could be some setting in ffdshow ? (i use this to decode almost all audio format, besides WMA files...)
one more thing, don't run directly the cscript from dos box... but i build a .bat file and then launch this bat file. Anyway both launching from dos box (by copying the command line) and launch the bat the cscript doesn't close
BHH
zambelli
14th April 2007, 04:05
and this is the audio.wav (4.5mb) http://www.64k.it/andres/data/a/audio.wav
just one info: if i create an avs like this (say audio.avs)
directshowsource("audio.wav")
the cscript don't crash... could be some setting in ffdshow ? (i use this to decode almost all audio format, besides WMA files...)
Thank you for the sample - it explained a lot. That WAV is using IEEE Float precision. If you play it back in MPC, you'll see this in the file properties: IEEE Float 48000Hz stereo 3072Kbps. I'm guessing WME9 tries to process it directly (and fails), whereas DirectShowSource uses Ffdshow to decode and convert it to 16-bit integer PCM.
one more thing, don't run directly the cscript from dos box... but i build a .bat file and then launch this bat file. Anyway both launching from dos box (by copying the command line) and launch the bat the cscript doesn't close
But it closes fine when invoked from a command window?
Are you running Windows in Italian by any chance?
buzzqw
14th April 2007, 08:06
That WAV is using IEEE Float precision
that's true! ... i must "downsample" to 32bit pcm...
But it closes fine when invoked from a command window?
NO. It's doesn't close in command window and not close when launching (from explorer) the bat file
and yes, WinXp Pro Sp2 Italian (but at work... on win2003server SP2 ITALIAN it close ok...)
BHH
zambelli
14th April 2007, 08:34
I've replaced the April 12th build with a new build (dated April 14th) that fixes the bug that was hanging the script at the end of the encode.
http://citizeninsomniac.com/WMV/WMCmd_20070414.zip
buzzqw
14th April 2007, 08:41
I've replaced the April 12th build with a new build (dated April 14th)
:thanks: !
this build fixed my hang problem!!
BHH
NHRaider
14th April 2007, 12:11
Yeah, that's normal when using .avs as sources.
Are you encoding the video and audio separately? If you're muxing them together in the .avs file, can you verify they are the same length?
WMcmd is just relying on DirectShow and WMP to report the correct lengh of the .avs source. If you can get it to play back in WMP - it will report the correct length in Wmcmd too.
After a little experimentation I found the duration issue!
When I use:
Directshowsource("video_only.GRF", fps=23.976, audio=false, framecount = 145000, seekzero=false, seek=true)
* I get 1:37 for the duration from the movie.
When I use:
Directshowsource("video_only.GRF", fps=23.976, audio=false, seekzero=false, seek=true).trim(0,145000)
* I get duration of 50 minutes for the movie.
Unfortunately after 13 hours of encoding it crashed...
Encoded: 5868.6s (97%) Elapsed: 13:40:24 Left: 00:25:02 [0.12x]
Encoder error: 0x8007000E
Error occurred in transcoding: Error Code = 0x8007000E
When I open the audioandvideo.avs in VirtualDub and check the length, the audio length is 1:37.13 and the video length is 1:40.47.
I'm assuming those extra video minutes are the 9000 extra frames I added to directshowfilter over what EVO Demux gave me.
The actual output .wmv is 1:37:49 in length.
NHRaider
14th April 2007, 12:53
Buffer ? What for a Buffer ? latest version of Evodemux calculates the Frames 99,9% correct ,or waht do you mean ?
I use exactly the "calculated Framecount" from latest Evodemux
For encoding i use -v_buffer 60000
But i think i know what is your Error !
Use :
Filesource(async)-SoncHDDemuxer-SonicCinemasterVideoDecoder
Not VC1 Source Filter! I dont think it will work properly, with Filesource you have no Problems
No Wonder why you have wrong values .
Lots of conflicting terms...when I wrote buffer, I really meant "padding" on the numbers or how much extra to add. I was reading earlier in the HD-DVD to WMV thread that you add some frames to eliminate the chance of vidoe getting cut off. If EVO is 99.9% accurate, then I will certainly use that number for framecount.
I tried your method and that was the problem...rendering file vs. filesource (async). It fixed my video problem! I did the same file source (async) on the audio and unbelieveably I have 6 channel DD in the sonic demux filter for the audio using the sonic audio decoder! The last bit of question is the video is 1:48 as expected. However, the audio is 4:31! When I render the audio file, I get the correct 1:48 but only 2 channels. Additional note VirtualDub says it's still 2 channel but the filter says 6...
Also, I do see True HD on the audio...is there a filter that would allow encoding?
Thanks in advance!
jokin
14th April 2007, 14:22
Now all I need to do is figure out how to get audio decoding in more than stereo for dolby digital plus! Sonic audio Decoder 4.2 only gives me 2 channels...
I use this method for the audio.
I do eac3to then tranzcode.
"eac3to <input.ddp> <output.wav>"
then
"tranzcode <output.wav>"
finally in WME I select audio as Multichannel WAV source then click properties of that and put each channel in its correct spot.
For Video I select the video_only.avs I have created that references my GRF.
Finally I select all my compression settings and start the encode.
ACrowley
14th April 2007, 19:46
You cant decode TrueHD to wave at the Moment
Sonic can only do DD+ ,no MLP
Also only SonicDecoder 4.2 is working with correct Channles...i think thats your Problem.
Use SonicCinemasterAudioDecoder 4.2, works perfect
You need Orbitlees modified Source Filter (DTS/AC3/DD+ Source)for the Audio NOT Filesource/asnyc)
Required Filters/Software: DTS/AC3/DD+ Source ,Dump.ax .SonicDecoder 4.2 . EAC3to will autom. the whole process.
Tranzcode 0.40b
1. eac3to to decode DD+ to raw-wave : eac3to.exe g:\audio.ec3 g:\audio.wav
2. Tranzcode.exe to decode the big 24bit waves to 24bit 6 monowaves (a 24bit multichannel wave is to big for the most encoders)
Tranzcode.exe youraudio.wav
3. encode 6mono waves to WMA10 Pro 24Bit 48khz using SonyVegas7 or Steinberg Nuendo/Cubase,that gives perfect Results which are very close to the original Audio.
buzzqw
14th April 2007, 21:26
sorry pal but you are going a little of topic...
is possible to leave to thread to problems/ideas regarding wmcmd.vbs ?
open one new thread for those problem
thanks :)
BHH
NHRaider
14th April 2007, 23:54
sorry pal but you are going a little of topic...
is possible to leave to thread to problems/ideas regarding wmcmd.vbs ?
open one new thread for those problem
thanks :)
BHH
I was on topic on an issue getting this error running the vbs script...
"Unfortunately after 13 hours of encoding it crashed...
Encoded: 5868.6s (97%) Elapsed: 13:40:24 Left: 00:25:02 [0.12x]
Encoder error: 0x8007000E
Error occurred in transcoding: Error Code = 0x8007000E"
buzzqw
15th April 2007, 07:11
Nothing personal NHRaider :)
happy encoding!
BHH
olivierdb
17th April 2007, 11:04
Hello again Zambelli,
I am having problems with your latest version of WMCmd.vbs when used with Sonic Cineplayer Decoder Pack 4.2.
I use the following DirectShow filters to decode my HD content:
audio: DTS/DD+/AC3 source filter>Sonic Audio Decoder
video: File Source(Async)>Sonic HD demuxer>Sonic Video Decoder
I have no problems rendering the HD content with Sonic. However, when I execute the wmcmd.bat file, I get a series of errors of the type:
ContextException thrown by BaseCertificate::GetField [.\BaseCertificate.cpp:903]
with context
Field
SAR_FeatureValue
not found in certificate
C:\Program Files\Common Files\Roxio Shared\Certificates8\cp42ppg.rxc
Would you know what the problem is here and how to fix it?
(NHRaider reported this problem earlier in this thread (http://forum.doom9.org/showthread.php?p=988478#post988478), but I haven't seen any answers!)
NHRaider
17th April 2007, 12:12
Hello again Zambelli,
I am having problems with your latest version of WMCmd.vbs when used with Sonic Cineplayer Decoder Pack 4.2.
I use the following DirectShow filters to decode my HD content:
audio: DTS/DD+/AC3 source filter>Sonic Audio Decoder
video: File Source(Async)>Sonic HD demuxer>Sonic Video Decoder
I have no problems rendering the HD content with Sonic. However, when I execute the wmcmd.bat file, I get a series of errors of the type:
ContextException thrown by BaseCertificate::GetField [.\BaseCertificate.cpp:903]
with context
Field
SAR_FeatureValue
not found in certificate
C:\Program Files\Common Files\Roxio Shared\Certificates8\cp42ppg.rxc
Would you know what the problem is here and how to fix it?
(NHRaider reported this problem earlier in this thread (http://forum.doom9.org/showthread.php?p=988478#post988478), but I haven't seen any answers!)
After some trial and error, these warnings are originating from the Sonic Video Decoder filter. If you use InterVideo Video Decoder, the warnings go away. However, even getting the ContextExceptions above, I still get the output video...so I'm not sure if they are warnings vs. errors. I'm sure someone with more knowledge of the inner-workings can elaborate. Also, I was getting these warnings before and after the .vbs release
jokin
17th April 2007, 13:42
I get the same errors with the VBS. I switched to the GUI so I could use my 6 mono tranzcoded wavs directly. I haven't had any problems with the video so I wouldn't worry about it.
olivierdb
17th April 2007, 16:54
After a whole series of ContextException error messages, I get this final message:
"Prepare to encode failed with error -1072886856 The input media format is invalid."
Therefore no output.wmv is produced. I don't see why I have no issue rendering the video from within graphedit, yet it doesn't work with WMCmd.vbs!
buzzqw
17th April 2007, 17:28
you are not alone.... :( even with normal mpeg2 file (processed via avisynth/dgdecode) cause crash in wmcmd.vbs.. while playing in virtualdub (or xvid/x264) is ok...
i hope that wvcmd.vbs get more stable :)
BHH
NHRaider
17th April 2007, 17:56
After a whole series of ContextException error messages, I get this final message:
"Prepare to encode failed with error -1072886856 The input media format is invalid."
Therefore no output.wmv is produced. I don't see why I have no issue rendering the video from within graphedit, yet it doesn't work with WMCmd.vbs!
Don't feel alone...but I believe by my many attempts at converting the audio to multi-channel, I would get that "Prepare to encode failed with error -1072886856 The input media format is invalid." when I used a wrong -a_setting in the vbs.
Mostly by trying to do something like 640_48_6_24 when there was a conflict with any of those parameters. I bet if you remove the -a_setting input the error goes away...it did for me...when I saw all the warnings I assumed that they were both related to the video filter...
jokin
18th April 2007, 00:15
After a whole series of ContextException error messages, I get this final message:
"Prepare to encode failed with error -1072886856 The input media format is invalid."
Therefore no output.wmv is produced. I don't see why I have no issue rendering the video from within graphedit, yet it doesn't work with WMCmd.vbs!
I also had this error. When my audio setting was:
-a_setting 640_48_6_24
it would crash with the same error.
If I used:
-a_setting 192_48_2_24
or -a_setting 192_48_2_16
It didnt.
I will try to duplicate the error but I remember trying to connect a ddp file to Sonic Cinemaster Audio Decoder 4.2 and graphedit gave an error like use a decoder that supports 5 channels.
I could only get it to work with 192 kbps and 2 channels.
Try changing your script to the
-a_setting 192_48_2_24
or
-a_setting 192_48_2_16
setting.
This is why I do the 6 mono waves directly into the GUI.
I just made a HDDVD profile and it take maybe 30 secs more to load it and change the video bitrate than to edit my script.
ACrowley
18th April 2007, 11:15
I also had this error. When my audio setting was:
This is why I do the 6 mono waves directly into the GUI.
I just made a HDDVD profile and it take maybe 30 secs more to load it and change the video bitrate than to edit my script.
yep , it works with wmencoder.
But you can only use 16 and 24 Bit mono waves in wmencoder
NHRaider
18th April 2007, 18:16
I've been getting this error when encoding via both WME GUI and by using wmcmd.vbs ...
VBS:
"Encoder error: 0x8007000E
Error occurred in transcoding: Error Code = 0x8007000E"
WME:
"Not enough storage is available to complete this operation. (0x8007000E)"
This seems to be an out of memory error. It's consistently happening about 1:38 into encoding across 2 different movies and multiple attempts each.
I have 4GB or RAM so I don't think it's hardware related.
If this is relevant:
Windows XP Media Center Edition Version 2002 Sevice Pack 2. It's a relatively new machine so I'm not sure why 2005 isn't on there.
Dell XPS Intel Core 2 CPU X6800 @2.93GHz, 2.93GHz.
My question is if anyone has seen this particular error and what is the culprit? I'm sure some of the developers have seen this....
Any help would be appreciated.
BTW, I have managed to encode in entirety movies in 2 channel. The multichannel encoding seems to be what is causing these issues...
In the interim, I'll try to used WME to create the WMA 6channel audio and WME on the video avs to see if they can be independently encoded. Then I'll try to mux them with Stream Edit...
These 13 hour cycles are draining...
olivierdb
19th April 2007, 10:12
@Zambelli: It seems that WMCmd.vbs generates the error "Prepare to encode failed with error -1072886856 The input media format is invalid." when using 6 channels instead of 2 in the following script (with 2 channels it works!):
cscript.exe "C:\Program Files\Windows Media Components\Encoder\wmcmd.vbs" -input "C:\Documents and Settings\Olivier\My Documents\My Videos\HD-DVD to WMV HD\AudioAndVideo.avs" -output "C:\Documents and Settings\Olivier\My Documents\My Videos\HD-DVD to WMV HD\output.wmv" -v_bframedist 1 -v_bdeltaqp 1 -v_mslevel 1 -v_codec wvc1 -v_keydist 3 -v_mode 2 -v_quality 96 -v_mmatch 0 -v_msrange 0 -v_performance 20 -v_loopfilter 1 -a_codec wmapro -a_setting 384_48_6_24
Would you have an idea why the 6 channels are not supported?
(FYI - I used DTS/DD+/AC3 source filter>Sonic Cinemaster Audio Decoder 4.2 to decode 5.1 DD+ channels)
zambelli
19th April 2007, 10:38
you are not alone.... :( even with normal mpeg2 file (processed via avisynth/dgdecode) cause crash in wmcmd.vbs.. while playing in virtualdub (or xvid/x264) is ok...
i hope that wvcmd.vbs get more stable :)
Well, those kind of issues are unfortunately out of my hands. I can't fix issues in WME9 DLLs. Things that make cscript.exe crash are typically not errors in the VBScript code but issues in the runtime DLLs.
As for normal MPEG-2 not working... I think you may have a bigger issue there than just WME9/WMCmd. I routinely use MPEG-2 sources via Avisynth/DGDecode and I've NEVER had issues getting them to encode with WMCmd.vbs. Make sure strange filters aren't getting introduced into your DirectShow graphs when playing back .avs files.
zambelli
19th April 2007, 10:41
@Zambelli: It seems that WMCmd.vbs generates the error "Prepare to encode failed with error -1072886856 The input media format is invalid." when using 6 channels instead of 2 in the following script (with 2 channels it works!):
2/6 channels on input or output?
When feeding 6 channels to WME9, it's important to note: which format is being used? Integer precision? Floating point IEEE? 16-bit? 24-bit? 32-bit? Which version of Avisynth is used?
You can find out all this stuff by playing back the .avs in MPC and then checking the AVS audio Pin Out properties.
NHRaider
19th April 2007, 11:48
I've been getting this error when encoding via both WME GUI and by using wmcmd.vbs ...
VBS:
"Encoder error: 0x8007000E
Error occurred in transcoding: Error Code = 0x8007000E"
WME:
"Not enough storage is available to complete this operation. (0x8007000E)"
This seems to be an out of memory error. It's consistently happening about 1:38 into encoding across 2 different movies and multiple attempts each.
I have 4GB or RAM so I don't think it's hardware related.
If this is relevant:
Windows XP Media Center Edition Version 2005.
Dell XPS Intel Core 2 CPU X6800 @2.93GHz, 2.93GHz.
My question is if anyone has seen this particular error and what is the culprit? I'm sure some of the developers have seen this....
Any help would be appreciated.
BTW, I have managed to encode in entirety movies in 2 channel. The multichannel encoding seems to be what is causing these issues...
In the interim, I'll try to used WME to create the WMA 6channel audio and WME on the video avs to see if they can be independently encoded. Then I'll try to mux them with Stream Edit...
These 13 hour cycles are draining...
The memory error seems to be consistent when I'm encoding video (10.8kbps) and multichannel (768kbps 48KHz 6 Channel 24 bit) audio together. When I encode them separately and mux them with Stream Edit, there are no memory issues.
olivierdb
19th April 2007, 17:54
@Zambelli: These are the properties:
Properties from EVO Demux:
Dolby Digital Plus audio stream 0 found!
First PTS = 0000111D (+10ms)
Substream id = C0
Stream 0 is Dolby Digital Plus
frame size = 1024 bytes, number of blocks per frame = 1
Sampling frequency = 48 kHz
Transmission bitrate = 1536 kbit/s
Channel arrangement = L + R + C + Ls + Rs, bsid = 16
LFE channel = present
Properties from MPC:
- Connected to:
CLSID: {79376820-07D0-11CF-A24D-0020AFD79767}
Filter: Default DirectSound Device
Pin: Audio Input pin (rendered)
- Connection media type:
Audio: PCM 48000Hz stereo 1536Kbps
AM_MEDIA_TYPE:
majortype: MEDIATYPE_Audio {73647561-0000-0010-8000-00AA00389B71}
subtype: MEDIASUBTYPE_PCM {00000001-0000-0010-8000-00AA00389B71}
formattype: FORMAT_WaveFormatEx {05589F81-C356-11CE-BF01-00AA0055595A}
bFixedSizeSamples: 1
bTemporalCompression: 0
lSampleSize: 1
cbFormat: 18
WAVEFORMATEX:
wFormatTag: 0x0001
nChannels: 2
nSamplesPerSec: 48000
nAvgBytesPerSec: 192000
nBlockAlign: 4
wBitsPerSample: 16
cbSize: 0 (extra bytes)
pbFormat:
0000: 01 00 02 00 80 bb 00 00 00 ee 02 00 04 00 10 00 ....€»...î......
0010: 00 00 ..
- Enumerated media type 0:
Set as the current media type
Which, I presume, means that the Sonic Audio Decoder only supports 2 channels.
It's strange because:
DTS/DD+/AC3 source filter> Sonic Cinemaster Audio Decoder> AC3 filter
output is 6 channels! Would this mean that some upmixing takes place?
Thanks.
NHRaider
19th April 2007, 18:36
@Zambelli: These are the properties:
Properties from EVO Demux:
Dolby Digital Plus audio stream 0 found!
First PTS = 0000111D (+10ms)
Substream id = C0
Stream 0 is Dolby Digital Plus
frame size = 1024 bytes, number of blocks per frame = 1
Sampling frequency = 48 kHz
Transmission bitrate = 1536 kbit/s
Channel arrangement = L + R + C + Ls + Rs, bsid = 16
LFE channel = present
Properties from MPC:
- Connected to:
CLSID: {79376820-07D0-11CF-A24D-0020AFD79767}
Filter: Default DirectSound Device
Pin: Audio Input pin (rendered)
- Connection media type:
Audio: PCM 48000Hz stereo 1536Kbps
AM_MEDIA_TYPE:
majortype: MEDIATYPE_Audio {73647561-0000-0010-8000-00AA00389B71}
subtype: MEDIASUBTYPE_PCM {00000001-0000-0010-8000-00AA00389B71}
formattype: FORMAT_WaveFormatEx {05589F81-C356-11CE-BF01-00AA0055595A}
bFixedSizeSamples: 1
bTemporalCompression: 0
lSampleSize: 1
cbFormat: 18
WAVEFORMATEX:
wFormatTag: 0x0001
nChannels: 2
nSamplesPerSec: 48000
nAvgBytesPerSec: 192000
nBlockAlign: 4
wBitsPerSample: 16
cbSize: 0 (extra bytes)
pbFormat:
0000: 01 00 02 00 80 bb 00 00 00 ee 02 00 04 00 10 00 ....€»...î......
0010: 00 00 ..
- Enumerated media type 0:
Set as the current media type
Which, I presume, means that the Sonic Audio Decoder only supports 2 channels.
It's strange because:
DTS/DD+/AC3 source filter> Sonic Cinemaster Audio Decoder> AC3 filter
output is 6 channels! Would this mean that some upmixing takes place?
Thanks.
I've been trying to solve this problem for weeks with the multichannel. 2 Channel works like a champ, but multichannel has given me that input format error you state above. Some suggestions I received was making sure that you go to control panel > cineplayer dvd decoder options is set to 6 channels and that your system speaker is set to 6 channels.
Even then there were issues that you have above. I've found that I can go through the process and make the 6 channel audio is to just encode the video only...use the process to convert the audio to 6 mono wav files and encode them into a wma file and use stream edit to mux them.
Works perfectly.
buzzqw
19th April 2007, 19:06
@Zambelli
the problem arise with filter that change fps (from tdecimate to changefps)...
BHH
zambelli
19th April 2007, 22:14
@Zambelli
the problem arise with filter that change fps (from tdecimate to changefps)...
The crashing problem? I've used ConvertFPS and Decimate in my scripts many times, I don't recall seeing such a problem. Do the .avs files play back OK in WMP or GraphEdit?
buzzqw
20th April 2007, 07:26
here the script
#cut out load plugin part
movie = mpeg2source("D:\DVDMAGIC\temp\movie.d2v")
audio = DirectShowSource("D:\DVDMAGIC\temp\audio.wav") #this is a 3.01 Gb IEEE 2ch 2h 35m wav file (the audio of movie , Matrix NTSC version)
function getOrder(clip c) {
order = GetParity(c) ? 1 : 0
Return order }
movie = tfm(movie,d2v="D:\DVDMAGIC\temp\movie.d2v").tdecimate()
cropclip = autocrop(movie,mode=0,wmultof=4,hmultof=4,samples=40,aspect=0,threshold=34,samplestartframe=0)
fixed_aspect = 1.185185
c_width = width(cropclip)
c_height = Round(height(cropclip) / fixed_aspect)
input_par = float(float(c_width)/float(c_height))
input_par = input_par > 1.4 ? input_par : (4.0/3.0)
out_width = 672
out_height = Round(float(out_width) / input_par)
hmod = out_height - (floor(out_height / 16 ) * 16)
out_height = (hmod > 4) ? (out_height + (16 - hmod)) : (out_height - hmod)
new_aspect = (float(out_width) / float(out_height)) / fixed_aspect
autocrop(movie,mode=0,wmultof=4,hmultof=4,samples=40,aspect=new_aspect,threshold=34,samplestartframe=0)
LanczosResize(out_width,out_height)
Hqdn3d(4,3,6,4.5)
ColorMatrix("Rec.709->Rec.601",hints=false,threads=0)
audiodub(audio,last)
the file is perfectly played in mpc and graphedit
http://img401.imageshack.us/img401/930/grapheditmt5.th.png (http://img401.imageshack.us/my.php?image=grapheditmt5.png)
here the log of encoding
D:\DVDMAGIC\temp>movie_wmv.bat
D:\DVDMAGIC\temp>cscript.exe "C:\Programmi\PureBasic4\AutoMKV\exe\encoder\WMCmd.
vbs" -input "D:\DVDMAGIC\temp\movie.avs" -output "D:\DVDMAGIC\temp\movie.wmv" -
v_codec WVC1 -v_mode 3 -v_bitrate 577902 -s_config "D:\DVDMAGIC\temp\wmv_crb" -v
_preset better -v_dquantoption 3 -v_percopt 1 -v_bdeltaqp 1 -a_codec wmapro -a_m
ode 0 -title "VTS_02_0" -year 2007 -copyright "Done with AutoMKV! 0.81b" -a_set
ting 96_48_2_16
Microsoft (R) Windows Script Host Versione 5.6
Copyright (C) Microsoft Corporation 1996-2001. Tutti i diritti riservati.
Microsoft (R) Windows Media Encoder Command Line Script Utility
Copyright (C) Microsoft Corporation. All rights reserved.
Title: VTS_02_0
Year: 2007
Copyright: Done with AutoMKV! 0.81b
Warning: Encoder failed to retrieve duration attribute from source plug-in.
Trying alternate method now................................
Warning: Encoder failed to retrieve source duration again.
Encode process might not continue or progress report may be inaccurate.
======== Begin Pass1 ========
..............
======== Begin Pass2 ========
======== Encoding Completed ========
Audio :
Codec: Windows Media Audio 10 Professional
Expected bit rate: 96000 bps
Average bit rate: 96000 bps
Expected sample rate: 5859
Average sample rate: 0
Dropped byte count: 0 bytes
Dropped sample rate: 0
Total bytes: 0 bytes
Video :
Codec: Windows Media Video 9 Advanced Profile
Expected bit rate: 577902 bps
Average bit rate: 577902 bps
Expected fps: 30
Dropped frame count: 0
Total coded frames: 0
Average sample rate: 0
Dropped bytes: 0 bytes
Total bytes: 0 bytes
Overall:
Encoding time: 77 seconds
Average bit rate: 673902 bps
File size: 5628 bytes
File duration: 0 seconds
D:\DVDMAGIC\temp>
hope that helps!
if i move the movie = tfm(movie,d2v="D:\DVDMAGIC\temp\movie.d2v").tdecimate() after autocrop scring the encoding goes fine (and changing it to
tfm(d2v="D:\DVDMAGIC\temp\movie.d2v").tdecimate() )
D:\DVDMAGIC\temp>movie_wmv.bat
D:\DVDMAGIC\temp>cscript.exe "C:\Programmi\PureBasic4\AutoMKV\exe\encoder\WMCmd.
vbs" -input "D:\DVDMAGIC\temp\movie.avs" -output "D:\DVDMAGIC\temp\movie.wmv" -
v_codec WVC1 -v_mode 3 -v_bitrate 577902 -s_config "D:\DVDMAGIC\temp\wmv_crb" -v
_preset better -v_dquantoption 3 -v_percopt 1 -v_bdeltaqp 1 -a_codec wmapro -a_m
ode 0 -title "VTS_02_0" -year 2007 -copyright "Done with AutoMKV! 0.81b" -a_set
ting 96_48_2_16
Microsoft (R) Windows Script Host Versione 5.6
Copyright (C) Microsoft Corporation 1996-2001. Tutti i diritti riservati.
Microsoft (R) Windows Media Encoder Command Line Script Utility
Copyright (C) Microsoft Corporation. All rights reserved.
Title: VTS_02_0
Year: 2007
Copyright: Done with AutoMKV! 0.81b
Warning: Encoder failed to retrieve duration attribute from source plug-in.
Trying alternate method now.............
Source duration retrieved: 8469,461 seconds.
======== Begin Pass1 ========
Read: 68,5s (0,8%) Elapsed: 00:01:01 Left: 02:04:43 [1,12x]
hope that help
BHH
zambelli
20th April 2007, 09:11
When you play it back in WMP (not MPC), how long does it take for WMP to start playing the video and show the duration?
buzzqw
20th April 2007, 09:33
using wmp11 on p4 3ghz prescott, 1gb ram, win2003srv
from 9 to 12 seconds
BHH
Icemaan
20th April 2007, 11:38
hello
Long I read about all what can make with Avisynth and Zambelli Script.
Now I have make a first Test for myself.
1.Demux a Testfile Evo into Mpv and Mpa
2.Encode the Mpv via Graphedit and Avisynth to Wmv
3.Mpa via Eac3to into Ac3 and then like the Tut from Zambelli into a 6 Channel Avi.
Now my Question
When I want encode the Audio Avi into WmaPro which Codec i need
and whats a good CommandLine Parameter for this
When i Have make the Wma how i can put the Wmv and the Wma together in one Container
Thanks for your help
Icemaan
zambelli
21st April 2007, 04:03
using wmp11 on p4 3ghz prescott, 1gb ram, win2003srv
from 9 to 12 seconds
Ah. It sounds like Autocrop is waiting for TFM and TDecimate to finish re-arranging frames before it processes the first frames - so hence the long delay in loading.
WMCMd.vbs will wait 30 seconds for WMP OCX to open to AVS, but it will only wait 3 seconds for the playback state to transition from opened to playing (it's at this point where the duration truly becomes available to WMP). I'm guessing that's where it's timing out.
I think it's generally preferable to use the Avisynth script which is faster - so if simply switching those 2 lines works faster - just use that then.
buzzqw
21st April 2007, 08:27
@zambelli
thanks Zambelli!
i'll try to adjust the avs
BHH
leiming2006
22nd April 2007, 04:53
Oh, a new version.
It's actually a good way to encode an awful number of files.
But why can't I get the file successfully?
Thanks.
edit: OK, finally I get it through checking the source code of that html.
zambelli
23rd April 2007, 00:34
Oh, a new version.
It's actually a good way to encode an awful number of files.
But why can't I get the file successfully?
Thanks.
edit: OK, finally I get it through checking the source code of that html.
Sorry, I've been having issues with my web host. I'll be switching providers very soon.
[consumer alert] MySiteSpace (http://www.mysitespace.com)is a horrible web hosting service provider. Security issues abound and the customer support is the worst I've seen in ages (sometimes they don't even reply to trouble tickets). I highly recommend to everybody to stay clear of MySiteSpace. [/consumer alert]
sportcenter
23rd April 2007, 05:31
hello to all (a few familiar users too)...
zambelli am getting into using your method - used to do how crowley used to do his encodes
one problem though, i am getting an error when i begin the .bat file
"Warning: Encoder failed to retrieve duration attribute from source plug-in. Trying alternate method now..."
it then finds another method and begins to encode....but after about 1 minute it gets VERY SLOW and eventually stops
my cmd -
cmd /k cscript.exe J:\wmcmd.vbs -input J:\test.avs -output J:\deer_hunter.wmv -v_codec WVC1 -videoonly -v_mode 0 -v_bitrate 5903000 -v_preset better -v_buffer 60000 -v_quality 100
any ideas?
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.