For conversion into DivX/XviD, I use D-Vision3. Its default choices produce very good output (and you can override the defaults if you want/need to). I recommend giving that app a try.
Also, lanczos can produce problems of its own (aside from slow encoding). Precisely because of its frequency response, any Gibbs phenomenon-related artifacts introduced by the rest of the encoding process can result in visually objectionable results. If your quality issues have more to do with a "graininess" or coarseness, as opposed to motion artifacts or blur, you may wish to reconsider your choice of scaling algorithm.