Path: utzoo!utgpu!watmath!clyde!att!alberta!calgary!cpsc!jevans From: jevans@cpsc.ucalgary.ca (David Jevans) Newsgroups: comp.graphics Subject: Re: raytracing in || Summary: blech Keywords: 4 rays per pixel Message-ID: <265@cs-spool.calgary.UUCP> Date: 1 Dec 88 02:46:37 GMT References: <9700001@datacube> <3148@uoregon.uoregon.edu> <1351@umbc3.UMD.EDU> <5548@thorin.cs.unc.edu> Sender: news@calgary.UUCP Lines: 36 In article <5548@thorin.cs.unc.edu>, brown@tyler.cs.unc.edu (Lurch) writes: > In article <5263@cbmvax.UUCP> steveb@cbmvax.UUCP (Steve Beats) writes: > >In article <1351@umbc3.UMD.EDU> bodarky@umbc3.UMD.EDU (Scott Bodarky) writes: > >If you sample the scene using one pixel per ray, you will get > >pretty severe aliasing at high contrast boundaries. One trick is to sample > >at twice the vertical and horizontal resolution (yielding 4 rays per pixel) > >and average the resultant intensities. This is a pretty effective method > >of anti-aliasing. > From what I understand, the way to achieve 4 rays per pixel is to sample at > vertical resolution +1, horizontal resolution +1, and treat each ray as a > 'corner' of each pixel, and average those values. This is super cheap compared > to sampling at twice vertical and horizontal. Blech! Super-sampling, as suggested in the first article, works ok but is very slow and 4 rays/pixel is not enough for high quality images. Simply rendering vres+1 by hres+1 doesn't gain you anything. All you end up doing is blurring the image. This is VERY unpleasant and makes an image look out of focus. Aliasing is an artifact of regular under-sampling. Most people adaptively super-sample in areas where it is needed (edges, textures, small objects). Super-sampling in a regular pattern often requires more than 16 rays per anti-aliased pixel to get acceptable results. A great improvement comes from filtering your rays instead of simply averaging them. Even better is to fire super-sample rays according to some distribution (eg. Poisson) and then filter them. Check SIGGRAPH proceedings from about 84 - 87 for relevant articles and pointers to articles. Changing a ray tracer from simple super-sampling to adaptive super-sampling can be done in less time than it takes to render an image, and will save you HUGE amounts of time in the future. Filtering and distributing rays takes more work, but the results are good. David Jevans, U of Calgary Computer Science, Calgary AB T2N 1N4 Canada uucp: ...{ubc-cs,utai,alberta}!calgary!jevans