Archive

Archive for June, 2009

Binary PLY File Support

June 22nd, 2009 Romain No comments

I’ve just added support for binary files to my PLY file reader. With this enhancement on board I could render the heavier models from the Stanford 3D Scanning Repository.

Thai statue (10 million triangles)

Thai statue (10 million triangles)

I ran out of luck with the Lucy model, though, as the core engine would run out of memory (I have 3GB installed and compile as a 32-bit app) while constructing the kd-tree…. 28 million triangles is heavy, and my code for kd-tree construction is probably not the most memory efficient out there.

Material Representation

June 17th, 2009 Romain No comments

I am investigating how to represent materials in the core engine. Obviously it should be as physically correct as possible.

Here is my current wish list. The material representation should:

  1. Be physically-based (or at least physically plausible),
  2. Be capable of representing a wide variety of materials,
  3. Support sub-surface scattering (including single sheet SSS),
  4. Support thin film interference.

From readings and thoughts, I think that requirement no. 2 pretty much implies some sort of layered model to combine simple building blocks into a complex material. This is the route I am following at the moment.

As for references, I have grabbed a copy of Digital Modeling of Material Appearance by Dorsey, Rushmeier and Sillion, which in my opinion gives a good theoretical overview of the topic. And, of course, I am roaming the web for academic papers.

Regarding reference implementations, the PBRT book seems to give the most complete example.

Physical Sun

June 11th, 2009 Romain No comments

I’ve just finished integrating the Sun into the physically-based sky model. Here’s a test render:

Stanford Dragon in the sun

Stanford Dragon in the sun

This was quite an useful exercise as it exposed some bugs in my light sampling code. Moreover at first I had overlooked the fact that, in the Preetham et al. paper, data for the Sun and sky radiance are not in the same units… Looks fine now, though ;-)

PS: Note that in the render above I had increased the Sun’s angular diameter in order to better visualise soft shadows.

Physical Sky

June 5th, 2009 Romain 3 comments

It is perhaps not a priority at this point, but I felt like experimenting with the physical sky model by Preetham et al.

So far I have only crudely integrated skylight rendering. Sunlight and aerial perspective are next on my list.

Stanford dragon in the morning

Stanford dragon in the morning

I find this model quite simple to implement. In my opinion the downside is that it lacks the possibility to modify all the scattering parameters, and that it holds only for observers on the ground. Anyway, these limitations are pretty minor for me at the moment.

Introduction

June 3rd, 2009 Romain 5 comments

Yes, another blog on ray-tracing! ;-)

I am developing a photo-realistic render engine and hopefully this blog will make me stay focused and perhaps get useful comments.

The main objective of this render engine is to produce as accurate and realistic pictures as possible, possibly at the expense of render time.

For this reason this engine will implement physically-based, unbiased modelisation and rendering methods.

It is currently extremely primitive: It only supports Monte Carlo path tracing, simple area lighting scheme and Lambertian reflections.

Here is a test render featuring the famous Stanford dragon:

Stanford Dragon