View Full Version : Is mjpegcorrect() still needed in Avisynth 2.5?
famawizard
29th May 2003, 22:37
I think so...
but do you know if a version for avisynth 2.5 exists?
And if not, how is it possible to make the same luma corrections using other filters?
Thanks
Lucio
P.S.
Is there an Huffyuv version for YV12?
I did read the thread but find nothing...
Wilbert
30th May 2003, 15:35
One of the last questions in the YV12 faq!
sh0dan
30th May 2003, 16:19
- Don't double post!
- Use search.
:readfaq:
The other thread has been removed.
famawizard
31st May 2003, 12:41
Sorry for the double post... :(
But I used search and I did read the FAQ...
I was not sure that was the new version of Huffy...
and, what about mjpegcorrect?
I read the threads but I am a bit confused...and after many tests I am still more confused...
Sometimes it seems that filter is needed, sometimes it changes nothing.
Exactly, does someone know what modifications mjpegcorrect does?
Lucio
(BTW excuse me for my bad English)
P.S.
I captured the same sequence (640x480 mjpeg picvideo and morgan latest beta) both in YUV2 and YV12 formats but I noticed no speed difference encoding in Divx5.05 from avisynth 2.5.1 (no filtering added, I use only avisource).
Probably I am wrong, but shouldn't the conversion be faster from an YV112 source?
sh0dan
31st May 2003, 19:54
- MjpegCorrect seem to be a luma-scaling filter - this should not be necessary at any time. Use historgram to check your color ranges - if you run it in YV12 mode it should not enter the "brown/yellow" areas, but black should lie at the bottom of this range. See the capture guide on the main doom9 page for more info.
- Using MJPEG it doesn't matter what format you capture in - this will have no impact on the speed you get, when decoding it.
I think the issue is that some mjpeg codecs improperly/inconsistently clip the luma range to 16-235 when encoding/decoding yuy2. This thread (http://forum.doom9.org/showthread.php?threadid=32066) is fairly informative. I use the pixel_type parameter in avisource to force rgb decoding and then convert to yuy2 or yv12. Presumably it's slower than mjpegcorrect, but perhaps more accurate?
For completeness, decoding picvideo in yuy2 then converting to yv12 does run into the "brown/yellow" areas of histogram. Decoding in rgb then converting to yv12 does not. The morgan codec seems to have the same problem.
Edit: coloryuv(levels="pc->tv") should do the same thing as mjpegcorrect, but decoding to rgb seems more accurate to me.
sh0dan
1st June 2003, 09:18
@waka: Luma range SHOULD be limited to 16-235.
RGB->YUV convertion also produces 16-235 as defined by CCIR 601. When you do this you get overbrighted video.
I phrased that poorly, what I should of said is that on decoding 16-235 is scaled to 0-255(!?!). On encoding 0-255 is clipped to 16-235. At least thats how it seems to work on my system. Decoding in yuy2 using avisynth and resaving in vdub causes the video to get more and more clipped with each iteration.
sh0dan
1st June 2003, 15:28
Oh - I haven't experienced this with Morgan MJPEG, but maybe Avid Express exports as RGB.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.