[EMAIL PROTECTED] wrote:

> What exactly does the dispatch table do.  I understand that it is a 
> function pointer table, however, I do not fully understand what the pros 
> and cons of using it is.  I see that Haiku's implementation now uses 
> it.  I am trying to evaluate it to see if it would benefit me in the 
> design of the 3d driver foundation for Syllable.  Any help that you can 
> give me will be greatly appreciated.  Thanks.

With OpenGL, a particular GL function might behave differently 
depending on the state of things.  The most obvious example is display 
list vs. immediate mode.  glEnable, for example, will either be 
compiled into the current display list or immediately executed, 
respectively.  In other cases, we might use different versions of 
glColor3f if GL_COLOR_MATERIAL is enabled.

With a dispatch table, we can effectively change the implementation of 
all the GL functions on the fly for the most efficiency/flexiblity.

-Brian

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Mesa3d-dev mailing list
Mesa3d-dev@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mesa3d-dev

Reply via email to