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 > Capturing and Editing Video > Avisynth Development
Register FAQ Calendar Today's Posts Search

Reply
 
Thread Tools Search this Thread Display Modes
Old 1st April 2011, 16:40   #21  |  Link
ganymede
Registered User
 
Join Date: Aug 2010
Location: Paris
Posts: 52
Is it possible to combine audio and video output ? If I could pass audio and video at the same time to mencoder or ffmpeg, it would be a big step forward for me, compared to avs2yuv.
ganymede is offline   Reply With Quote
Old 1st April 2011, 17:05   #22  |  Link
doobry
Totally Clueless
 
doobry's Avatar
 
Join Date: Nov 2010
Location: Edinburgh, UK
Posts: 31
@ganymede

There is no reason not to be able to combine the outputs provided there is a simple container format that can wrap the video and audio unmangled, that the target tool can accept via stdin, any suggestions?

Last edited by doobry; 1st April 2011 at 17:11.
doobry is offline   Reply With Quote
Old 1st April 2011, 17:09   #23  |  Link
doobry
Totally Clueless
 
doobry's Avatar
 
Join Date: Nov 2010
Location: Edinburgh, UK
Posts: 31
@Gavino

What I mean by stale is that the latest release is from 2009, and I cannot find an updated avisynth_c.h header in the cvs that supports the new colourspaces I think 2.6 has.

And yes I am thinking of the unofficial builds, I'm new to all this, and I don't want to write something just to find out that everyone is actually using something different or that the work had already been done.
doobry is offline   Reply With Quote
Old 1st April 2011, 17:16   #24  |  Link
Chikuzen
typo lover
 
Chikuzen's Avatar
 
Join Date: May 2009
Posts: 595
oh doobry, did you think that I'm using 2.6.0MT
Then, it is a misunderstanding.
IMO, official 2.6.0alpha is more stable and faster than 2.5.8(not MT).
(I can't understand why IanB doesn't change alpha to latest stable )
__________________
my repositories
Chikuzen is offline   Reply With Quote
Old 1st April 2011, 17:36   #25  |  Link
doobry
Totally Clueless
 
doobry's Avatar
 
Join Date: Nov 2010
Location: Edinburgh, UK
Posts: 31
doesn't really matter what version you are using at this stage, I cannot find an updated avisynth_c.h that contains support for the new colourspaces, so I'm going to leave it until I can find an "official" source.
doobry is offline   Reply With Quote
Old 1st April 2011, 17:49   #26  |  Link
Gavino
Avisynth language lover
 
Join Date: Dec 2007
Location: Spain
Posts: 3,431
Quote:
Originally Posted by doobry View Post
What I mean by stale is that the latest release is from 2009, and I cannot find an updated avisynth_c.h header in the cvs that supports the new colourspaces I think 2.6 has.
I think this has something to do with developments regarding 'baked code' - see this post.
Perhaps IanB can shed more light on the subject.
__________________
GScript and GRunT - complex Avisynth scripting made easier
Gavino is offline   Reply With Quote
Old 1st April 2011, 18:08   #27  |  Link
doobry
Totally Clueless
 
doobry's Avatar
 
Join Date: Nov 2010
Location: Edinburgh, UK
Posts: 31
@Gavino

Thats exactly what I'm talking about, thank you!!! been unable to find that info myself, will give it a good read when I get some time.
doobry is offline   Reply With Quote
Old 1st April 2011, 18:26   #28  |  Link
doobry
Totally Clueless
 
doobry's Avatar
 
Join Date: Nov 2010
Location: Edinburgh, UK
Posts: 31
I've uploaded version 0.0.2 which has added interlaced support, and adds a dump of avisynth's internal pixel_type field to the --info option, as I thought it might be of use to be able to see / post the value avisynth is presenting to the program.

http://doobrymedia.com/avs2pipe-0.0.2.zip
doobry is offline   Reply With Quote
Old 1st April 2011, 18:37   #29  |  Link
Chikuzen
typo lover
 
Chikuzen's Avatar
 
Join Date: May 2009
Posts: 595
thanks for updating.

BWT, there is a typo in line 37 of readme.txt
s/aac/mp4/g
__________________
my repositories
Chikuzen is offline   Reply With Quote
Old 1st April 2011, 19:59   #30  |  Link
tebasuna51
Moderator
 
tebasuna51's Avatar
 
Join Date: Feb 2005
Location: Spain
Posts: 6,915
About Wavi.

Please read the pending bug http://sourceforge.net/tracker/?func...37&atid=956250
From this page you can download the wavi.exe fixed.
__________________
BeHappy, AviSynth audio transcoder.
tebasuna51 is offline   Reply With Quote
Old 1st April 2011, 20:34   #31  |  Link
doobry
Totally Clueless
 
doobry's Avatar
 
Join Date: Nov 2010
Location: Edinburgh, UK
Posts: 31
@tebasuna51, that looks correct, i found that link to samples I posted earlier great for testing if things were working correctly by piping them though my code and checking they came out the same.

fyi can you confirm that wavi handles channel mapping my parsing an int from the command line and directly writing it into the header? From a brief look at the code that seems to be what it does, but I just wanted to make sure.
doobry is offline   Reply With Quote
Old 2nd April 2011, 00:06   #32  |  Link
kemuri-_9
Compiling Encoder
 
kemuri-_9's Avatar
 
Join Date: Jan 2007
Posts: 1,348
you can find the modified avisynth_c.h that x264cli uses here

which is good enough to support recognizing the newer 2.6 csps if that's all you need.
it's not complete enough to write a filter with to support the new csps however.
__________________
custom x264 builds & patches | F@H | My Specs
kemuri-_9 is offline   Reply With Quote
Old 2nd April 2011, 00:53   #33  |  Link
ganymede
Registered User
 
Join Date: Aug 2010
Location: Paris
Posts: 52
Quote:
Originally Posted by doobry View Post
There is no reason not to be able to combine the outputs provided there is a simple container format that can wrap the video and audio unmangled, that the target tool can accept via stdin, any suggestions?
Good news. But are you sure that a container is needed, and that both audio and video cannot be output together as a raw data stream ?
It seems that ffmpeg and mplayer/mencoder can work with a raw data stream where audio and video are "mixed" (I don't know if it's the right word). For instance, I tested the following commands on my linux system :
Code:
cat file | ffplay -
cat file | mplayer -
"file" was either in .avi, .mp4 or .flv container, and in all cases ffplay or mplayer were able to read it, with both audio and video (so I guess ffmpeg and mencoder would be able to process it).
ganymede is offline   Reply With Quote
Old 2nd April 2011, 01:00   #34  |  Link
doobry
Totally Clueless
 
doobry's Avatar
 
Join Date: Nov 2010
Location: Edinburgh, UK
Posts: 31
Quote:
.avi, .mp4 or .flv container
what you are doing works because the avi etc files are sent directly to ffplay etc, they are already containers... something is needed to tell the receiving application what is video, what is audio, and how they are encoded. The current version provides YV12 video in a YUV4MPEG2 "container" and PCM / FLOAT audio in WAV container. In theory it should be possible to say use an AVI container to send both, but that assumes that you can send raw YV12 data in an avi file stream written on the fly, ideally one frame at a time.

Basically I've not looked into it, but I can easily make it output both streams, the issue is doing it in a way that other programs can understand.
doobry is offline   Reply With Quote
Old 2nd April 2011, 01:09   #35  |  Link
ganymede
Registered User
 
Join Date: Aug 2010
Location: Paris
Posts: 52
Quote:
Originally Posted by doobry View Post
what you are doing works because the avi etc files are sent directly to ffplay etc, they are already containers...
Oops, you're right
If it's not too complicated to embed YV12 video and PCM audio streams in an avi container, I guess it would do the trick.
ganymede is offline   Reply With Quote
Old 2nd April 2011, 01:17   #36  |  Link
doobry
Totally Clueless
 
doobry's Avatar
 
Join Date: Nov 2010
Location: Edinburgh, UK
Posts: 31
I really should be in bed, but I've had a quick google and YV12 is a supported microsoft / apple FOURCC, so it should be possible, the only problems I see is the receiving program being willing to play the avi without random access, which should be ok if you can cat then in, and it ignoring the 4GB limit that avi's 32bit headers impose. The same limit applies to WAV files but the encoders I use ignore the header so work fine.

Will have a go next week.
doobry is offline   Reply With Quote
Old 2nd April 2011, 02:33   #37  |  Link
space1999
Banned
 
Join Date: Mar 2011
Posts: 37
@ tebasuna51:

thanks for the unb0rked build of wavi.exe

@ doobry:

if a container is really desirable/required, would be a big problem to use Matroska ? AFAIK MP4 does not support uncompressed audio (not "natively" anyway), and even though AVI currently has no filesize limit, one can never be "100%-sure" of which applications fully respect the OpenDML specs.
space1999 is offline   Reply With Quote
Old 2nd April 2011, 13:22   #38  |  Link
ganymede
Registered User
 
Join Date: Aug 2010
Location: Paris
Posts: 52
@doobry : thank you very much.
ganymede is offline   Reply With Quote
Old 3rd April 2011, 02:13   #39  |  Link
tebasuna51
Moderator
 
tebasuna51's Avatar
 
Join Date: Feb 2005
Location: Spain
Posts: 6,915
Quote:
Originally Posted by doobry View Post
@tebasuna51,...
fyi can you confirm that wavi handles channel mapping my parsing an int from the command line and directly writing it into the header? From a brief look at the code that seems to be what it does, but I just wanted to make sure.
I'm not sure what ask you.

If is a wavi test, yes I make many test (because part of the code is from me) and I think work fine.

If is about your soft seems also work (gcc build tested), but:

- A minor info problem, the code seems ok:
avs2pipe [info]: writing 20 seconds of 0 Hz, 48000 channel audio.

- The Chunk 'fact' is not needed with WAVE_FORMAT_PCM/WAVE_FORMAT_IEEE_FLOAT.
The 'samples' data is always 'data_length'/'BlockAlign'

- The WAVE_FORMAT_EXTENSIBLE_HEADER is useless without a correct MaskChannel value.
AviSynth don't have a MaskChannel audio property, then decoders like NicAudio, than know the proper MaskChannel value, can't pass it to AviSynth.
And AviSynth can't pass the value to wavi/avs2pipe.
Wavi put a default value for each numchannels and accept a parameter to change the default.
__________________
BeHappy, AviSynth audio transcoder.
tebasuna51 is offline   Reply With Quote
Old 3rd April 2011, 17:36   #40  |  Link
doobry
Totally Clueless
 
doobry's Avatar
 
Join Date: Nov 2010
Location: Edinburgh, UK
Posts: 31
Quote:
Originally Posted by tebasuna51 View Post
A minor info problem, the code seems ok:
Thanks will try to work that out, clearly something is not right.


Quote:
Originally Posted by tebasuna51 View Post
The Chunk 'fact' is not needed with WAVE_FORMAT_PCM/WAVE_FORMAT_IEEE_FLOAT.
I saw that it was not required with WAVE_FORMAT_PCM but the info i had was a little unclear on WAVE_FORMAT_IEEE_FLOAT, i.e. info said it was "needed when the samples are not WAVE_FORMAT_PCM", so I figured as it is allowed, Its best to include it just incase... altho it should never be needed.


Quote:
Originally Posted by tebasuna51 View Post
The WAVE_FORMAT_EXTENSIBLE_HEADER is useless without a correct MaskChannel value.
It was my understanding that the spec included an "all zero" option for the mask that means the channels are mapped in order, ie first channel -> first output etc. As you said I cannot get a channel mask from avisynth, so I figured using this "blank" mask was the best option until I add a way to specify a mapping.

Last edited by doobry; 3rd April 2011 at 18:03.
doobry is offline   Reply With Quote
Reply

Tags
avs2pipe


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 17:11.


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