On Wed, Jul 23, 2008 at 7:50 PM, Pat Suwalski <pat@...> wrote:
> Chris Laurel wrote:
>> Can anyone think of a reason to keep this old code around?
> If it's a lot of code that isn't being maintained then it might as well go.
> The logical question is if it actually gets in the way of anything? In other
> words, what prompted this desire to remove it?
Somewhat ironically, I was looking to improve compatibility with
non-NVIDIA graphics cards. Point sprites only seem to work correctly
on NVIDIA cards (though they *used* to work on some ATI cards, too.)
Point sprites can be 'faked' by drawing squares that always face the
camera (a technique called 'billboarding'.) In order to do this, it's
necessary for the mesh rendering code to know the model/view matrix.
The RenderInfo class already has a member variable to store an
orientation, but it's not quite the correct one for billboarding.
Instead, it's a value that's exclusively used for bump mapped
rendering in the combiners-only render path. I'd like to store a more
generally useful value in the RenderInfo orientation instead of a
special case for a legacy render path. I probably could rewrite the
combiner bump mapping use the billboarding orientation, but it strikes
me as a colossal waste of time to do so. I could also opt to store
*both* the bump mapping orientation and the billboarding orientation,
but I feel like this bloat is unnecessary. And I'd still be stuck
having to test the combiner only path to make sure it still worked.