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 Usage

Reply
 
Thread Tools Search this Thread Display Modes
Old 28th June 2003, 10:14   #1  |  Link
FredThompson
Registered User
 
FredThompson's Avatar
 
Join Date: Feb 2002
Location: Charlotte, NC USA
Posts: 1,960
How to make a color-friendly grayscale?

I have some DV of analog source which alternates from color to greyscale and back a few times.

I'd really like to completely remove the chroma noise in the B&W sections.

Manually cutting these segments, filtering, and reassembling is acceptable if it's the only way.

The problem is I haven't figured out how to make a proper greyscale. The VirtualDub and AviSynth built-in filters yield clips which VirtualDub will refuse to append to color segments, claiming the formats are incompatible.

How can chroma be effectively removed yet the clip still "play friendly" with color clips?

Also, is there a way to do this conditionally within a script such that multiple sections would be converted to greyscale within the same stream, based on frame number?
__________________
Reclusive fart.
Collecting Military, Trains, Cooking, Woodworking, Fighting Illini, Auburn Tigers
FredThompson is offline   Reply With Quote
Old 28th June 2003, 12:35   #2  |  Link
Wilbert
Moderator
 
Join Date: Nov 2001
Location: Netherlands
Posts: 6,293
Quote:
The problem is I haven't figured out how to make a proper greyscale. The VirtualDub and AviSynth built-in filters yield clips which VirtualDub will refuse to append to color segments, claiming the formats are incompatible.
Use greyscale and append them in AviSynth. I assume that the color segments and greyscale segments are from the same clip?

Quote:
Also, is there a way to do this conditionally within a script such that multiple sections would be converted to greyscale within the same stream, based on frame number?
Don't know. Have you tried ApplyRange: http://cvs.sourceforge.net/cgi-bin/v...e.html?rev=1.7
Wilbert is offline   Reply With Quote
Old 28th June 2003, 16:39   #3  |  Link
FredThompson
Registered User
 
FredThompson's Avatar
 
Join Date: Feb 2002
Location: Charlotte, NC USA
Posts: 1,960
Ah, insight

Another approach I thought of last night is to force the chroma range to very low, say 1-10, and let it get removed by Limiter(). Don't know how to re-scale it but this should be more append-friendly.

Last edited by FredThompson; 29th June 2003 at 06:13.
FredThompson is offline   Reply With Quote
Old 29th June 2003, 06:13   #4  |  Link
FredThompson
Registered User
 
FredThompson's Avatar
 
Join Date: Feb 2002
Location: Charlotte, NC USA
Posts: 1,960
Darn it, I'm doing something incorrectly. This is being rejected with the claim the arguments for ApplyRange are invalid:

ApplyRange(1416,1801,"GreyScale")

Why is this happening?
FredThompson is offline   Reply With Quote
Old 29th June 2003, 14:13   #5  |  Link
Guest
Guest
 
Join Date: Jan 2002
Posts: 21,924
Ha ha. Gotcha! Tweak strikes again.

Greyscale takes no arguments, so it can't be animated. Use this:

ApplyRange(0,10,"Tweak",0.0,0.0,0.0,1.0)
Guest is offline   Reply With Quote
Old 29th June 2003, 20:42   #6  |  Link
stickboy
AviSynth Enthusiast
 
Join Date: Jul 2002
Location: California, U.S.
Posts: 1,268
Quote:
Originally posted by neuron2
Greyscale takes no arguments, so it can't be animated.
You can work around this by creating your own user-defined function to act as a wrapper.
Code:
function GreyscaleWrapper(clip c, string unused)
{
    return c.Greyscale()
}

ApplyRange(1416, 1801, "GreyscaleWrapper", "")
Or, a more general version:

Code:
function NoArgFunctionWrapper(clip c, string f)
{
    c
    return Eval(filter + "()")
}

ApplyRange(1416, 1801, "NoArgFunctionWrapper", "Greyscale")

Last edited by stickboy; 30th September 2006 at 20:01.
stickboy is offline   Reply With Quote
Old 29th June 2003, 20:47   #7  |  Link
Wilbert
Moderator
 
Join Date: Nov 2001
Location: Netherlands
Posts: 6,293
good one
Wilbert is offline   Reply With Quote
Reply

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 16:15.


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