[Soc-2009-dev] Raytrace api

André Pinto andresusanopinto at gmail.com
Mon May 11 17:12:13 CEST 2009

Hi all,

this week I have been coding a more generic raytrace api and I have some

* In the new files (rayobject.h, rayobject*.c), I copied the GPL license
block from other files and changed copyright to "2009 Blender Foundation". I
also set the properties svn:keywords and svn:eol-style.
Is this all that needs to be done for created files?
And Is there any sample GPL licence block? i noticed those sligtly change
between files.

* The exported functions from render, should all started with RE_ ?
That means the functions I added should be:

* Is it safe to assume that all MEM_callocN are aligned to 4bytes?

==API details==
Details about the ray trace design implementation

I denoted RayObject as everything where its possible to raycast including a
single face or a complex data structure.
Thus allowing to create compound structures (eg.: a bvh of octrees (like 1
octree per object)).

In order to allow an eficient type-detectation mechanism, all RayObjects are
aligned to 4bytes, leaving 2bits of adress to determine the type, so far 2
types exist:

RayFace - struct with coords, object and face.
RayObject - struct to an abstract raytrace aceleration, with callbacks to
generic stuff like: add faces, free struct and raycast

All callbacks like get coordinates/transform_coords, check_hit, where
removed for now.. as the functionality of those will be coded as needed in a
better way.

For now only API and Isect structure were modified.
Daniel Salazar(ZanQdo) reported an 9% improve on his quad core2  :)
At the moment only shadow rays work/were tested.

Best regards,
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.blender.org/pipermail/soc-2009-dev/attachments/20090511/85d8c7be/attachment.htm 

More information about the Soc-2009-dev mailing list