[opensource-dev] crazy land idea
kow at sapinski.com
Sun Sep 26 12:06:18 PDT 2010
I've been thinking about ways to implement subtractive objects for a
We would flag the object as subtractive and flip its normals.
During the rendering phase, we would apply a simple clipping algorithm
to each object to slice off the intersecting geometry.
The subtractive object would be merged into the original object to
create the hollowed section.
The math involved is very similar to the math already used in SL's
occlusion culling, and if used properly should reduce render time vs.
trying the create the same effect with many more prims.
A quick demo of an algorithm for openGL clipping can be found here:
Similar code would be required for the physics, lighting, and shadow
Subtractive geometry has been a basic feature of many game engines for
quite a while, and if used right improves performance.
I like the idea of using prims to define area effects like the presence
of rain or snow! This is exactly how these kinds of things are done in
other game engines. Content creators already do this with volume
detection but it could be supported better by the client and a new prim
On 9/26/2010 12:10 PM, Carlo Wood wrote:
> Hmmm, yes. There is more use to detecting "being inside a prim"
> and toggling certain render types as a result it seems.
> Now, an easy way would be to detect if the CAM is inside a prim,
> and then turn off -say- water fog, or whatever causes one to
> appear being under water; or turn off rain/snow if that is turned
> However, if then you look out the window, it stopped raining
> outside too.. so that isn't good enough.
> On Sun, Sep 26, 2010 at 09:46:09AM -0400, Tammy Nowotny wrote:
>> This is purely anecdotal (though maybe someone knows more than my anecdote): I
>> have heard that the SL game engine is not good at determining which points are
>> under/above/inside an enclosure such as a building. Moreoever, legend has it
>> that there is a whole weather system in the engine which was never activated
>> because there was no way to stop rain, snow etc. from going through roofs,
>> walls, etc.
More information about the opensource-dev