X-Reyes

Tuesday, February 14, 2006

A little snip here, a little snip there

In order to pave the way for the next phase, I have done some trimming of the data structures used within the X-Reyes.

The chief culprit was the use of the svg:metadata element to store additional data (metadata if you like) about the primitives. I had used an:

<xr:bbox top="0" right="16" bottom="16" left="0"/>

element to store the bounding box of each primitive (and micropolygon). This, as I'm sure you can imagine is rather verbose. So I have done away with the svg:metadata element and now use an:

xr:bbox="0 16 16 0"

attribute instead. This has reduced the memory required to process an image by a third.

Sweet!

Labels: , , ,

Thursday, February 09, 2006

Add a bit of opacity can make things clearer

The addition of opacity makes things a bit more interesting. I used a simple equation:

I = k * I + (1 - k) * I'

where k is the opacity, I is the intensity (the value of each of the RGB colour channels) of the nearest of two overlapping polygons and I' is that of the one behind it.

Labels: , , ,

Monday, February 06, 2006

That's more like it!

The square peg in the square hole. For the rather simplistic sampling strategy I'm using at present, the occlusion culling is quite straight forward. Find the first micropolygon who's top-left vertex matches the sample coordinates. And yes you're right, no multipoint stochastic sampling here. But then why would I? I'm working in pixel units only and there are no rotated primitives, diagonal lines or curves.

As yet...

Labels: , , ,

Friday, February 03, 2006

Not so clever now are we, aye?

I need to explain here that this image was supposed to be an orange square, half the size of the blue one, placed in the middle of the image.

Now at first glance it would seem that I've either got my buckets muddled up, or else the tiles in the TIFF image, which coincidentally are the same size as the buckets (16x16) have got jumbled. Well not so.

It so happens that I didn't realize the importance of Occlusion Culling. My buckets contain samples for all the micropolygons for each of the primitives covered by the bucket. What I need to do is only keep one sample, the first, (seeing as the micropolygons have been depth sorted) for each sample position in the bucket.

I'd better go and implement the occlusion culling before I go any further.

Labels: , , ,

Getting there...

It seems a bit of a leap from my previous posts to this one that announces results of the first tests of this implementation of the Reyes pipeline. However, above is a JPEG of the first TIFF image produced.

Yes, blue isn't it!

Now, don't all rush at once, it is a simple image but it proves that I can get an input SVG graphic through the pipeline, in the processes splitting it into smaller primitives, create grids, bust the grids into micropolygons, sample them, wrap the rendered sequence of pixel values in a TIFF image format before running it through a Base64 encoding and out to the file system (all in XSLT I might add). Of course I have to Base64 decode the resulting file in order to view it, but that's trivial compared to what has gone on previously.

Labels: , , ,