ray tracing

Started by
5 comments, last by playmesumch00ns 18 years, 6 months ago
hi everyone, i'm new here and was hoping to get some help about a project i have. now i dont want someone to do my work for me, all i'm asking is some guidelines, as i'm new to programming and i have limited programming experience. so i need to improve those skills and know where to look. here's the description of my project: The aim of this project is to investigate techniques that are used to render impure translucent objects. You are required to design and implement a ray tracer to render such type of objects like jade. to tell the truth i have no idea what that means, all i did before was a couple of 2d games and simple 3d one. so i have no idea where to start looking.. can anyone direct me a bit here please? like tell me what subjects i should look for on net or in books, or what tasks/problems i should be looking for their solutions??? basically any guidelines to get me started (i have to write a report in 10 days explaining my plans and steps) so please any resources names, or suggestions on research plans, like to know what to read first and what to read second. looking forward for suggestions as its very important for me. thanks alot
Advertisement
This is a pretty tall order - proper translucency is a pretty sophisticated effect. You have a lot of reading ahead of you [wink]

First, I'm assuming you'll need a good solid grounding in raytracing. A good web-based crash course is available at FuzzyPhoton. Once you're familiar with the basic concepts, it's time to move on to the complex bit. At this stage, I would strongly recommend implementing your own simple raytracer, because continuing on with research without a little bit of experience with the technique will probably just make you confused. Practicing the fundamentals is critical here.

The next phase is to start reading up on global illumination models. Do some research into radiosity, path tracing, Monte Carlo sampling techniques, and photon mapping. Ideally, you should be able to sit down and explain the basics of each of these areas when you are done, and note the important differences, advantages, and disadvantages of each. A good solid Google session should get you started on those topics - and be sure to make good friends with CiteSeer, as it will lead you to a trove of well-known publications on various rendering methods.

Then you just need to pick which method seems the easiest to implement, and bang it into your raytracer. If you're highly prolific and/or have a huge amount of time to finish the project, you might try implementing two or three methods and writing up a post-mortem analysis of the strengths and weaknesses of the models you implemented.

Wielder of the Sacred Wands
[Work - ArenaNet] [Epoch Language] [Scribblings]

What about this link from FlipCode?
Raytracing Topics & Techniques: Part 1
I was planing on going through that at some point.
Programming since 1995.
wow you got yourself a tall order is right. basically you have to impliment the volume rendering equation of some sort.

first off you got purely absorbing materials or materials where absorption strongly dominates over scattering. such materials include glass, water(for the most part) and wine, whiskey, dimonds, etc etc. but liquids that have a merky appearence such as milk or rocks such as marble or jade scattering becomes a factor. the reason that's it's so hard to simulate is because scattering becomes a factor. you can't just simply treat jade as strictly absorbative material simulating absorption is simple(look up beers law of attenuation) basically this is a function of how far your ray traversed through the material. however scattering function is not only a function of how far the ray travels throught the material, but also how much light scatters along the direction of the ray from all other points within the medium, this light that scatters in, is also a function of all other points lol so you got a very large recursion problem. most methods only simulate a single scatter. as the equations for multiple scatter are so heavely recursive as to be hopelessly inefficent. there are ways however, one straightforward way is using photon mapping to account for multiple scatter. other methods use diffusion theory and is good for layered surfaces.

however there are many ways to fake it. like lighting the surface with a standard lighting model. then adding some light based on how far a ray traverses the medium. you can fake it lots of ways. but to do it accurate is a very advanced measure. look up the volume rendering equation for the correct way to do this, look up volumetric rendering and you'll probably find lots of hacks if that's what your after. unless this is a graduate level class I'd assume that's what you're after. whatever the level of physical accuracy you want to impliment, all the methods are solved using ray marching technique, so google that.

Tim
Given that jade is one of the most common subsurface scattering demo materials, I'd imagine they'd want you to implement the dipole diffusion approximation.

Read A Practical Model For Subsurface Light Transport, then read A Rapid Hierachical Technique For Translucent Materials.

To implement a raytracer that does this you'll need simple geometry and camera classes, as well as an acceleration structure. The flipcode tutorial will give you all you need for that.

Next thing to do is add lighting. Since you're going for physical realism, I'd advise you to implement an HDRI environment light.

Once you've done all that it's fairly trivial to add final gathering for some extra credit.

I could probably give you a better idea of what's achievable if you let us know how long you're going to have to do this.
that's really advanced stuff, I would think if he were at that level he'd know where to look already and probably wouldn't be asking us this question. he probably implimenting some sort of hack. this is probably simple volumetric rendering with a single scatter. assuming homogenious scattering coefficent.

Tim
It's really not that difficult. Jensen just likes horrific symbols!

If you have enough time to implement it I can help you decipher the paper.

The basic algorithm goes

1) Distribute particles uniformly on the surface
2) Evaluate the illumination at each of these particles (this could be normal direct lighting, or could involve GI--it doesn't really matter)
3) For each point you want to shade, loop over all the particles and apply the dipole diffusion approximation (it's just a function based on the distance between points and some material parameters )

This topic is closed to new replies.

Advertisement