View Full Version : Problem encoding uncompressed AVI
kallekill
5th July 2004, 13:44
I have made an uncompressed RGB24 AVI out of many TGA still images. I wanted to make a DVD out of it so I used Cinemacraft Encoder to encode it to mpeg2. The mpeg2 looks good in Windvd that I am using, but when I tried to play the clip in Media Player Classic the colors on some objects are bleeding and moving object leaves smudges like a bad divx. The picture is also too dark. I tried it in Powerdvd and there it looks too dark and stutters a lot in many scenes. In Elecards MPEG2 player it plays fine but looks too dark. I don’t have any problems playing other DVDs in either Powerdvd or Mediaplayer classic and I have encoded movies captured from VHS that looks good. I suspected that something was wrong with CCE so I tried to encode the avi with TMPG but the result is exactly the same. I use constant bitrate at 8000 kbits/s with both encoders.
I then tried to compress the avi to HuffYUV and that looks fine. I then tried MJPEG and it looks too dark and horizontal banding problems on some objects. If I try to make an Xvid or Divx of the avi, it is too dark and depending on which decoder I use for playing the divx I get pixilated edges on some objects.
I can’t understand what is causing this. It can’t be the encoder since it is the same with different encoders and it’s strange that it plays fine in Windvd. It must have something to do with the source, but it’s uncompressed so I don’t understand what. Could it have something to do with the color conversion from the RGB24 to YUV for MPEG? I’m not so familiar with color compressions and I’ve seen there are a lot of different formats like RGB, YUV 4:2:0, YUV 4:2:1, YUV 4:2:2 and different ways in AVIsynth to convert between them.
ppera2
5th July 2004, 14:53
Diverse players use diverse playback software (algorithms). So, no wonder that there is difference in playback, especially in case of total unusual uncompressed RGB 24 still image flow.
It's not good idea to encode with Tmpgenc to AVI, and especially not to constant bitrate.
Try with Gordian Knot and XviD. But which setting use to Slide-show, I can't say. Need to experiment.
It's possible that you will need to manually correct AVS script.
Need to add pixeltype info:
AviSource("Filename",pixel_type="RGB24")
kallekill
5th July 2004, 15:56
The uncompressed avi is the source I am using when encoding the Mpeg2 with tmpg. The avi is a normal uncompressed avi with RGB24 color. I made the avi with a utility that takes a series of still images as input and makes a avi file out of them. It is the encoded mpeg2-file that looks bad in media player classic and stutters in powerdvd. I know that they use different software algorithms to decode but this clip have strange errors and looks like a badly encoded divx while it looks perfect in windvd.
I tried specifying the source's colorformat with that AVS script but it didn't help.
kallekill
5th July 2004, 18:34
I think I know why the compressed video gets darker. The overlay isn't used when playing the uncompressed AVI and the HuffYUV compressed avi. Windvd seems to alter the overlay brightness and thats why it looks brighter. If I go into the overlay control tab on the driver settings while having windvd open in the background it reverts back to the default overlay brighness.
I still don't understand why the mpeg2 looks like crap in Powerdvd and Media Player classic though. When turning on bitrate information in Powerdvd it goes from 8000 kbit/s (which is the actual rate) to 2 kbit/s and jumps around when the picture is stuttering.
ppera2
5th July 2004, 19:45
Originally posted by kallekill
The uncompressed avi is the source I am using when encoding the Mpeg2 with tmpg....
I tried specifying the source's colorformat with that AVS script but it didn't help.
Understood. Codecs are made primaly for moving content, not for slideshow. Encoding with constant bitrate is totally wrong aproach.
You should try to encode with some settings with strong scene changes sensitivity.
It looks that there is no (much) people with such experience. Maybe you should perform lot of tests with diverse settings, and inform us how it progress :)
kallekill
5th July 2004, 20:02
Yes, I have compressed the file to Xvid and Windows Media Video 9 and it looks fine. I'm going to put the Windows Media 9 video on my webpage (I chose WMV9 so that the codec is downloaded automatically)
My only problem now is that the mpeg2 encoded movie stutters in Powerdvd and that colors bleeds and smears in Media Player Classic. It is obviously dependant on the mpeg2 decoder, but there must be some way to prevent this since all other mpeg2 movies plays fine.
I don't have a standalone DVD myself, but I'm going to try the dvd on some friends DVD players and see how it works.
kallekill
5th July 2004, 20:10
The movie I'm encoding isn't a slideshow. To be able to do a network render in 3D Studio you have to save the movie as still images. The frames are divided among the computers and saved as images. Then I merge the images to an uncompressed AVI to get the final moving scene.
I use constant bitrate at 8000 kbit/sec when encoding mpeg2 because it is the maximum recommended bitrate that should get the best results with all content. The file gets pretty big, but this isn't a concern since my movie is only 4 minutes and easily fits on a cd with 5.1 audio and menus.
ppera2
5th July 2004, 22:41
I see. Maybe you should try with another Mpeg2 encoder. They aren't free, but usually you have trial versions for probe. CCE, Mainconcept...
kallekill
5th July 2004, 23:35
I tried CCE and I get the same problem with encoding artifacts in media player classic. But it plays fine in powerdvd though. Guess I have to live with this.
ppera2
5th July 2004, 23:53
There is possibility in Media Player Classic to have control over decoding filters. Just go in Options, Filters, Overrides section.
It can use Mpeg2 decoders from software DVD players like Win DVD and Power DVD. At least it worked in earlier versions, I didn't try it with new versions of mentioned software.
Soulhunter
6th July 2004, 00:44
Hmm, could you maybe post some sampleframes ???
You can upload them here... (http://www.imageshack.us/) ;)
Bye
kallekill
6th July 2004, 09:40
It looks fine in Media Player Classic if I use Intervideo's decoder. It is the built in decoder that smears the picture. It is much more obvious when the picture is moving. The smear doesn't stay as long as is usual with bad encoded divx since the mpeg2 has keyframes much more often.
I've tried to take a sample of it here. The right picture is the good looking one and the left is the movie encoded with media player classic. Notice the greenish smear in the left side of the picture. Also notice that the red color bleeds over to the yellow color. The lower picture is a zoom in on a red color that is completely red. A black object just passed over it causing this smear.
http://www.geomatics.kth.se/sjoberg/homepage/screenshot/smear.jpg
ppera2
6th July 2004, 10:51
Originally posted by kallekill
... The smear doesn't stay as long as is usual with bad encoded divx since the mpeg2 has keyframes much more often...
Of course, you can set kayframe ratio to lower value by XviD or DivX.
Even to value of 1, so there will be only keyframes.
kallekill
6th July 2004, 18:25
Originally posted by ppera2
Of course, you can set kayframe ratio to lower value by XviD or DivX.
Even to value of 1, so there will be only keyframes.
Yeah, but I remember those early divx movies were moving objects smeared purple and green stuff that could last for ten seconds.
Soulhunter
6th July 2004, 18:41
If it's really somehow source related, and not only a broken decoder...
Try to encode it again with AddGrain (low value) via AviSynth !!!
Only a guess, don't know if it really helps... :rolleyes:
Bye
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.