View Full Version : FACAR - As seen on TV!
ebcoelho
15th November 2003, 06:22
I had the same problem with my NTSC interlaced sources, I was using avisynth 2.0 with Blendfields in my movies but FACAR use 2.5x and I can't use this function in DVD2SVCD now :(.
I tried to put SeparateFields() in preresize.avs and Weave() in postresize.avs. But DVD2svcd preview says "you cannot use crop to enlarge or 'shift' a clip".
I'm waiting with Crackhead for an idea :(.
r6d2
15th November 2003, 06:27
OK, guys, let's try this.
Please use one of the default resizers from DVD2SVCD (bilinear, for instance). Select the deinterlacer of your choice and encode a short clip. You should check your encode to make sure it is satisfactory with the default resize/interlace.
Then post your AVS script so I can get a grasp on how to implement that if at all possible. As I said before, I don't have PAL interlaced sources to test it myself, so your help would be appreciated.
Crackhead
15th November 2003, 19:42
ok i hope i didn't misunderstand your suggestion! If so, plz tell me!:rolleyes: :D
i encoded one chapter of a movie with bilinear resize in frameserver and deinterlacer separatefields. the avisynth_script looks like this:
LoadPlugin("C:\PROGRA~1\DVD2SVCD\AVISYN~1.5PL\Mpeg2dec\MPEG2D~1.DLL")
mpeg2source("D:\SVCD\DVD2AV~2.D2V")
SeparateFields()
SelectEvery(2,0)
BilinearResize(480,432)
AddBorders(0,72,0,72)
Import("D:\SVCD\ResampleAudio.avs")
ResampleAudio(44100)
ConvertToYUY2()
the resize went fine, the AR was maintained, didn't notice any difference in quality to another test encode without deinterlacing, only the deinterlaced file was 0,5mb smaller than the one without deinterlacing.
hope this helps! feel free to ask for more test encodes with special settings from me, i want to help wherever i am able to!
btw, facar+d2sroba+dvd2vcd is one hell of a combination!! keep up the GREAT work!:thanks:
r6d2
16th November 2003, 02:48
Originally posted by Crackhead
ok i hope i didn't misunderstand your suggestion!
No, you got it quite right! :helpful:
LoadPlugin("C:\PROGRA~1\DVD2SVCD\AVISYN~1.5PL\Mpeg2dec\MPEG2D~1.DLL")
mpeg2source("D:\SVCD\DVD2AV~2.D2V")
SeparateFields()
SelectEvery(2,0)
BilinearResize(480,432)
AddBorders(0,72,0,72)
Import("D:\SVCD\ResampleAudio.avs")
ResampleAudio(44100)
ConvertToYUY2()
OK then. What I see is that deinterlaced seems to work when done completely just before the resize.
Please do one more test for me. Open FACAR.avs with the notepad and before this line:
# --(r6d2)-- Actual resize
insert this:
SeparateFields()
SelectEvery(2,0)
Encode a short clip again, this time with FACAR, but select No deinterlacing in DVD2SVCD.
Tell me if that works.
Crackhead
16th November 2003, 14:53
ok, did it.
first, it encoded fine, no error message anymore!
the result was ok, no noticable difference to the other encodes, but with facar it was about 5mb smaller. :D
i did the same chapter without any filters and bilinear resize!
i am curious whether it is possible to check if the movie is deinterlaced or not. bitrateviewer still shows that it is interlaced, no matter whether it was deinterlaced or not... :confused:
BIG :thanks: to r6d2, i think i will do some more tests to see what's possible with deinterlacing/interlaced material. :cool:
r6d2
16th November 2003, 22:46
Originally posted by Crackhead
first, it encoded fine, no error message anymore!
Glad to hear that.
i am curious whether it is possible to check if the movie is deinterlaced or not.
BR Viewer says that because of the framerate. In general, BR Viewer is not too smart. Take its information with a grain of salt.
You can indeed check the encode to see the interlacing. Use this (http://www.doom9.org/ivtc-tut.htm) guide.
Remember to comment out those lines if you have progressive source.
I might add a deinterlacing option for PAL sources in a future version, for people not having to edit the script.
ebcoelho
20th November 2003, 13:47
I had a NTSC interlaced source and I used this avisynth script:
AVISYNTH SCRIPT:
LoadPlugin("C:\ARQUIV~1\DVD2SVCD\AVISYN~1.5PL\Mpeg2dec\MPEG2D~1.DLL")
LoadPlugin("C:\ARQUIV~1\DVD2SVCD\AVISYN~1.5PL\AVISYN~2.DLL")
LoadPlugin("C:\ARQUIV~1\DVD2SVCD\AVISYN~1.5PL\SimpleResize\SimpleResize.dll")
mpeg2source("C:\ARQUIV~1\DVD2SVCD\Movie\DVD2AV~2.D2V")
ResizeTo=3 global ResizeMethod=2 DebugMode=0
GammaCorrection=1.0 Hue=0 Saturation=1.0 Brightness=0 Contrast=1.0
DetectedTop=0 DetectedHeight=480
OverscanH=0.04 OverscanV=0.04 BlockOptimization=1 AsoTV=1
global Bicubic_b_Value=0 global Bicubic_c_Value=0.6
DestinationWidth=480
DestinationHeight=480
Import("C:\ARQUIV~1\DVD2SVCD\AVISYN~1.5PL\FACAR\PreResize.avs")
ConvertToYUY2(interlaced=true) # this stuff is important?
LoadPlugin("C:\ARQUIV~1\DVD2SVCD\AVISYN~1.5PL\InverseTelecine\Decomb.dll")
FieldDeinterlace()
Import("C:\ARQUIV~1\DVD2SVCD\AVISYN~1.5PL\FACAR\FACAR.avs")
AvisynthSubtitler("C:\ARQUIV~1\DVD2SVCD\Movie\subs\","permsubs.txt")
Import("C:\ARQUIV~1\DVD2SVCD\Movie\ResampleAudio.avs")
ResampleAudio(44100)
or edit on dvd2svcd frameserver the template FACAR:
0=ResizeTo=^ResizeTo. global ResizeMethod=^ResizeMethod. DebugMode=^DebugMode
1=GammaCorrection=^GammaCorrection. Hue=^Hue. Saturation=^Saturation. Brightness=^Brightness. Contrast=^Contrast
2=DetectedTop=^DetectedTop. DetectedHeight=^DetectedHeight
3=OverscanH=^OverscanH. OverscanV=^OverscanV. BlockOptimization=^BlockOptimization. AsoTV=^AsoTV
4=global Bicubic_b_Value=^b_value. global Bicubic_c_Value=^c_value
5=DestinationWidth=^TargetWidth
6=DestinationHeight=^TargetHeight
7=LoadPlugin(!SimpleResize.dll)
8=LoadPlugin(!Decomb.dll)
9=FieldDeinterlace()
10=# Import(!qmf15b1.avs)
11=# Import(!QMF_functions.avs)
12=Import(!PreResize.avs)
13=ConvertToYUY2(interlaced=true) # this stuff is important?
14=Import(!FACAR.avs)
15=# Import(!PostResize.avs)
^ResizeTo.=3
^ResizeMethod.=2
^DebugMode=0
^GammaCorrection.=1.0
^Hue.=0
^Saturation.=1.0
^Brightness.=0
^Contrast=1.0
^DetectedTop.=0
^DetectedHeight=480
^OverscanH.=0.04
^OverscanV.=0.04
^BlockOptimization.=1
^AsoTV=1
^b_value.=0
^c_value=0.6
!SimpleResize.dll=C:\Arquivos de programas\DVD2SVCD\Avisynth2.5 Plugins\SimpleResize\SimpleResize.dll
!Decomb.dll=C:\ARQUIV~1\DVD2SVCD\AVISYN~1.5PL\InverseTelecine\Decomb.dll
!qmf15b1.avs=C:\Arquivos de programas\DVD2SVCD\Avisynth2.5 Plugins\FACAR\qmf15b1.avs
!QMF_functions.avs=C:\Arquivos de programas\DVD2SVCD\Avisynth2.5 Plugins\FACAR\QMF_functions.avs
!PreResize.avs=C:\Arquivos de programas\DVD2SVCD\Avisynth2.5 Plugins\FACAR\PreResize.avs
!FACAR.avs=C:\Arquivos de programas\DVD2SVCD\Avisynth2.5 Plugins\FACAR\FACAR.avs
:)
What are the important options for FieldDeinterlace?
FieldDeinterlace parameters:
- FieldDeinterlace(full, threshold, dthreshold, blend, chroma, debug). The default parameters correspond to FieldDeinterlace(full=false, threshold=15, dthreshold=9, blend=true, chroma=false, debug=false) or simply FieldDeinterlace().
- full (true/false) selects whether to process all frames or only frames that have been detected as being combed. The default is full=false which will only treat frames detected as being combed.
- threshold (0-255), dthreshold (0-255), blend (true/false), chroma (true/false) and debug (true/false) correspond to the respective functions in telecide.
Thanks :)
windtrader
9th December 2003, 20:08
At the risk of sounding like an idiot:
Is there any benefit of using FACAR if I use DVD2SVCD in DVD-DVD mode and play back the movies via a PC(RGB) based display device (CRT Front Projector)that is calibrated to display the full 720x480 picture?
I installed FACAR while using this great guide http://www.geocities.com/syzygydvd/help/index.htm to configure DS2RoBa with DVD2DVD.
I ran a test using the defaults and it narrowed the sides of the movie, leaving black bars so I went back and changed the overscan to 0. After running this test, the picture was full then I had one of those "duh" moments and figured out I was not using FACAR for its primary purpose. I figured I would go ahead and ask if there might be other less obvious advantages to include FACAR in my DVD reencoding process.
r6d2
9th December 2003, 20:53
Originally posted by windtrader
At the risk of sounding like an idiot:
The only stupid question is the one you keep to yourself because you're affraid to ask. ;)
Is there any benefit of using FACAR if I use DVD2SVCD in DVD-DVD mode and play back the movies via a PC(RGB) based display device (CRT Front Projector)that is calibrated to display the full 720x480 picture?
Even though FACAR is mainly oriented at eliminating overscan, yes, there are.
Even when you only crop the top and botton black bars, you save a significant amount of resizing area. When encoding to smaller frame sizes, this significantly reduces the time used by the resizing stage.
When encoding DVD2DVD (keeping frame size), resizing is neutral, so it will not be done and no overhead is saved (or produced).
However, if you encode the uncropped source straight with the original black bars, artifacts may appear in the black zone, and the black bars may end up being not so "black". Hard to notice, but noticeable at last. There is a thread showing that visually but I don't have the pointer at hand.
Keep in mind that if just one pixel gets grayed by a color conversion or other artifact, a full macroblock will be suboptimal and thus wasting bitrate.
FACAR also optimizes the macroblocks (at least one of the top and bottom borders), which provides some saving in bitrate, leaving more to increase the quality.
Besides that, FACAR provides some filtering capabilities which allow you to tune your encode.
Bottom line is, you lose nothing when using FACAR with DVD output, and you gain flexibility.
windtrader
10th December 2003, 00:55
Thanks.
However, if you encode the uncropped source straight with the original black bars, artifacts may appear in the black zone, and the black bars may end up being not so "black". Hard to notice, but noticeable at last. There is a thread showing that visually but I don't have the pointer at hand.
Great, now I'll start watching and analyzing the black bars too. I'll be committed if this gets out. :)
manolito
21st December 2003, 18:34
Sometimes those real widescreen 2.35:1 Cinemascope films look just too flimsy on a regular 4:3 TV set. You give up more than half of your screen real estate which makes the movie look very distant. If you convert these films to 1.85:1 you will lose some movie information from the outer edges, but in many cases the movie will look much better, because it seems with this "zooming in" the emotional impact is a lot higher.
In the D2S FAQ at http://forum.doom9.org/showthread.php?s=&threadid=21859 you can find a method to do this conversion, but this only works with the standard D2S resizer scripts. In a previous post r6d2 explained how you can do the same thing with FitCD, but he also said that he is not ready to implement this into FACAR.
I thought of implementing this "4:3" mode in FACAR, as it was one of gerti67's ideas on the ToDo, but I didn't because IMHO, it sucks.
I do agree with r6d2 that converting a 1.85:1 film to 4:3 does not make much sense in most cases, but converting 2.35:1 to 1.85:1 is not a bad idea at all IMHO.
Anyway, I could have used the method from the D2S FAQ or FitCD, but somehow I have become a real FACAR addict. All the scripts in my AVISYNTH.INI have been modified to work with the latest FACAR, so I really wanted to make this conversion work with FACAR. I first thought I would just modify FACAR.AVS to implement this thing, but after trying to analyze it I quickly decided not to mess with it. (I am not a "real" programmer after all) :o
What I came up with is just a two line quick and dirty script which can be imported into the D2S FACAR script just before FACAR.AVS. It automatically determines if the output is PAL or NTSC (stolen from FACAR.AVS) and changes the DestinationHeight variable accordingly. The clip is cropped with the appropriate values before turning over control to FACAR.
This method only works with anamorphic sources. Supported target resolutions are SVCD, CVD and DVD. VCD definitely does not work.
Usage:
Paste the two lines into an editor and save it as "235to185.avs" to your FACAR folder.
235to185.avs
------------------------------------------------------------------------------------------------
DestinationHeight = (DestinationHeight % 288 == 0) || (DestinationHeight % 216 == 0) ? 576 : 480
Crop(90,0,540,DestinationHeight)
------------------------------------------------------------------------------------------------
Start DVD2SVCD, go to the Frameserver tab and select the FACAR script. Click "Edit Avisynth script" and insert the following line just before the "Import(!FACAR.avs) line:
11=# Import(!235to185.avs)
Click OK, then scroll down to the "Import" line you just inserted and enter the correct path to "235to185.avs". Close DVD2SVCD to save the changes you just made.
To activate the conversion all you have to do is to uncomment the "Import" line for 235to185.avs.
Of course it would be much more elegant if this method was implemented right into FACAR. Maybe if some forum members find this useful r6d2 might change his mind ??? :cool:
Cheers
manolito
r6d2
22nd December 2003, 17:06
Thanks, manolito. I'll try your stuff and see if it fits easily into FACAR, but not now because I'm finishing some projects and have little spare time.
Holomatrix
22nd December 2003, 17:48
I would second that request :) I too really hate those 2.35:1 films.
manolito
22nd December 2003, 18:41
I would really appreciate if some people tried this little script with various sources and gave me some feedback if it works in all cases. I only own one NTSC DVD, all the rest is anamorphic PAL, so I cannot be totally sure if the PAL/NTSC detection works all the time.
@r6d2
If you find the time it would be very nice of you to review the logic of the method. I only change the value for "DestinationHeight" and let FACAR do its thing afterwards. I am not messing with "NewDestinationHeight" at all, so I am not sure if my script really keeps the correct aspect ratio. The encodes I did with it look OK though.
r6d2
4th February 2004, 16:39
Hi, guys,
Just a note to tell you I found an irritating bug in FACAR. It only affects Anamorphic movies which have a high "height". The OverscanH crops too much in ASOTV mode (the default). I'll fix it ASAP, but wanted to warn you anyway.
Workaround: set OverscanH to 0 for the time being when source is Anamorphic and detected height is above 448 (in NTSC).
r6d2
8th February 2004, 23:36
New features/fixes:
# v1.06.7
# - Added corrected aspect ratio in preview mode for PAL (now both NTSC and PAL supported).
# - Fixed OverscanH bug of cropping too much top&bottom on "high" anamorphic movies (DetectedHeight > 448 in NTSC).
# - Changed default values for Overscan to 5%.
P.S.: I've not forgotten the 2.35/1.85 thing. Not working on it right now but I'll keep you all posted.
homerjay
9th February 2004, 17:12
ive been quiet for a while but got to say thanks for all your continued improvements to this excellent plugin :)
manolito
9th February 2004, 22:29
Thanks r6d2, version 1.06.7 works perfectly.
I wouldn't bother about integrating the 2.35 to 1.85 conversion thing into FACAR. There probably are not too many people who actually need it, and then it already works quite well as it is. Installation is far from elegant, but you only have to do it once. What concerns me a lot more is that it raises your Q by about 85%, so CVD resolution and/or heavy filtering (or more blanks) are required.
r6d2
9th February 2004, 23:15
Originally posted by manolito
What concerns me a lot more is that it raises your Q by about 85%, so CVD resolution and/or heavy filtering (or more blanks) are required.
Well, it does increase the Q of course, since there is more film pixel to encode.
On another topic, I've been doing some tests lately with the ResizeTo variable. I set it to 6 for 704x480 (so it keeps almost all the source). Surprisingly enough, this increases the sharpness a lot and does not significantly increase the Q, provided you use KISS.
But I'll post some results on this soon. It may be a better way to increase quality than just lowering the Q.
r6d2
14th February 2004, 17:34
It would be very helpful if some PAL users could post their results with the PAL aspect ratio feature, since I don't have PAL sources to test it very much.
puddy
16th February 2004, 03:31
First, thanks for the work you put into this. :)
My source is captured NTSC at 29.97 352x480, Interlaced, AVI with Huffy.
I want my output to be NTSC 29.97 352x480 Interlaced MPEG2 (exactly
the same) except I want the overscan removed.
But, I can't seem to make this happen. I mean, the overscan gets removed, but the video is stretched like silly putty from left to right. Smack down the middle the video is the same. As it moves to the left and right it is streched.
Here's 3 screen shots of a test clip:
1. Original AVI as viewed in Vdub.
http://stuff.wso.net/images/max/max_orig.jpg
2. Converted FACAR MPEG as viewed in VdubMod.
http://stuff.wso.net/images/max/max_facar.jpg
3. This is how I'd like the end result to look.
http://stuff.wso.net/images/max/max_desired.jpg
My goal is to capture VHS video and burn it to DVD as
half size DVD spec (CVD size). I've done it many times
already but I wanted to squeeze a little more out and
thought taking out the overscan would be good.
Oh, forgot to post my settings/logs which produced #2 above:
--------------------------------------------------------
- 2/15/2004 8:13:16 PM
- AVI to SVCD Conversion
- AVI2DVD ver. 1.2.1 build 3
--------------------------------------------------------
Initializing
- E:\max_manners1.avi
Initializing finished.
--------------------------------------------------------
- 2/15/2004 8:13:18 PM
- Free on drive D: 11880.66 mb
- AUDIO Extraction
--------------------------------------------------------
Audio extraction finished.
--------------------------------------------------------
- 2/15/2004 8:13:27 PM
- Free on drive D: 11864.15 mb
- AUDIO conversion
--------------------------------------------------------
--------------------------------------------------------
- 2/15/2004 8:13:28 PM
- Free on drive D: 11864.15 mb
- AUDIO conversion
--------------------------------------------------------
Encoding Audio. Filename: D:\DVD2SVCD\audio\Extracted_audio_1.wav
Executing BeSweet. Commandline:
"C:\Program Files\DVD2SVCD\BeSweet\BeSweet.exe" -core( -input "D:\DVD2SVCD\audio\Extracted_audio_1.wav" -output "D:\DVD2SVCD\audio\Encoded_audio_1.mp2"
-logfile "D:\DVD2SVCD\audio\Encoded_audio_1.log" ) -ota( -g max -r 29971 29970 ) -shibatch( --rate 48000 ) -2lame( -e -b 192 -m s )
Audio conversion of D:\DVD2SVCD\audio\Extracted_audio_1.wav finished.
Audio conversion finished.
--------------------------------------------------------
- 2/15/2004 8:13:40 PM
- Free on drive D: 11862.08 mb
- Video Encoding using Cinema Craft
--------------------------------------------------------
Executing Cinema Craft Encoder.
StreamSectors: 4651455788
AudioSectors: 2363508
VideoPAPO: 72016920
ScanOffsetBytes: 4052
SeqAligningBytes: 257495
DVDBytes: 0
VideoEndHeader: 4
SubtitleSectors: 0
EmptySectors: 238.00
PictureSectors: 0.00
PureMPEGStream: 4576813809.17
Seconds: 97.12
CalcMPEGStream: 4576813809.17
Frames: 2701
CDSize: 4450.00
Number of CDs: 1
Cut point 4446.00
Variable Settings:
Frames: 2701
Anti Noise Filter: Off
Passes: 4
Image Quality: 10
VAF file creation: On
Video Encoding Mode: One Pass VBR
Q. Factor: 5
Min. bitrate: 2000
Max. bitrate: 7200
Aspect Ratio: 4:3 (No borders, encoded as 4:3)
---AVS Begin---
LoadPlugin("C:\PROGRA~1\DVD2SVCD\AVISYN~1.5PL\Mpeg2dec\MPEG2D~1.DLL")
AVISource("E:\MAX_MA~1.AVI",False)
ConvertToYUY2(interlaced=true)
AssumeFPS(29.970,True)
ResizeTo=0 global ResizeMethod=4 DebugMode=0
GammaCorrection=1.0 Hue=0 Saturation=1.0 Brightness=0 Contrast=1.0
DetectedTop=0 DetectedHeight=480
OverscanH=0.04 OverscanV=0.04 BlockOptimization=0 AsoTV=1
global Bicubic_b_Value=0 global Bicubic_c_Value=0.6
DestinationWidth=352
DestinationHeight=480
DestinationTop=0
DestinationBottom=0
LoadPlugin("C:\Program Files\DVD2SVCD\Avisynth2.5 Plugins\SimpleResize\SimpleResize.dll")
# Import("C:\Program Files\DVD2SVCD\Avisynth2.5 Plugins\FACAR\qmf15b1.avs")
# Import("C:\Program Files\DVD2SVCD\Avisynth2.5 Plugins\FACAR\QMF_functions.avs")
# Import("C:\Program Files\DVD2SVCD\Avisynth2.5 Plugins\FACAR\PreResize.avs")
Import("C:\Program Files\DVD2SVCD\Avisynth2.5 Plugins\FACAR\FACAR.avs")
# Import("C:\Program Files\DVD2SVCD\Avisynth2.5 Plugins\FACAR\PostResize.avs")
----AVS End----
Closing program
CCE Max Speed: 1.580
Video Encoding finished.
--------------------------------------------------------
- 2/15/2004 8:15:23 PM
- Free on drive D: 11771.63 mb
- Converting Pictures from ES to PS
--------------------------------------------------------
Saving bbMPEG settings: C:\Program Files\DVD2SVCD\bbMPEG\default.ini
--------------------------------------------------------
- 2/15/2004 8:15:26 PM
- Free on drive D: 11771.63 mb
- Converting Pictures from ES to PS
--------------------------------------------------------
Saving bbMPEG settings: C:\Program Files\DVD2SVCD\bbMPEG\default.ini
--------------------------------------------------------
- 2/15/2004 8:15:28 PM
- Free on drive D: 11771.63 mb
- Converting Pictures from ES to PS
--------------------------------------------------------
Saving bbMPEG settings: C:\Program Files\DVD2SVCD\bbMPEG\default.ini
--------------------------------------------------------
- 2/15/2004 8:15:31 PM
- Free on drive D: 11771.63 mb
- Multiplexing and cutting
--------------------------------------------------------
Saving bbMPEG settings: C:\Program Files\DVD2SVCD\bbMPEG\default.ini
Offset in Seconds: 0
Executing bbMPEG.
Variable Settings:
Cut point: 4446 mb
Executing RunbbMPEG. Commandline:
"C:\Program Files\DVD2SVCD\bbMPEG\RunbbMPEG.exe" "D:\DVD2SVCD\muxed\bbMPEG_Muxed_File.mpg"
Multiplexing and cutting finished.
Image creation finished.
--------------------------------------------------------
- 2/15/2004 8:15:47 PM
- Free on drive D: 11678.10 mb
- Conversion done!
--------------------------------------------------------
Thanks!
puddy
r6d2
16th February 2004, 03:48
@puddy,
On its current form, FACAR is only good for DVD sources, sorry.
However, eliminating overscan for a source like yours should be easy. Try adding this line to your AVS script in DVD2SVCD (remember to select CVD output):
Letterbox (http://www.avisynth.org/index.php?page=Letterbox)(16,16,16,16)
This will eliminate 2 blocks of overscan on each side, and top and bottom, which is more or less what FACAR would do.
puddy
16th February 2004, 17:45
Thanks! I'll probably use Letterbox(8,8,8,8) since my resolution is half that of DVD. 16 will show black around the edges, just slightly, on a Sony WEGA at 352x480.
Thanks again!
puddy
r6d2
16th February 2004, 18:33
Originally posted by puddy
16 will show black around the edges, just slightly, on a Sony WEGA at 352x480.If you want to measure the overscan of a NTSC TV you might want to try Overscan 1.1 (http://www.geocities.com/r6d2_stuff/). In most TVs overscan is 4-6%, so 2 blocks each side should be OK IMHO for CVD, but the best thing it to measure it. Good luck!
lordkinbote
19th March 2004, 01:21
In an attempt to clarify my FACAR cropping issues I'm giving example measurements of an AVI of a WS TV show I'm about to encode. All of these measurements are from the Preview windows for both FACAR in Debug mode 1 and AutoFitCD. Oh, by the way, I was mistaken in saying the sides/Vertical measurement would go to 432 when going down 2 sizes in AutoFit. 432 is perfect for my TV (it has HUGE overscan), instead going down two sizes brings the Vertical to 416. THAT is too much. I got it to 432 by changing the Blocks TV-Overscan setting to 3 instead of the default 2. Anyway here are the measurements between the two.
The original source AVI's size is 624x352.
In AutoFitCD, with 3 Blocks TV-Overscan and 16 block optimization, it crops to 618x352 and resizes to 432x336.
FACAR has this info in Debug mode 1:
Crop (36,8,552,344)
Resize (432,344)
Borders (24,72,24,64)
If I'm understanding this correctly, according FACAR's cropping, it's cutting off much more from the sides (552 as opposed to 618 with AutoFit). This is why the CBS logo is much closer to the edge of the screen. My goal is to try to set FACAR up so the resulting cropping and resizing are closer to AutoFitCD's results. Changing the overscan V & H settings don't seem to change the results of the cropping, only the transparency overlay and that lines up perfectly with my .03 OverscanH and .05 OverscanV. If you any suggestions, r6d2, that would be great. Thanks.
r6d2
19th March 2004, 02:06
Seems my readme is not good enough after all since it has not transmitted to you FACAR's leit motiv. ;)
You cannot mimic FitCD with FACAR. You can, however, mimic FACAR with FitCD.
FACAR is powerful, but restricted to a single purpose: "As seen on TV" mode. The idea is to have an image exactly equal to what you get to see when using the original DVD. Since the overscan is on an hidded area, FACAR just eliminates that source part to save bitrate for the rest.
If you want to keep more of the source than what you get on the original DVD, FitCD is the way to go. In fact, I recommend FitCD for full screen 16:9 (anamorphic) sources for plain full screen 4:3 sources, since using FACAR you lose a great deal of picture pixel.
Full screen sources (in which by definition DetectedTop=0 and DetectedHeight=480/576), don't really require FACAR functionality. (You see why?)
Now back to the point. You can mimic FACAR with FitCD by letting target height be equal to the source height. There is an arrow pair to do this. Just make sure to set rounding to 2 instead of the typical default of 16.
On FitCD overscan must be set manually or each selected output frame size, though, and it has a limit of 3 blocks per side.
On anamorphic sources, let height be 3/4 the original height of the film pixel. Try it.
If you need help let me know.
lordkinbote
19th March 2004, 06:03
D'oh!
well, I'll use FitCD for WS AVI's then 'cause I do want to keep as much of the actual video picture as possible. I understand, now, that FACAR is used to crop the overscan and use the extra bitrate on what's left, but I guess I had it in my mind that it was resizing more than cropping. It's stuff that I would've missed anyway, I guess, but now it bothers me thinking I missed something. I love FACAR for the fully automated quality because, well, I'm a lazy bastard.:D But, I know it would bother me more to know I'm cropping off the sides. Not dissin' FACAR, just AutoFitCD seems to be more of what I'm looking for.
I don't really understand exactly what you mean by FACAR not being needed if the Height is 480.
windtrader
19th March 2004, 21:55
FACAR is powerful, but restricted to a single purpose: "As seen on TV" mode.
Humm.. I use FACAR all the time but have the overscans set to 0. I thought FACAR would clean up the video that is not fully using the 720x480 NTSC field and resize it to fit the full size. I also thought on any anamorph DVD with an AR greater than 1.78:1, FACAR optimizes the encoding by eliminating any processing in the black bar areas.
So, I figured using it was getting me the DVD frame filled and saving time due to no black bar processing. Am I out in space? :(
lordkinbote
20th March 2004, 00:00
@windtrader
Well, that is my understanding now.
I was hoping that when I cropped and resized to get rid of my overscan, it would do more resizing than cropping. But it seems to crop quite a bit more than AutoFitCD, which does more resizing. This is more to my advantage since I have a large overscan and don't want to permanently get rid of more picture. If and when I get a service manual and get around to adjusting my TV's geography to get rid of the overscan, I will use FACAR again in the same way you do.
r6d2, correct us both if we're wrong about this, please.
r6d2
20th March 2004, 02:15
Well, you both have the general idea, but I'd rather rephrase it to look simpler, if possible.
What FACAR does is to crop only the "visible film pixel", exactly the same that your TV does. This optimizes the encode because the resizer only works with relevant data, this is only the film pixel and not the black bars. This saves a lot of time, the most as the movie is more wide than tall.
Then FACAR adds the black bars to complete the output frame size selected, so the encoder gets the whole picture, but in much less time.
Any statement about FitCD being more resizer-oriented or FACAR being more cropping-oriented is inaccurate. When fed with the same input, both produce the same output and hence the same optimization level.
The only difference is that FACAR does it always the same way, whereas FitCD lets you play with resizing to keep more or less film pixel. FACAR does not since its purpose is, as stated above, to mimic the TV cropping on the original source.
Don't worry, if you set your Overscan to 0, you still get the top/bottom black bar optimization with FACAR.
If still unclear, please just ask.
lordkinbote
20th March 2004, 02:21
That helps me understand a bit more. Some things take a little bit of time to sink in with me.:( It becomes clearer every day.
bobwillis
24th March 2004, 08:42
Hi r6d2,
I have noticed a few occasions where "FACARDetectBorders" has determined that the left hand side of the frame is 2. However, I can see (in the preview window), picture information to the left of the vertical white line in pixels 0 & 1. This is no big deal (2 pixels), but I thought I'd let you know about it.
Regards,
Bob
r6d2
24th March 2004, 12:26
Originally posted by bobwillis
This is no big deal (2 pixels), but I thought I'd let you know about it.I've seen this from time to time. It has something to do with interlaced frames I think. However, width errors are completely irrelevant since the sides cropping is done based on the overscan setting. Don't worry.
If you experience top and bottom errors, you may want to play with the threshold parameter of "FACAR Detect Borders", but then again, width detection it is not really relevant to the output script.
homerjay
25th April 2004, 23:40
hi there have just had to reinstall dvd2svcd etc and noticed an error i didnt use to have in version 1067 as below ( i think i originally installed it to a subfolder of itself so was always using the previous version )
i dont know what "destinationtop" means
e:\dvd2svcd\avisynth2.5 Plugins\Facar\FACAR.avs, line 136
have searched the FACAR.avs file and dont see any other reference to it other than line 136
could you please point me to what im sure is an obvious oversite by me
thanks
edit - knew it was an oversite the FACAR folder and a new avisynth.ini it :o merged with the original and now all sorted :rolleyes: :o
jorel
12th June 2004, 01:06
r6d2,
i don't use tweak. have a way to remove that filter from FACAR? i know that using the defaults in tweak don't change the image but(i think) that if the filter can be removed from the script maybe it can run faster...or is my mistake? it's a newby question of course but i have my doubts.
in the FACAR readme explain about GammaCorrection. is used the built in dvd2avi or the levels from avisynth?...and why GammaCorretion is in 1.0 if the default is 0.0?
i like to use "kiss" filter like that in d2s:
undot()
lanczosresize(.....)
deen()
using "kiss" in FACAR,where i put this filters using the same sequence like i posted? means undot before resize and deen after resize.
thanks in advance! :)
r6d2
12th June 2004, 02:03
Originally posted by jorel
i don't use tweak. have a way to remove that filter from FACAR?I don't think that eliminating that script line will improve speed. Anyway, you're welcome to try. Just open FACAR.avs and comment out this line:
((Hue <> 0) [...]) ? Tweak(Hue, Saturation, Brightness, Contrast) : NOP()by prepending a '#'.
in the FACAR readme explain about GammaCorrection. is used the built in dvd2avi or the levels from avisynth?...and why GammaCorretion is in 1.0 if the default is 0.0?AviSynth, and actually the default behaviour of the Levels functions is to do nothing if GammaCorrection is 1, not 0. You can check that here (http://www.avisynth.org/index.php?page=Levels). In other words, don't worry. Levels will only be invoked if you change the GammaCorrection value to other thing than 1.0
i like to use "kiss" filter like that in d2s:
undot()
lanczosresize(.....)
deen()Put Undot() in Preresize.avs and Deen() in Postresize.avs. Then just make sure both lines are uncommented in DVD2SVCD AviSynth script editor.
It is likely that Debug mode won't work if you do this though, but in normal operation it should. Please report back if it doesn't.
jorel
12th June 2004, 02:18
i will report all after tests include the comment in tweak if it turn the script faster.
very clear, thanks for all explanations, recomendations and hints! :)
jorel
12th June 2004, 05:40
r6d2,
like you "preview", don't have differences in quality or time to encode using the " # " eliminating tweak from the script in my sample test ( ~ 01minutes:22seconds vob),...just the same with or without tweak(in default values,of course)!
using Undot() in Preresize.avs and Deen() in Postresize.avs worked like a charm....and :o forgive my "old" question cos i read the FACAR readme "too fast" and without atention(sorry)before ask you and there is very clear about "<iii>. Additional filtering" and with details about kiss "filter".everything is clear in the readme.
thank you very much r6d2, FACAR stills "turbo"! :)
Monkeychops
14th June 2004, 17:53
I've been using FACAR for a couple of encodes and it seems to save me bitrate, but at the risk of sounding stupid, can I ask a couple of questions?
1) My understanding from reading the script is FACAR works out what area of the frame you won't see by examining the overscan. It then chops this portion off and adds a border to keep proper frame size. Correct?
2) If 1) is true, is the advantage on a full height movie coming only from chopping the unseen parts off (no visible borders)?
3) I was interested in seeing just how much of the frame is lost when viewing on TV, but FACAR shows what will be encoded post cropping and overlaying additional lost area to overscan so it's hard to judge what is missing.
I've played with the script a little and come up with the following:
Targetpre = AddBorders(1, 1, 1, 1).bilinearresize(DestinationWidth,DestinationHeight)
# --(r6d2)-- Calculate BlocksToCrop based on Overscan parameters.
# --(r6d2)-- Add the overscan overlay to the given clip in transparency mode
# (Target clip must already be properly cropped, resized and bordered.)
DebugTarget = ConvertToRGB32(Targetpre) # use RBG32 for Layer()
[Additions / changes from original script in RED/ BLACK text shows relative position]
Does this do what I want it to do; ie take the original clip and overlay a border showing everything that will be lost?
Forgive me if it doesn't but I don't know much about Avisynth, but like understand the whole process
r6d2
14th June 2004, 18:33
Well, sort of. But it should be easier than that. What FACAR does is to take Overscan percentages as input parameters and crop out the unseen area, thus saving the BR that it would take to encode the whole original picture frame.
If you would like to see how much is being cropped, use Debug mode (set it to 3, for example) and an overlay margin in blue will be shown along with the cropped picture. Currently there is no way to see how much will be cropped together with the original (uncropped) picture, but it sounds like a good idea. I cannot test you your modifications now but I'll look at them later to see if they add the desired effect.
Monkeychops
14th June 2004, 21:23
Thanks for the reply.
No sweat on checking my alterations; for my own amusement as anything else.
jorel
14th June 2004, 23:12
r6d2,please,take a look in this pictures:
http://img12.imageshack.us/img12/6758/fitcdoverscan1.jpg
http://img18.imageshack.us/img18/3848/fitcdoverscan3.jpg
see that the first picture using fitcd overscan1,show the same as the second picture form fitcd overscan3...same details within the borders without loose parts of the scenes(pictures)
now see that using Facar:
http://img12.imageshack.us/img12/9291/facar1.jpg
see that i'm loosing part of the picture within the borders(the chickens on the left and in the right are loose).what can i do to get the same as from fitcd overscan3 in Facar without loose part of the picture within the borders?
thanks in advance!:)
r6d2
15th June 2004, 02:37
Originally posted by jorel
what can i do to get the same as from fitcd overscan3 in Facar without loose part of the picture within the borders?Well, my friend, you are missing the whole point of using FACAR. If you want to keep all the source pixel, you have to use FitCD Overscan 3 (or whatever value suits you).
FACAR is useful if you want to encode in "As seen on TV" mode.
jorel
15th June 2004, 03:28
is true .
and see my point of view r6d2. what i gain in the right/left using fitcd overscan(1,2 or 3)i loose in the top bottom. compare the size of the top bottom of Facar...have less black bordes and with fitcd overscan have more in top bottom. means that with overscan i don't get real gain and the right/left from Facar the tv(4:3) don't show....resuming my "explanation":
fitcd overscan ---> less black borders in right/left(that are invisible in tv,then are irrelevants) from fitcd overscan and true loose in top/bottom(too big black borders)
you loose more in top/bottom than gain in left/right.
FACAR ---> less black borders in top/bottom with facar(the real gain)and "invisibles" left/right borders in tv!
ps: in the end what someone can think or feel as "loose" using Facar is the "true gain"!
that pictures are some more prooves,only need atention in all details!
i was clear?
big thanks! :)
edited>
r6d2, my good conclusion and personal taste about your great job is posted in the last post of that page and in the first 2 posts in the next page (more will be posted later): http://kvcd.net/forum/viewtopic.php?t=11640&postdays=0&postorder=asc&start=0
manolito
23rd June 2006, 14:39
Anyone still using FACAR? I certainly do for my AVI2DVD conversions. Very convenient for cropping off station logos and playing with different filters and resizers.
AviSynth 2.56 introduced two new resizers: GaussResize and SplineResize. A sharper version of LanczosResize (called Lanczos4Resize) is also included. So I decided to modify FACAR to support Lanczos4Resize and Spline36Resize. If anyone is interested, you can download the modded version at
http://scifi.pages.at/manolito/FACAR/FACAR_Update_1.06.8.zip
ResizeMethod=6 is Lanczos4Resize, ResizeMode=7 is Spline36Resize. The debug modes for previewing the different resizers are also modified to display 6 resizers now instead of 4.
Cheers
manolito
homerjay
3rd July 2006, 20:38
im still using it for the very same purpose :)
is there any significant improvement ?
manolito
10th July 2006, 22:33
is there any significant improvement ?You have to play with the new resizers to find out if the improvements they offer are "significant" for you or not. For my purposes LanczosResize is all I need, but Lanczos4 and Spline36 certainly have their merits. I did not change anything in FACAR itself, I just added the new resizers.
Cheers
manolito
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.