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 14th March 2004, 05:12   #1  |  Link
trevlac
budala
 
Join Date: Oct 2003
Location: U.S.
Posts: 545
Fun with Video Scopes

Hi,

I've had trouble knowing what to do with many of the lovely filters that are available. So, I made a vdub plugin that shows a bunch of charts of the video so I can measure/see the effect of filters like levels. I've included histograms, a waveform monitor, a vectorscope, and a scanner for 'non legal' composite signals.

I just reworked the thing so it could be called from avisynth. So, I thought I'd post here. It of course only works in RGB, but it's for seeing, not changing, so colorspace conversions should not be a big issue.

The plugin is here. Below is an avs usage function.

Code:
# Arguments:
#   mode:  0=Histograms, 1=Show Hot Pixels, 2=Video Channels, 
#          3=Waveform Monitor, 4=Vectorscope
#
#   (input Characteristic args mainly used for luma calcs)
#   NTSC vs PAL
#   stdDef (601) vs hiDef (709)
#   rng255 vs rng219 (Pick rng255=false if you want luma black=0)
#
#   (show channels used in modes 0,2,3)
#   luma,red,green,blue
#
#   hotFixMode: 0=turn hot pixels black, 1=lower intensity, 2=lower saturation
#   showWFMgrid: turn it off to see better.


function VD_clrtools(clip clip, int "mode",
			\ bool "NTSC", bool "stdDef", bool "rng255",
			\ bool "luma", bool "red", bool "green", bool "blue",
			\ int "hotFixMode", bool "showWFMgrid")
{
  LoadVirtualdubPlugin(VirtualDub_plugin_directory+"\clrtools.vdf", "_VD_clrtools")

  return clip._VD_clrtools(default(mode,0),0,0,
			\ default(NTSC,true)?1:0,0, 
			\ default(stdDef,true)?1:0, 
			\ default(rng255,true)?1:0, 
			\ default(luma,true)?1:0, 
			\ default(red,true)?1:0, 
			\ default(green,true)?1:0, 
			\ default(blue,true)?1:0, 
			\ default(hotFixMode,0), 
			\ default(showWFMgrid,true)?1:0)
}


#Example Usage:

avisource("my.avi", pixel_type="RGB32")

#Luma Histogram Only
VD_clrtools(mode=0,red=false,green=false,blue=false) 

#Luma Waveform Monitor
#VD_clrtools(mode=3,red=false,green=false,blue=false) 

#Vectorscope
#VD_clrtools(mode=4)

Last edited by trevlac; 15th March 2004 at 15:03.
trevlac is offline   Reply With Quote
Old 14th March 2004, 05:53   #2  |  Link
rfmmars
Registered User
 
Join Date: Feb 2004
Posts: 743
Many thanks for your plug-in and hard work.

richard
photorecall.net
rfmmars is offline   Reply With Quote
Old 15th March 2004, 14:03   #3  |  Link
Arachnotron
Alias fragger
 
Arachnotron's Avatar
 
Join Date: Jul 2003
Location: the Netherlands
Posts: 863
Arachnotron is offline   Reply With Quote
Old 8th February 2005, 14:27   #4  |  Link
BloodyRipper
tsMuxeR developer(-ish)
 
BloodyRipper's Avatar
 
Join Date: May 2003
Location: Poznań, Poland
Posts: 72
the link doesn't want to work...can anybody supply a mirror?
__________________
aka xavery at GitHub

Nie poganiaj mnie, bo tracę oddech.
BloodyRipper is offline   Reply With Quote
Old 8th February 2005, 15:01   #5  |  Link
Arachnotron
Alias fragger
 
Arachnotron's Avatar
 
Join Date: Jul 2003
Location: the Netherlands
Posts: 863
Try this one:

http://www.trevlac.us/colorCorrection/clrtools.vdf

(it's the www that makes the difference)

[edit] Spoke to soon!! Hey trev, your domain is gone!!
Arachnotron is offline   Reply With Quote
Old 2nd April 2007, 00:13   #6  |  Link
signal
to noise
 
Join Date: Dec 2005
Posts: 96
Is there a way to use this filter in a capture preview mode (possibly in vdub)?

I'd like to fine tune my analog capture setup (i.e. adjust color/brightness/etc) before capturing.

Thanks

Last edited by signal; 2nd April 2007 at 04:57.
signal is offline   Reply With Quote
Old 6th April 2007, 11:15   #7  |  Link
Arachnotron
Alias fragger
 
Arachnotron's Avatar
 
Join Date: Jul 2003
Location: the Netherlands
Posts: 863
This receipe is straight from trevlac. Make sure you use a recent ffdshow build and the latest colortools version.

Quote:
For Live DV feed Very Happy But should work for other sources.

Using
- VirtualVCR
- ffdshow
- my vdub scope
- avisynth script


1) Set ffdshow to decode DV as said in this thread

http://forum.doom9.org/showthread.ph...ght=ffdshow+dv

2) Make avisynth script to use colortools as said here

http://forum.doom9.org/showthread.ph...scope+avisynth

3) Change sample script to not use avisource and add a converttorgb32() at start, and a flipvertical() at end.

4) Startup vvcr capture preview (or another directshow cap app)

5) Check avisynth config setting in ffdshow decoder and load the script
Since my device is not DV, I used graphedit and attached the fddshow filter to the preview pin of the capture device.

It was a while back when I did this, so the details are a bit fuzzy by now. Prototyping in graphedit gives you a better grip on which conversions are happening along the chain.
Arachnotron 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 13:23.


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