On Mon, Sep 21, 2009 at 05:58:06PM -0600, Brian Paul wrote: > When we omit a feature such as convolution, I'd rather entirely omit > convolve.c and convolve.h from the build rather than define a bunch > of new no-op convolution stub functions in convolve.h I wanted to make #if's more a one-time effort. The #if's are either in convolve.h, or in every location, say, _mesa_adjust_image_for_convolution is called. This includes in st, meta, and drivers. It becomes horrible soon.
I am not against having #if's outside convolve.h. I think #if's should be used to whenever one wants to eliminate a chunk of code because it is not needed. But, #if's should no be _required_ because a function may become unavailable. Another reason for not omitting the files is that a feature may have states. It may need to initialize the states to sane defaults even it is disabled. pixel.c is an example. If it is omitted, the initialization code would have to be duplicated somewhere else. > The current system for dealing with features might be prone to > occasional build failures, but when I did the ES subset it really > wasn't a big deal (it was easy to find the stale calls to removed > functions and fix them). The current feature system is really > simple, and results in a bit less code. I think the patches look more complex than they really are because they are converting existing features. When supporting a new extension, following the convensions should not make it more complex, if not simpler. They also remind the driver author that he/she is implementing a feature. This is important because new features are constantly added. > Do you feel strongly about these patches? I would like to see them in. Looking at the recently added features, there are already some sort of convensions. This patch series is built upon them, and has the hope that not only core mesa, but also drivers can follow them eventually. -- Regards, olv ------------------------------------------------------------------------------ Come build with us! The BlackBerry® Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9-12, 2009. Register now! http://p.sf.net/sfu/devconf _______________________________________________ Mesa3d-dev mailing list Mesa3d-dev@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mesa3d-dev