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. |
|
|
Thread Tools | Search this Thread | Display Modes |
15th December 2010, 14:38 | #21 | Link |
Registered User
Join Date: Feb 2010
Location: New York
Posts: 116
|
Ooh, thank you again! I see your script is using some of the values listed in these conversion tables. Through reading several aspect ratio threads here on Doom9, I was led to that page some months ago, and had planned to use those numbers instead of what I've got now, but I believe I had some sort of issue with the way I was rounding certain values at certain points in the script (that, and I couldn't find anything about widescreen ratios on that page; I just decided to stick with what VirtualDub uses in its preview pane context menu).
It's been a while since I've tested that, however, so I should probably revisit the subject. It may take a bit, though, since I'm just in the process of finishing up my first proper plugin. It turns an input clip into a mosaic built out of pieces of a custom tilesheet that you supply. Mock up a sheet of solid colors, gradients, ASCII text, whatever you want, tell the plugin the tile dimensions, and it does the rest, picking tiles according to the channel of your choosing. Nothing mindblowing, but fun to play with, and has helped me focus my efforts to learn C++. Should be finished in a few days. |
15th December 2010, 15:39 | #23 | Link |
Registered User
Join Date: Feb 2010
Location: New York
Posts: 116
|
Ah. Well then. "Looks like they know what they're talking about" is as dangerous as I thought it was, after all.
Am I to take it the values I'm using now (10:11 and 40:33 for NTSC DV and NTSC DV wide, 12:11 and 16:11 for PAL DV and PAL DV wide) are accurate? |
16th December 2010, 16:31 | #25 | Link | |
Registered User
Join Date: Dec 2002
Location: UK
Posts: 1,673
|
Quote:
Anyway, we've discussed this before... http://forum.doom9.org/showthread.ph...30#post1072530 ! There are several other threads, e.g. this lists the PARs etc... http://forum.doom9.org/showthread.ph...77#post1451277 Cheers, David. |
|
19th December 2010, 19:10 | #26 | Link |
Anime addict
Join Date: Feb 2009
Location: Spain
Posts: 673
|
Hi, i have been testing this filter and i obtein that results:
Original video DVD-NTSC 720x480, PAR=10/11, DAR=3:2 Original video DVD-NTSC 640x480, PAR=1:1, DAR=4:3 Video upscale Option 1 Size 1440x1080p, PAR= 1:1, DAR=4:3 Code:
AssumetFF() SimpleSlugUpscale(widein=false,size="1080pana") In this case, the image is cropped at the top and bottom Video upscale Option 2 Size 1440x1080p, PAR= 1:1, DAR=4:3 Code:
AssumetFF() SimpleSlugUpscale(widein=true,size="1080pana") In this other case, the image is cropped at the left and right Video upscale Option 3 Size 1440x1080p, PAR= 1:1, DAR=4:3. In this case, Im looking for the original image without crooping but upsize. Code:
AssumetFF() SimpleSlugUpscale(widein=true,size="1080pana", parIn=1.185) or SimpleSlugUpscale(widein=false,size="1080pana", parIn=1.185) The result for me is nice, however I dont know because autocrooping when the Par Input video not is 1.185 but is 10:11. All of modes, if i specify in argument ParIn a fraction (i.e 32/27), the result is wrong. It seems as if the function to return the truncated value of the fraction, that is 1. Last edited by Overdrive80; 19th December 2010 at 19:19. |
19th December 2010, 19:26 | #27 | Link | |
Registered User
Join Date: Feb 2010
Location: New York
Posts: 116
|
Quote:
Update, I think I see the cause of your other problem here: you're using the 'size' preset of 1080pana ("1080p anamorphic"), which has a pixel aspect ratio of 4.0/3.0 and a display aspect ratio of 16.0/9.0. If you want 1440x1080 output with a 1:1 pixel aspect ratio, you'll need to define it by hand. There are a few ways to achieve the result you're after: First, you can keep the 1080pana preset, but define your own output pixel aspect ratio: Code:
SimpleSlugUpscale(size="1080pana",PARout=1.0) Second, if you prefer, you could always define your own dimensions: Code:
SimpleSlugUpscale(outwidth=1440,outheight=1080) Last edited by Robert Martens; 19th December 2010 at 19:37. |
|
19th December 2010, 19:46 | #28 | Link | |
Anime addict
Join Date: Feb 2009
Location: Spain
Posts: 673
|
Quote:
With scripts of you last post, the resulting video is autocrop too, and I want to keep with the original image with the band black. So the only way to get it to assign the ParIn. It is my opinion but I think if you rescale the video it would not crooping the video. I do not want to offend you, its great contribution. ^^ eDIT: I think that PAR NTSC is 4320/4739 Last edited by Overdrive80; 19th December 2010 at 20:06. |
|
19th December 2010, 20:12 | #29 | Link | |
Registered User
Join Date: Feb 2010
Location: New York
Posts: 116
|
Quote:
Using the first screenshot, original.jpg, I can see the cropping you describe, but I believe the problem here is the fact that NTSC video, at 720x480 and a pixel aspect ratio of 10.0/11.0, actually has a display aspect ratio of 15:11, which is slightly wider than 4:3, which means a certain amount of cropping is to be expected. I had planned to offer a parameter named 'DARin', to let people more easily handle situations like this without requiring you to calculate an appropriate input pixel aspect ratio, but I ran into some sort of problem that I can't recall off the top of my head. The variable actually exists internally, but something went wrong when I tried exposing it as a parameter. I'm still finishing up that plugin I mentioned a few posts ago, but once it's done and made public I'll get back to work on this script. If I review my work with a fresh perspective I might see a way around whatever issues I ran into last time. I used to think the same thing, but it seems we're wrong: the topic actually came up at the top of this page, check the links 2Bdecided mentioned to find out more. |
|
19th December 2010, 20:26 | #30 | Link |
Anime addict
Join Date: Feb 2009
Location: Spain
Posts: 673
|
Well, I have the video and cant do it as you said. However, i redefined variables
cropwidth = 0 cropheight = 0 cropleft = 0 croptop = 0 As they say in my country, its to kill a fly with a cannon, but for now I serve. Thanks Robert. EDIT: Without redefined variables, with this code I got what I wanted. Simply, firs resize and after upsize ^^ Code:
Spline36Resize(720,540) AssumetFF() SimpleSlugUpscale(size="1080pana", parout=1.0) Last edited by Overdrive80; 19th December 2010 at 21:15. |
20th December 2010, 02:13 | #31 | Link |
Anime addict
Join Date: Feb 2009
Location: Spain
Posts: 673
|
I hope that it, could be interesting. ^^ http://en.wikipedia.org/wiki/ATSC_Standards
|
17th February 2011, 08:41 | #32 | Link |
Registered User
Join Date: Feb 2010
Location: New York
Posts: 116
|
Just to get it out of the way up front: I'm not sure if this issue deserves its own thread, but I noticed while working on the 1.10 update that FindStr() is case sensitive. I've found this to be true in 2.5.6, 2.5.7, 2.5.8, SEt's 2.5.8MT, and the September 27th, 2009 2.6.0 alpha. I imagine the behavior may be intentional, but the documentation and wiki show an example, searching the string "AviSynth" for the string "syn" and getting a return value of 4, that doesn't actually work. Can anyone confirm whether it's a bug in the software or an oversight in the docs?
With that out of the way: SimpleSlugUpscale 1.10 Despite the time gap since 1.02, this doesn't represent three months worth of work. It's more like two and three quarters being distracted by other obligations and one week of scripting and testing, but I managed to add a few useful things: -I took a look at what I'd mentioned to Overdrive80 earlier, and sure enough, it was only a matter of coming back with a fresh perspective. After a moment pondering a chicken-or-egg dilemma I managed to get DARin working, so now if you want to force SimpleSlug to treat your footage as a certain shape, you no longer need to figure out the pixel aspect ratio (though that's still an option). Revisiting the example Overdrive posted, this syntax can now be used in lieu of my earlier suggestions: Code:
SimpleSlugUpscale(outwidth=1440,outheight=1080,DARin=4.0/3.0) -I adjusted 'shtrhack' a bit to allow rudimentary usage of QTGMC's motion blur system. The settings of true and false still work as they did in past releases (Merge and SelectEven, respectively), but now you can also set the variable to the string "QTGMCdefault", which will turn on motion blur in QTGMC, though only using its defaults. I didn't want to get too crazy with extra parameters here, so if you want finer control over the settings, keep shtrhack set to false and pass in your own 'qual' string. For example: Code:
SimpleSlugUpscale(qual="QTGMC(MotionBlur=3,ShutterAngleOut=360)") Nothing major beyond that, I'm afraid. Some grammar cleaned up, typos fixed, I added some more whitespace to make the script easier to follow, but that's about it. I've got some ideas for future releases, and I'm excited to get to work, but it'll take me a while to slog through them, and I figured I should get this out as soon as possible. Last edited by Robert Martens; 5th March 2011 at 20:14. |
17th February 2011, 18:41 | #33 | Link | |
Avisynth language lover
Join Date: Dec 2007
Location: Spain
Posts: 3,431
|
Quote:
I imagine it has always been that way - whether by design or by oversight, I dont know. It certainly seems inconsistent with the string comparison operators ("==", etc), which are not case-sensitive. And, as you say, it does not match the example in the docs. Perhaps you should start a new thread in the Development forum to discuss this. |
|
5th March 2011, 20:20 | #34 | Link |
Registered User
Join Date: Feb 2010
Location: New York
Posts: 116
|
SimpleSlugUpscale 1.11
Quick update to account for renamed parameter in QTGMC 3.20, made an improvement to one internal variable whose inefficiency was revealed by said QTGMC, and tidied up the presentation of my one try...catch block. Hey, a post that's not "War and Peace"! Nice change of pace for me. |
5th March 2011, 22:20 | #35 | Link |
Registered User
Join Date: Jul 2010
Posts: 448
|
Wow, you caught that variable name change quickly! I don't usually like to change setting names, but I was getting queries from people expecting major streaks of motion blur from that MotionBlur setting. Figured it was still new enough to change, although I did realize it would affect your script...
I notice that you've flagged the possibility of QTGMC global variable clashes if people use QTGMC in your 'bgargs' setting. You might want to note that adding the setting PrevGlobals="Replace" to QTGMC will prevent any such clashes. Is it worth adding that setting to your own QTGMC calls? I guess it depends on when bgargs is called compared to your script calls. This kind of thing did worry me when I added this use of globals, but I am intending to use the system as an integral part of the QTGMC process soon (which is why the globals are not optional). I'm hoping actual problems are rare and the mechanisms I've provided will work around any that crop up. Last edited by -Vit-; 5th March 2011 at 23:04. |
5th March 2011, 22:49 | #36 | Link | ||
Registered User
Join Date: Feb 2010
Location: New York
Posts: 116
|
Quote:
Quote:
As for adding the setting to my own calls, there's really only the possibility for two now. Something I realized when testing QTGMC 3.20 is that my internal 'bobbed' variable was being generated even if the user asked for a boxed output size (which would ignore 'bobbed' at the top level SSU and generate the deinterlaced output when calling SimpleSlug from within the Box function). This pointed out to me something you touched on in your thread, and that I'd thought I'd adequately reviewed for this script, the fact that variables are initialized even if they're not used. I've now hidden the 'bobbed' deinterlacing behind a conditional, and the top level assignment is a NOP() if the user asks for letter/pillar/windowboxed output. As such, there's only ever one QTGMC call in SimpleSlug--save bgargs, as noted--since everything I do is parse-time parameter selection, and all the QTGMC() lines peppered through it are merely strings that are later parsed by Eval(). It still may be worth adding the overwrite argument, I just need to look into it a bit more. I wanted to get a new version out to accomodate the new variable name, so any users I may actually have can use the fanciest new QTGMC you're offering. I'm working on finishing up TurnsTile 0.2.0 at the moment, which could be either a few hours or a few days away from release, but after that I'll swing back to SSU and take a deeper look at refining my approach to your global variable setup. |
||
5th March 2011, 23:03 | #37 | Link |
Registered User
Join Date: Jul 2010
Posts: 448
|
Thinking again, my suggestion is probably not a good idea - you'd be forcing users to upgrade QTGMC just to prevent a very remote possibility. And what I've done with the globals is... unusual - there's the possibility it will cause some unexpected problems and I'll have to backtrack. It seems that bgargs is used after your QTGMC evals anyway...
|
16th October 2011, 11:09 | #38 | Link |
partially-informed layman
Join Date: Jan 2002
Location: Bangkok, Thailand
Posts: 314
|
What options would I use in this to upscale 4:3 interlaced 720x576 PAL DV to 4:3 progressive 960x720 (square pixels)? At the moment I can only get 16:9 output. Such a preset would be very welcome.
|
16th October 2011, 14:23 | #39 | Link |
Registered User
Join Date: Feb 2010
Location: New York
Posts: 116
|
I limited the presets only to the most common broadcast formats that I'm aware of, just to try and keep things tidy, but what you're after is easy even without one:
Code:
SimpleSlugUpscale(outwidth=960, DARout=4.0/3.0) Code:
SimpleSlugUpscale(outheight=720, DARout=4.0/3.0) Code:
SimpleSlugUpscale(outwidth=960, outheight=720) 720x576 PAL DV will be autodetected on input, so the proper input pixel aspect ratio will be applied automatically, and the output PAR is assumed to be 1.0 unless specified or using a preset which isn't square pixel. If you want a QTGMC preset beside its default (I think "Slower", but don't quote me on that), just add the 'qual' parameter to your SimpleSlug call and enter it there. For the record, there is a preset for pillarboxed 960x720, and if anyone's interested it would be Code:
SimpleSlugUpscale(size="720pbox") |
16th October 2011, 15:35 | #40 | Link |
partially-informed layman
Join Date: Jan 2002
Location: Bangkok, Thailand
Posts: 314
|
Thanks Robert. Actually the first 3 options are stretching the video horizontally slightly and cropping the sides. I guess I need another option there somewhere.
This is for faux-HD on YouTube, which will recognise a 960x720 video as HD. It turns out it's actually the pillarboxed version I need, as I want to use the black sides for YouTube annotations, and the black sides that YouTube generates for the 960x720 version will not accept annotations. |
Tags |
qtgmc, resize, tempgaussmc, upscale |
Thread Tools | Search this Thread |
Display Modes | |
|
|