|
|
Help encoding Xvid for XBMC playback?
I have had some success playing around with encoding levels for 1280x720 xvid files, and then getting good playback results on xbmc/mplayer.
My question is what method should I use for encoding 720p files (divx, xvid, wmvhd, etc) that will result in playback without dropped frames on xmbc.
I know that it is CPU limited but I have had some success, so part of me hopes that it is just a bitrate option, or quantizer, or something I don't know, as I have limited knowledge of the codec.
Thanks again.
JT
resize to 960x720 animorphic
do not use qpel, gmc, or high bitrate matrix
do use bframes and vbv
do NOT use b-frames and dont use wmv.
I wanted to try to keep the resolution to 1280x720 for maximum quality (and maintain the 16:9 ratio for the source).
So should I do full processing, a fast reencode or normal reencode using virtualdub?
what is the verdict on bframes and the matrix settings?
Thanks
fast processing mode ensures a faster and better quality encoding. it doesnt affect decoding at all.
b-frames add decoding complexity and turning them off should speed up the decoding process.
matrices affect the quantization process so, in theory, they should interfere with decoding speed.
do NOT use b-frames and dont use wmv.
who said anything about wmv? this xvid forum fast processing mode ensures a faster and better quality encoding
this isn't true
Basically I'm looking for a 'basic' guide to get the maximum amount of quality for a 1280x720 file, at the lowest decoding effort and the resulting size of the file is also not an issue (lots of hd space).
Can you guys suggest quick and dirty steps using virtualdub that would get me where I want to go?
Thanks again.
in my tests, the quality was actually higher using a smaller resolution because the higher resolution was too much for the xbox to handle. therefore to get the higher resolution to work you have to drop the bitrate which resulted in less quality overall.
btw: my tests are all done over the network. I found that playing off the harddrive will reduce the number of dropped frames during high bitrate scenes.
Is there anyway to optimize the codec so that on the high bitrate scenes the quality is reduced slightly to lower the bitrate temporarily, then when the scene is less intesive, the quality is raised?
In your experience what should I set the bitrate setting to, to get the highest quality vs lowest bitrate at 720?
thanks
I think VBV does prevent XviD from using more bits than 'allowed'. However the values for it are defined for each Profile / Level and I dont think you can change it as in some MPEG1/2 Encoders. If bitrate (and not the big resolution / cpu requirement for it) is really your problem then try the latest beta with VBV enabled and check which profiles gives you the most optimal trade-off.
Originally posted by Emp3r0r
this isn't true
No? and why? Maybe you should search a bit...
Originally posted by jthunder
Is there anyway to optimize the codec so that on the high bitrate scenes the quality is reduced slightly to lower the bitrate temporarily, then when the scene is less intesive, the quality is raised?
yes, xvid has it. it's called curve compression. u'll find it on the 2nd pass setup panel (lower part)
the bests
y
Thanks I'll post back to this thread once I've run through encodes to see how it looks and the performance on the xbox hardware.
JT
Originally posted by Sharktooth
No? and why?
As far as I know, fast processing mode just speeds up the first pass by taking a bunch of shortcuts. On the other hand, a full quality first pass should increase quality as it takes no shortcuts on the firstpass and the curve scaling should be more accurate for the second pass. However, the longer encoding time usually isn't worth the small boost in quality.
Sharktooth, if you know differently, by all means share what you know or at least provide a link that explains fast processing increases quality.
I think he is referring to the fast processing option in virtual dub. If I am correctly decoding Sharktooth's brainwaves - he means that forcing quot;fast recompressquot; keeps the video in yv12 through the whole encoding process - no color conversions.
Not that this would really impact decoding, since xvid uses yv12 colorspace anyway. Hmm now that I think about it I may not have a clue as to what Sharktooth means share it with us!
-MiSfit
How do I best speed up compression?
There is only one tip I can give: try enabling quot;fast repack.quot; When this is enabled, VirtualDub attempts to negotiate a fast YUV or YCrCb path between the video decompression and compression codecs. Both input and output video streams must be compressed, and you can get weird artifacts or flipped video with buggy codecs -- do not use it if Indeo Video R3.2 or Radius Cinepak are involved. This option will also disable all video filters, however, so it's mainly only useful for transcoding. It's not unusual to see overall frame rates increase by 20% when using fast repack.
Fast repack cannot be used with Ben's original versions of Avisynth, because they only output RGB data. Others have since released updated versions of Avisynth that can output YUY2 as well, and these will work in fast repack.
That is fast recompress in newer versions. That will make VDub directly give YV12 data that you feed it via AviSynth (for ex.) to the encoder - so no quality amp; speed loss due to color space conversions.
Sorry i meant Fast Recompress in Vdub.
Good news! it worked.
Fast recompress/single pass/xvid/unrestricted profile/no options selected/~4000Kbps
Now any of the 720p files that I had (wmv, divx, xvid) will playback smoothly using xbmc. I have noticed some quality compromises in some of the fast moving scenes, but in the slow detailed scenes it looks great. Although I have to admit that I don't really have that much to compare it to, but I do know that it looks better than the original DVD/MPEG2 480p source.
Thanks for the help guys, when I have some time I'm going to play around with a few of the options to see if I can get it any better. If you have any suggestions or experience with what settings I could change for quality vs bitrate I'd like to know.
JT
a 2 passes encode with the same settings will give you a better quality during high motion, but it will take longer to encode.
Are there any special settings for 2-pass that I should worry about? |
|