One glance at the yc waveform is all it takes to reveal the fact that my footage has been converted to RGB (fun black horizontal lines in the waveform), and after a dozen little tests, the culprit ended up being Avisynth. This won't do.
I found this thread:
In it, the suggestion is made to convert the video to Huffyuv, and that the new file can be used in an avisource command without resulting in an automatic RGB conversion. I tried this out with UT Video Codec and it worked like a charm.
The new problem with this process is a different kind of subtle degradation of the video. If I were to judge what's going on, it'd go something like this: UT Video Codec supports YUV420 and YUV422. Now, while theoretically YUV422 ought to be backwards compatible, so to speak, with the 4:1:1 video I am dealing with, in practice I recognize that the desirability of interpolating the chroma channel on such video means that the two really aren't compatible at all.
Anyway, I figure rather than beating my head against a wall, there's probably a way of forcing Avisynth to skip the rgb conversion on raw video, so that's what I'm currently after. ;p
(PS: Smoothlevels is great.)
+ Reply to Thread
Results 1 to 19 of 19
If your source is uncompressed UYVY, what does 4:1:1 chroma subsampling come into play? If you have a DV source and to duplicate chroma samples rather than interpolate, use ffdshow as your DV decoder.
Premiere Pro, wherein I have done considerable editing to my DV sources, and the ultimate intent is to output the entire cut-down DV as one big raw file which will then be fed to Avisynth.
As for why I don't simply smart render the DV from Premiere Pro as DV, well, I could do that. But that would be no solution at all when it comes to other, non-DV footage, like the 1080i footage which will require pretty much the same external fixes (smoothlevels and QTGMC) and essentially must be rendered as raw.
Incidentally, if I render raw from PPro and then convert it to UT Video with VDub, the luma levels above 235 get crushed, which is one of the problems this whole process is meant to avoid. So that's out.
describe your workflow exactly, and what decoders you are using
you're probably converting to RGB in premiere , and that's causing the clipping
uncompressed YUV (any fourcc) will remain YUV with AVISource() . If there was clipping, it was occurred before reaching avisynth
Premiere Pro. For the time being, that means DV type 1 straight from the tapes. Once I get past this hump, future footage will include 1440x1080i MPEG2 straight from tapes, and 1920x1080p59.94 raws. The raws will be rendered from their AVCHD originals by something besides Premiere Pro due to the fact that PPro is incapable of decoding them without producing a severe chroma bug (even as of CS5) and Adobe evidently doesn't care. The raws will be replacing downscaled (720p) re-encoded proxy videos which I have created to ease the editing process.
After editing the DV video, the intent is to render everything as raw, import to Avisynth, process, export as raw again with Virtualdub, and reimport to Premiere Pro for final integration into the whole video project. There are actually more steps which I may as well outline in brief:
DV -> PPro -raw-> Avisynth, smoothlevels -> VDub -raw-> PPro, noise reduction -raw-> Avisynth, QTGMC -> VDub -raw-> PPro
Avisynth without Avisynth converting to RGB.
Last edited by Asterra; 22nd May 2011 at 16:17.
Because when you use UT through vdub in fast recompress mode (you bypass the RGB conversion and Rec.601 clipping)
Let's clarify: Avisynth doesn't convert to RGB, unless you specify ConvertToRGB() . Something ELSE is causing the RGB conversion, like your decoder or a program upstream.
Premiere Pro and see for myself that it is unmodified (apart from a very, very slight alteration which I cannot explain, but which I am willing to deal with because it is in effect inconsequential). Also there is the thread I mentioned earlier wherein there is a more detailed cause for why Avisynth is converting Avisource uncompressed UYVY to RGB, although none of the suggestions in that thread will work in my case.
What kind of edits are you doing in Premiere? Most filters work in RGB, so if you applied some color correction etc...
Ahhh I didn't see your ninja edit on your post
Anyways the "PPro, noise reduction" stage is most certainly where the RGB conversion is occuring. Unless you imported RGB, that is where the Rec601 clipping is occurring
I just did some quick tests with a full range 10-bit 422 YUV video (v210) , which definitely passes through premiere as YUV. This is the format I recommended to you in a couple of your other threads
Exporting v210 (uncompressed microsoft AVI => V210) works fine (both avisynth with ffvideosource, and back into premiere YC waveform shows full range)
If you use (microsoft AVI=> V210) , the fourcc is actually "012v" (byte order is backwards) , while this works fine for premiere, other programs don't see it as "v210", including ffvideosource
"UYVY" isn't handled correctly by default decoder, when exporting out , nor does ffvideosource handle it correctly (you probably need 3rd party decoder installed, either vfw for AVISource, or directshow for directshowsource or dss2) . It is handled correctly importing back in
Avisynth could import some type of lossless video without converting to RGB. The result was that it could, but due of the interpolation-mandated nature of 4:1:1 video, I could not use this method.
Does anyone know a way of opening an AVI 2.0 (OpenDML) uncompressed 8-bit UYVY file without converting to RGB?
"AviSource" calls "msyuv.dll" which inmediately converts to RGB.
Update: It seems the magical combination which may end up working is uncompressed v210 + FFVideoSource. No green frames on the four-frame clip. Crossing my fingers now. Thanks for the help as always!
LOL, I recommended v210 in your earlier threads . It's the "magic" one for premiere , allowing levels to go through untouched
Vegas' "magic" one is IYUV
Note, RawSource() is supposed to support UYVY, but there is corruption in the tests I did
e.g. RawSource("UYVY.avi", 1280,720, "UYVY")
vdub "sees" the UYVY export correctly when opened natively (if you have "show image formats" checked, and use a null filter, both input and output are UYVY without corruption)
I verified that AviSource() always converts uncompressed UYVY AVI to RGB. I can't find any way around that. DirectShowSource("filename.avi", pixel_type="YUY2") works and retains superblack and superwhites (see note below). DSS2() can open the UYVY and automatically outputs YUY2 with no losses (see note below). VirtualDub can convert from uncompressed UYVY to YUY2 without any loss (Video -> Color Depth -> set output format). Can't Premiere be set to output YUY2 instead of UYVY?
Note: I have ffdshow installed and the Raw Video decoder enabled and the output set to YUY2 only. Ie, ffdshow is acting as the decoder for UYVY and converting to YUY2.
Last edited by jagabo; 22nd May 2011 at 17:58.
Avisynth to accept a v210 video. FFVideoInput was the missing ingredient.
Incidentally, I'd be interested in hearing your thoughts on Premiere Pro's very subtle degradation of the video when outputting as uncompressed v210 (or UYVY). Try with my handy DV clip:
Just save as uncompressed v210 or UYVY, reimport, go to the yc waveform and compare with the original. The degradation is the same whether you choose v210 or UYVY, and it's definitely not identical to the DV original. I don't consider it a huge deal, but it does bug me somewhat.
They look the same to me in the YC Waveform. Are you looking at the same frame between the original and v210 ?
I suspect somewhere along the line there is a YUV to RGB conversion and back. Not all 8 bit YUV values map to unique RGB values and vice versa. So converting YUV to RGB then back to YUV will not return the original values. That will cause a few "holes" in a waveform monitor.
AFAIK, premiere works in YUV with a DV-AVI only project
I guess there is a very subtle change , here are some comparisons, the original, v210, and dv export . dv is smart rendered so of course that is the same.
If anyone is haveing difficulty seeing the differences, look around 20IRE
It might be 422 vs 411, but that shouldn't show up in a Y waveform
It might be 10-bit vs. 8-bit handling and how premiere rounds off or truncates values
There are differences shown in other programs between the original and v210 export (e.g. difference masks) but that depends on how the upsampling is done
I was all set to show the differences I am seeing but it looks like folks have already noticed them. I'll post this little image anyway since I went through the trouble.
It does look a lot like what you get with an RGB conversion, and that's why this is bugging me. Why go through all this trouble if a RGB-conversion-like amount of degradation is taking place anyway? Well whatever it is - and I note that there's no clear answer here - it's not the same thing you get with a definite RGB conversion. The differences from the original are similar but distinctly different from one another. I also don't think it has to do with 10-bit vs 8-bit because if you export as v210 and also as UYVY and compare the two, the two results are in fact identical.
It still could be 4:2:2 vs. 4:1:1 for DV. Both v210 and UYVY are upsampled to 4:2:2, but I don't know why the luminace would be different; I thought Y should be independent of Cb,Cr