summaryrefslogtreecommitdiff
path: root/src/mesa/glapi/glX_proto_size.py
AgeCommit message (Collapse)Author
2005-03-17Enable the generation of server-side __glGetBooleanv_size and relatedIan Romanick
functions. There are two parts to this. First, a size element with a name "Get" is shorthand for having four separate size elements with names "GetIntegerv", "GetDoublev", "GetFloatv", and "GetBooleanv". Additionally, a count of "?" is treated specially. This causes a call to a handcoded function named "__gl<base name>_variable_size". This is *only* needed to support GL_COMPRESSED_TEXTURE_FORMATS. That enum can return a variable number of values depending how many compressed texture formats are supported by the implementation. Fix a problem with glGetProgram{Local,Env}Parameter[df]vARB, glAreProgramsResidentNV, and glGetVertexAttribivNV. These changes only affect code generated for the server-side. The changes to enum.c are caused by enums added for the server-side __glGetBooleanv_size functions.
2005-03-17Refactored some of the code for PrintGlxReqSize_[ch]. This ensures that theIan Romanick
same set of functions will be iterated for both the generated C-source file and the generated header file.
2005-02-02Small refactor. Add glXFunctionIterator, which derrives fromIan Romanick
glFunctionIterator and is used by GlxProto. The difference between the two iterator classes is that glXFunctionIterator skips functions that the GLX protocol code does not care about. Replace all the remaining occurances of glParameter::p_count_parameters and glFunction::count_parameters with the count_parameter_list. Add GlxProto::size_call to generate the C code to calculate 'compsize'. These trivially modify the generated code.
2005-02-01Small refactor. Move several utility functions from glX_XML.py toIan Romanick
FilterGLAPISpecBase (in gl_XML.py). When these functions are used to emit common #define lines, the will automatically be undefined in FilterGLAPISpecBase::printFooter if header_tag is set (i.e., the file is a header file). These changes do not modify the generated code.
2005-02-01Add GlxProto::createEnumFunction and add a 'context' parameter to theIan Romanick
glXEnumFunction constructor. The allows sub-classes of GlxProto to over-ride the concrete class used for glXEnumFunction. In addition to tracking p_count_parameters in glParameter, break the comma separated list of parameter names into a Python list called count_parameter_list. It is now possible to query if a name is the name of one of the count parameters just by comparing param.count_parameter_list.count(n) to zero. Eventually the remaining uses of p_count_parameters will be replaced with uses of count_parameter_list. Make sure that 'void *' parameters are handled correctly in glParameter::size_string. Add PrintGlxReqSize_h and PrintGlxReqSize_c. These classes emit prototypes and functions used on the server-side to determine the expected size of an incoming GL command.
2005-01-28Refactor the code to emit multiple-inclusion protection toIan Romanick
FilterGLAPISpecBase. Since the size_h mode of glX_proto_size.py will be used to generate multiple header files, add an option to specify the define that is used for multiple-inclusion protection. The changes to the header files in this commit are just a side-effect of the changes to the Python scripts.
2005-01-27The 'mode' setting of a function within an 'enum' element is now used.Ian Romanick
Parameters to glX_proto_size.py are now used to determine whether to emit either get-type function, set-type functions, or both. When only get-type functions are emitted, they can optionally alias set-type functions. This would be useful if, for example, the two types were in different source files. The real work to implement this is in SizeStubFunctionIterator class. All of the logic for which functions to iterate and in which order is implemented there.
2005-01-24Correctly set the name of the generating script.Ian Romanick
2005-01-24Move all the code for generating "size" related functions to its ownIan Romanick
source file.