Anonymous avatar Anonymous committed 0b3628c

First pass of Version 1.1 done.

Comments (0)

Files changed (4)

 local lfs = require "lfs"
+local save = require "_StableSaveTable"
 
 --[[
-Copy algorithm.
+Copies the stuff from basic_dump to function_enums, but does so in a way that preserves the function_enum data entered thus far.
 
-* For each *.lua file in the basic_dump directory:
-** `dofile` the file.
-** Check to see if there is a corresponding file in the `function_enums` directory.
-*** if not:
-**** Write the loaded table, using stable ordering.
-**** Use hg add to add it to Mercurial.
-*** If there is a corresponding file there:
-**** `dofile` the destination file.
-**** For each function in the source:
-***** Check for a corresponding function.
-****** If one doesn't exist, copy the function entirely
-****** If one does exist, for each parameter in the source
-******* Check for a corresponding one in the destination function.
-******** If one doesn't exist, add it, with the parameter's table.
-******** If it does exist, do nothing.
-******* Given a corresponding function, for each parameter in the *destination*
-******** If no corresponding parameter exists in the source, delete it from the destion. Add it to the list of deleted entries.
-**** For each function in the destination that is *not* in the source
-***** Mark it as deleted and do not put it in the merged table.
+If parameters were removed in the new basic_dump, then the corresponding parameters will be deleted from function_enums. The same goes for functions that are removed (though this is unlikely). Parameter renaming has the same effect.
+
+This process should *only* be used when new .spec files have been published.
 ]]
 
 local sourceDir = "basic_dump/"
 local destDir = "function_enums/"
 
-local function WriteTableToFile(outputFilename, tbl)
-	local hFile = io.open(outputFilename, "w")
-	
-	--We want a stable write. So sort the table by function names.
-	local funcNames = {}
-	for name, funcData in pairs(tbl) do
-		funcNames[#funcNames + 1] = name
-	end
-	
-	table.sort(funcNames)
-	
-	hFile:write("return {\n")
-	
-	--Iterate over each function, in sorted order.
-	for _, funcName in ipairs(funcNames) do
-		hFile:write("['", funcName, "'] = {\n")
-		
-		local funcData = tbl[funcName]
-		
-		--Again for stability, write in order of parameter names.
-		local paramNames = {}
-		for paramName, paramList in pairs(funcData) do
-			paramNames[#paramNames + 1] = paramName
-		end
-		
-		table.sort(paramNames)
-		
-		for _, paramName in ipairs(paramNames) do
-			hFile:write("\t['", paramName, "'] = {")
-			if(#funcData[paramName] ~= 0) then
-				hFile:write("\n")
-				for _, enumName in ipairs(funcData[paramName]) do
-					hFile:write("\t\t'", enumName, "',\n")
-				end
-				hFile:write("\t")
-			end
-			hFile:write("},\n")
-		end
-		
-		hFile:write("},\n\n")
-	end
-	
-	hFile:write("}\n")
-	hFile:close()
-end
 
 local function ResolveTables(srcTable, destTable)
 	local finalTable = {}
 				end
 			end
 
-			WriteTableToFile(destPathname, finalTable)
+			save.WriteTableToFile(destPathname, finalTable)
 		else
 			--No matching file. So write it.
-			WriteTableToFile(destPathname, srcTable)
+			save.WriteTableToFile(destPathname, srcTable)
 			
 			--Add it to mercurial.
 			os.execute("hg add " .. destPathname)

RegularizeFunctionEnums.lua

+local lfs = require "lfs"
+local save = require "_StableSaveTable"
+
+
+
+local filename = ...
+
+local function Regularize(fullpathname)
+	local status, tbl = pcall(dofile, fullpathname)
+	
+	if(not status) then
+		print("Error processing " .. fullpathname)
+		print(tbl)
+	else
+		save.WriteTableToFile(fullpathname, tbl)
+	end		
+end
+
+local funcDir = "function_enums/"
+
+if(filename) then
+	Regularize(filename)
+else
+	for path in lfs.dir(funcDir) do
+		local fullpathname = funcDir .. path;
+		if(path:match("%.lua$") and lfs.attributes(fullpathname, "mode") == "file") then
+			Regularize(fullpathname)
+		end
+	end
+end

_StableSaveTable.lua

+
+
+local function WriteTableToFile(outputFilename, tbl)
+	local hFile = io.open(outputFilename, "w")
+	
+	--We want a stable write. So sort the table by function names.
+	local funcNames = {}
+	for name, funcData in pairs(tbl) do
+		funcNames[#funcNames + 1] = name
+	end
+	
+	table.sort(funcNames)
+	
+	hFile:write("return {\n")
+	
+	--Iterate over each function, in sorted order.
+	for _, funcName in ipairs(funcNames) do
+		hFile:write("['", funcName, "'] = {\n")
+		
+		local funcData = tbl[funcName]
+		
+		--Again for stability, write in order of parameter names.
+		local paramNames = {}
+		for paramName, paramList in pairs(funcData) do
+			paramNames[#paramNames + 1] = paramName
+		end
+		
+		table.sort(paramNames)
+		
+		for _, paramName in ipairs(paramNames) do
+			hFile:write("\t['", paramName, "'] = {")
+			if(#funcData[paramName] ~= 0) then
+				hFile:write("\n")
+				for _, enumName in ipairs(funcData[paramName]) do
+					hFile:write("\t\t'", enumName, "',\n")
+				end
+				hFile:write("\t")
+			end
+			hFile:write("},\n")
+		end
+		
+		hFile:write("},\n\n")
+	end
+	
+	hFile:write("}\n")
+	hFile:close()
+end
+
+return { WriteTableToFile = WriteTableToFile }

function_enums/Version_1_1.lua

 },
 
 ['BindTexture'] = {
-	['target'] = {},
+	['target'] = {
+		'TEXTURE_1D',
+		'TEXTURE_2D',
+		'TEXTURE_3D',
+		'TEXTURE_1D_ARRAY',
+		'TEXTURE_2D_ARRAY',
+		'TEXTURE_RECTANGLE',
+		'TEXTURE_BUFFER',
+		'TEXTURE_CUBE_MAP',
+		'TEXTURE_CUBE_MAP_ARRAY',
+		'TEXTURE_2D_MULTISAMPLE',
+		'TEXTURE_2D_MULTISAMPLE_ARRAY',
+	},
 },
 
 ['BlendFunc'] = {
-	['dfactor'] = {},
-	['sfactor'] = {},
+	['dfactor'] = {
+		'ZERO',
+		'ONE',
+		'SRC_COLOR',
+		'ONE_MINUS_SRC_COLOR',
+		'SRC_ALPHA',
+		'ONE_MINUS_SRC_ALPHA',
+		'DST_ALPHA',
+		'ONE_MINUS_DST_ALPHA',
+		'CONSTANT_COLOR',
+		'ONE_MINUS_CONSTANT_COLOR',
+		'CONSTANT_ALPHA',
+		'ONE_MINUS_CONSTANT_ALPHA',
+		'SRC_ALPHA_SATURATE',
+		'SRC1_COLOR',
+		'ONE_MINUS_SRC1_COLOR',
+		'SRC1_ALPHA',
+		'ONE_MINUS_SRC1_ALPHA',
+	},
+	['sfactor'] = {
+		'ZERO',
+		'ONE',
+		'SRC_COLOR',
+		'ONE_MINUS_SRC_COLOR',
+		'SRC_ALPHA',
+		'ONE_MINUS_SRC_ALPHA',
+		'DST_ALPHA',
+		'ONE_MINUS_DST_ALPHA',
+		'CONSTANT_COLOR',
+		'ONE_MINUS_CONSTANT_COLOR',
+		'CONSTANT_ALPHA',
+		'ONE_MINUS_CONSTANT_ALPHA',
+		'SRC_ALPHA_SATURATE',
+		'SRC1_COLOR',
+		'ONE_MINUS_SRC1_COLOR',
+		'SRC1_ALPHA',
+		'ONE_MINUS_SRC1_ALPHA',
+	},
 },
 
 ['CallLists'] = {
-	['type'] = {},
+	['type'] = {
+		'BYTE',
+		'UNSIGNED_BYTE',
+		'SHORT',
+		'UNSIGNED_SHORT',
+		'INT',
+		'UNSIGNED_INT',
+		'FLOAT',
+	},
 },
 
 ['ClipPlane'] = {
 },
 
 ['ColorMaterial'] = {
-	['face'] = {},
-	['mode'] = {},
+	['face'] = {
+		'FRONT',
+		'BACK',
+		'FRONT_AND_BACK',
+	},
+	['mode'] = {
+		'EMISSION',
+		'AMBIENT',
+		'DIFFUSE',
+		'SPECULAR',
+		'AMBIENT_AND_DIFFUSE',
+	},
 },
 
 ['ColorPointer'] = {
-	['type'] = {},
+	['type'] = {
+		'BYTE',
+		'UNSIGNED_BYTE',
+		'SHORT',
+		'UNSIGNED_SHORT',
+		'INT',
+		'UNSIGNED_INT',
+		'FLOAT',
+		'HALF',
+		'DOUBLE',
+		'INT_2_10_10_10_REV',
+		'UNSIGNED_INT_2_10_10_10_REV',
+	},
 },
 
 ['CopyPixels'] = {
-	['type'] = {},
+	['type'] = {
+		'COLOR',
+		'STENCIL',
+		'DEPTH',
+		'DEPTH_STENCIL',
+	},
 },
 
 ['CopyTexImage1D'] = {
 	['internalformat'] = {},
-	['target'] = {},
+	['target'] = {
+		'TEXTURE_1D',
+	},
 },
 
 ['CopyTexImage2D'] = {
 	['internalformat'] = {},
-	['target'] = {},
+	['target'] = {
+		'TEXTURE_2D',
+		'TEXTURE_1D_ARRAY',
+		'TEXTURE_RECTANGLE',
+		'TEXTURE_CUBE_MAP_POSITIVE_X',
+		'TEXTURE_CUBE_MAP_NEGATIVE_X',
+		'TEXTURE_CUBE_MAP_POSITIVE_Y',
+		'TEXTURE_CUBE_MAP_NEGATIVE_Y',
+		'TEXTURE_CUBE_MAP_POSITIVE_Z',
+		'TEXTURE_CUBE_MAP_NEGATIVE_Z',
+	},
 },
 
 ['CopyTexSubImage1D'] = {
-	['target'] = {},
+	['target'] = {
+		'TEXTURE_1D',
+	},
 },
 
 ['CopyTexSubImage2D'] = {
-	['target'] = {},
+	['target'] = {
+		'TEXTURE_2D',
+		'TEXTURE_1D_ARRAY',
+		'TEXTURE_RECTANGLE',
+		'TEXTURE_CUBE_MAP_POSITIVE_X',
+		'TEXTURE_CUBE_MAP_NEGATIVE_X',
+		'TEXTURE_CUBE_MAP_POSITIVE_Y',
+		'TEXTURE_CUBE_MAP_NEGATIVE_Y',
+		'TEXTURE_CUBE_MAP_POSITIVE_Z',
+		'TEXTURE_CUBE_MAP_NEGATIVE_Z',
+	},
 },
 
 ['CullFace'] = {
-	['mode'] = {},
+	['mode'] = {
+		'FRONT',
+		'BACK',
+		'FRONT_AND_BACK',
+	},
 },
 
 ['DepthFunc'] = {
-	['func'] = {},
+	['func'] = {
+		'NEVER',
+		'ALWAYS',
+		'LESS',
+		'LEQUAL',
+		'EQUAL',
+		'GREATER',
+		'GEQUAL',
+		'NOTEQUAL',
+	},
 },
 
 ['Disable'] = {
 },
 
 ['DisableClientState'] = {
-	['array'] = {},
+	['array'] = {
+		'VERTEX_ARRAY',
+		'NORMAL_ARRAY',
+		'COLOR_ARRAY',
+		'SECONDARY_COLOR_ARRAY',
+		'INDEX_ARRAY',
+		'EDGE_FLAG_ARRAY',
+		'FOG_COORD_ARRAY',
+		'TEXTURE_COORD_ARRAY',
+	},
 },
 
 ['DrawArrays'] = {
-	['mode'] = {},
+	['mode'] = {
+		'POINTS',
+		'LINE_STRIP',
+		'LINE_LOOP',
+		'LINES',
+		'POLYGON',
+		'TRIANGLE_STRIP',
+		'TRIANGLE_FAN',
+		'TRIANGLES',
+		'QUAD_STRIP',
+		'QUADS',
+		'LINES_ADJACENCY',
+		'LINE_STRIP_ADJACENCY',
+		'TRIANGLES_ADJACENCY',
+		'TRIANGLE_STRIP_ADJACENCY',
+		'PATCHES',
+	},
 },
 
 ['DrawBuffer'] = {
-	['mode'] = {},
+	['mode'] = {
+		'NONE',
+		'FRONT_LEFT',
+		'FRONT_RIGHT',
+		'BACK_LEFT',
+		'BACK_RIGHT',
+		'FRONT',
+		'BACK',
+		'LEFT',
+		'RIGHT',
+		'FRONT_AND_BACK',
+		'AUX0',
+		'COLOR_ATTACHMENT0',
+	},
 },
 
 ['DrawElements'] = {
-	['mode'] = {},
-	['type'] = {},
+	['mode'] = {
+		'POINTS',
+		'LINE_STRIP',
+		'LINE_LOOP',
+		'LINES',
+		'POLYGON',
+		'TRIANGLE_STRIP',
+		'TRIANGLE_FAN',
+		'TRIANGLES',
+		'QUAD_STRIP',
+		'QUADS',
+		'LINES_ADJACENCY',
+		'LINE_STRIP_ADJACENCY',
+		'TRIANGLES_ADJACENCY',
+		'TRIANGLE_STRIP_ADJACENCY',
+		'PATCHES',
+	},
+	['type'] = {
+		'UNSIGNED_BYTE',
+		'UNSIGNED_SHORT',
+		'UNSIGNED_INT',
+	},
 },
 
 ['DrawPixels'] = {
 },
 
 ['EnableClientState'] = {
-	['array'] = {},
+	['array'] = {
+		'VERTEX_ARRAY',
+		'NORMAL_ARRAY',
+		'COLOR_ARRAY',
+		'SECONDARY_COLOR_ARRAY',
+		'INDEX_ARRAY',
+		'EDGE_FLAG_ARRAY',
+		'FOG_COORD_ARRAY',
+		'TEXTURE_COORD_ARRAY',
+	},
 },
 
 ['EvalMesh1'] = {
-	['mode'] = {},
+	['mode'] = {
+		'POINT',
+		'LINE',
+	},
 },
 
 ['EvalMesh2'] = {
-	['mode'] = {},
+	['mode'] = {
+		'FILL',
+		'LINE',
+		'POINT',
+	},
 },
 
 ['FeedbackBuffer'] = {
 },
 
 ['Fogf'] = {
-	['pname'] = {},
+	['pname'] = {
+		'FOG_MODE',
+		'FOG_COORD_SRC',
+		'FOG_DENSITY',
+		'FOG_START',
+		'FOG_END',
+	},
 },
 
 ['Fogfv'] = {
-	['pname'] = {},
+	['pname'] = {
+		'FOG_MODE',
+		'FOG_COORD_SRC',
+		'FOG_DENSITY',
+		'FOG_START',
+		'FOG_END',
+	},
 },
 
 ['Fogi'] = {
-	['pname'] = {},
+	['pname'] = {
+		'FOG_MODE',
+		'FOG_COORD_SRC',
+		'FOG_DENSITY',
+		'FOG_START',
+		'FOG_END',
+	},
 },
 
 ['Fogiv'] = {
-	['pname'] = {},
+	['pname'] = {
+		'FOG_MODE',
+		'FOG_COORD_SRC',
+		'FOG_DENSITY',
+		'FOG_START',
+		'FOG_END',
+	},
 },
 
 ['FrontFace'] = {
-	['mode'] = {},
+	['mode'] = {
+		'CCW',
+		'CW',
+	},
 },
 
 ['GetBooleanv'] = {
 },
 
 ['GetClipPlane'] = {
-	['plane'] = {},
+	['plane'] = {
+		'CLIP_DISTANCE0',
+	},
 },
 
 ['GetDoublev'] = {
 },
 
 ['Hint'] = {
-	['mode'] = {},
-	['target'] = {},
+	['mode'] = {
+		'DONT_CARE',
+		'FASTEST',
+		'NICEST',
+	},
+	['target'] = {
+		'PERSPECTIVE_CORRECTION_HINT',
+		'POINT_SMOOTH_HINT',
+		'LINE_SMOOTH_HINT',
+		'POLYGON_SMOOTH_HINT',
+		'FOG_HINT',
+		'GENERATE_MIPMAP_HINT',
+		'TEXTURE_COMPRESSION_HINT',
+		'FRAGMENT_SHADER_DERIVATIVE_HINT',
+	},
 },
 
 ['IndexPointer'] = {
-	['type'] = {},
+	['type'] = {
+		'UNSIGNED_BYTE',
+		'SHORT',
+		'INT',
+		'FLOAT',
+		'DOUBLE',
+	},
 },
 
 ['InterleavedArrays'] = {
 },
 
 ['MatrixMode'] = {
-	['mode'] = {},
+	['mode'] = {
+		'TEXTURE',
+		'MODELVIEW',
+		'COLOR',
+		'PROJECTION',
+	},
 },
 
 ['NewList'] = {
 },
 
 ['PixelStoref'] = {
-	['pname'] = {},
+	['pname'] = {
+		'UNPACK_SWAP_BYTES',
+		'UNPACK_LSB_FIRST',
+		'UNPACK_ROW_LENGTH',
+		'UNPACK_SKIP_ROWS',
+		'UNPACK_SKIP_PIXELS',
+		'UNPACK_ALIGNMENT',
+		'UNPACK_IMAGE_HEIGHT',
+		'UNPACK_SKIP_IMAGES',
+		'UNPACK_COMPRESSED_BLOCK_WIDTH',
+		'UNPACK_COMPRESSED_BLOCK_HEIGHT',
+		'UNPACK_COMPRESSED_BLOCK_DEPTH',
+		'UNPACK_COMPRESSED_BLOCK_SIZE',
+	},
 },
 
 ['PixelStorei'] = {
-	['pname'] = {},
+	['pname'] = {
+		'UNPACK_SWAP_BYTES',
+		'UNPACK_LSB_FIRST',
+		'UNPACK_ROW_LENGTH',
+		'UNPACK_SKIP_ROWS',
+		'UNPACK_SKIP_PIXELS',
+		'UNPACK_ALIGNMENT',
+		'UNPACK_IMAGE_HEIGHT',
+		'UNPACK_SKIP_IMAGES',
+		'UNPACK_COMPRESSED_BLOCK_WIDTH',
+		'UNPACK_COMPRESSED_BLOCK_HEIGHT',
+		'UNPACK_COMPRESSED_BLOCK_DEPTH',
+		'UNPACK_COMPRESSED_BLOCK_SIZE',
+	},
 },
 
 ['PixelTransferf'] = {
-	['pname'] = {},
+	['pname'] = {
+		'MAP_COLOR',
+		'MAP_STENCIL',
+		'INDEX_SHIFT',
+		'INDEX_OFFSET',
+		'RED_SCALE',
+		'GREEN_SCALE',
+		'BLUE_SCALE',
+		'ALPHA_SCALE',
+		'DEPTH_SCALE',
+		'RED_BIAS',
+		'GREEN_BIAS',
+		'BLUE_BIAS',
+		'ALPHA_BIAS',
+		'DEPTH_BIAS',
+		'POST_CONVOLUTION_RED_SCALE',
+		'POST_CONVOLUTION_GREEN_SCALE',
+		'POST_CONVOLUTION_BLUE_SCALE',
+		'POST_CONVOLUTION_ALPHA_SCALE',
+		'POST_CONVOLUTION_RED_BIAS',
+		'POST_CONVOLUTION_GREEN_BIAS',
+		'POST_CONVOLUTION_BLUE_BIAS',
+		'POST_CONVOLUTION_ALPHA_BIAS',
+		'POST_COLOR_MATRIX_RED_SCALE',
+		'POST_COLOR_MATRIX_GREEN_SCALE',
+		'POST_COLOR_MATRIX_BLUE_SCALE',
+		'POST_COLOR_MATRIX_ALPHA_SCALE',
+		'POST_COLOR_MATRIX_RED_BIAS',
+		'POST_COLOR_MATRIX_GREEN_BIAS',
+		'POST_COLOR_MATRIX_BLUE_BIAS',
+		'POST_COLOR_MATRIX_ALPHA_BIAS',
+	},
 },
 
 ['PixelTransferi'] = {
-	['pname'] = {},
+	['pname'] = {
+		'MAP_COLOR',
+		'MAP_STENCIL',
+		'INDEX_SHIFT',
+		'INDEX_OFFSET',
+		'RED_SCALE',
+		'GREEN_SCALE',
+		'BLUE_SCALE',
+		'ALPHA_SCALE',
+		'DEPTH_SCALE',
+		'RED_BIAS',
+		'GREEN_BIAS',
+		'BLUE_BIAS',
+		'ALPHA_BIAS',
+		'DEPTH_BIAS',
+		'POST_CONVOLUTION_RED_SCALE',
+		'POST_CONVOLUTION_GREEN_SCALE',
+		'POST_CONVOLUTION_BLUE_SCALE',
+		'POST_CONVOLUTION_ALPHA_SCALE',
+		'POST_CONVOLUTION_RED_BIAS',
+		'POST_CONVOLUTION_GREEN_BIAS',
+		'POST_CONVOLUTION_BLUE_BIAS',
+		'POST_CONVOLUTION_ALPHA_BIAS',
+		'POST_COLOR_MATRIX_RED_SCALE',
+		'POST_COLOR_MATRIX_GREEN_SCALE',
+		'POST_COLOR_MATRIX_BLUE_SCALE',
+		'POST_COLOR_MATRIX_ALPHA_SCALE',
+		'POST_COLOR_MATRIX_RED_BIAS',
+		'POST_COLOR_MATRIX_GREEN_BIAS',
+		'POST_COLOR_MATRIX_BLUE_BIAS',
+		'POST_COLOR_MATRIX_ALPHA_BIAS',
+	},
 },
 
 ['PolygonMode'] = {
-	['face'] = {},
-	['mode'] = {},
+	['face'] = {
+		'FRONT',
+		'BACK',
+		'FRONT_AND_BACK',
+	},
+	['mode'] = {
+		'POINT',
+		'LINE',
+		'FILL',
+	},
 },
 
 ['ReadBuffer'] = {
-	['mode'] = {},
+	['mode'] = {
+		'NONE',
+		'FRONT_LEFT',
+		'FRONT_RIGHT',
+		'BACK_LEFT',
+		'BACK_RIGHT',
+		'FRONT',
+		'BACK',
+		'LEFT',
+		'RIGHT',
+		'FRONT_AND_BACK',
+		'AUX0',
+		'COLOR_ATTACHMENT0',
+	},
 },
 
 ['ReadPixels'] = {
 },
 
 ['RenderMode'] = {
-	['mode'] = {},
+	['mode'] = {
+		'RENDER',
+		'SELECT',
+		'FEEDBACK',
+	},
 },
 
 ['ShadeModel'] = {
-	['mode'] = {},
+	['mode'] = {
+		'SMOOTH',
+		'FLAT',
+	},
 },
 
 ['StencilFunc'] = {
-	['func'] = {},
+	['func'] = {
+		'NEVER',
+		'ALWAYS',
+		'LESS',
+		'LEQUAL',
+		'EQUAL',
+		'GEQUAL',
+		'GREATER',
+		'NOTEQUAL',
+	},
 },
 
 ['StencilOp'] = {
-	['fail'] = {},
-	['zfail'] = {},
-	['zpass'] = {},
+	['fail'] = {
+		'KEEP',
+		'ZERO',
+		'REPLACE',
+		'INCR',
+		'DECR',
+		'INVERT',
+		'INCR_WRAP',
+		'DECR_WRAP',
+	},
+	['zfail'] = {
+		'KEEP',
+		'ZERO',
+		'REPLACE',
+		'INCR',
+		'DECR',
+		'INVERT',
+		'INCR_WRAP',
+		'DECR_WRAP',
+	},
+	['zpass'] = {
+		'KEEP',
+		'ZERO',
+		'REPLACE',
+		'INCR',
+		'DECR',
+		'INVERT',
+		'INCR_WRAP',
+		'DECR_WRAP',
+	},
 },
 
 ['TexCoordPointer'] = {
 },
 
 ['TexParameterf'] = {
-	['pname'] = {},
-	['target'] = {},
+	['pname'] = {
+		'DEPTH_TEXTURE_MODE',
+		'DEPTH_STENCIL_TEXTURE_MODE',
+		'GENERATE_MIPMAP',
+		'TEXTURE_BASE_LEVEL',
+		'TEXTURE_BORDER_COLOR',
+		'TEXTURE_COMPARE_MODE',
+		'TEXTURE_COMPARE_FUNC',
+		'TEXTURE_LOD_BIAS',
+		'TEXTURE_MAG_FILTER',
+		'TEXTURE_MAX_LEVEL',
+		'TEXTURE_MAX_LOD',
+		'TEXTURE_MIN_FILTER',
+		'TEXTURE_MIN_LOD',
+		'TEXTURE_PRIORITY',
+		'TEXTURE_SWIZZLE_R',
+		'TEXTURE_SWIZZLE_G',
+		'TEXTURE_SWIZZLE_B',
+		'TEXTURE_SWIZZLE_A',
+		'TEXTURE_SWIZZLE_RGBA',
+		'TEXTURE_WRAP_S',
+		'TEXTURE_WRAP_T',
+		'TEXTURE_WRAP_R',
+	},
+	['target'] = {
+		'TEXTURE_1D',
+		'TEXTURE_2D',
+		'TEXTURE_3D',
+		'TEXTURE_1D_ARRAY',
+		'TEXTURE_2D_ARRAY',
+		'TEXTURE_RECTANGLE',
+		'TEXTURE_CUBE_MAP',
+		'TEXTURE_CUBE_MAP_ARRAY',
+		'TEXTURE_2D_MULTISAMPLE',
+		'TEXTURE_2D_MULTISAMPLE_ARRAY',
+	},
 },
 
 ['TexParameterfv'] = {
-	['pname'] = {},
-	['target'] = {},
+	['pname'] = {
+		'DEPTH_TEXTURE_MODE',
+		'DEPTH_STENCIL_TEXTURE_MODE',
+		'GENERATE_MIPMAP',
+		'TEXTURE_BASE_LEVEL',
+		'TEXTURE_BORDER_COLOR',
+		'TEXTURE_COMPARE_MODE',
+		'TEXTURE_COMPARE_FUNC',
+		'TEXTURE_LOD_BIAS',
+		'TEXTURE_MAG_FILTER',
+		'TEXTURE_MAX_LEVEL',
+		'TEXTURE_MAX_LOD',
+		'TEXTURE_MIN_FILTER',
+		'TEXTURE_MIN_LOD',
+		'TEXTURE_PRIORITY',
+		'TEXTURE_SWIZZLE_R',
+		'TEXTURE_SWIZZLE_G',
+		'TEXTURE_SWIZZLE_B',
+		'TEXTURE_SWIZZLE_A',
+		'TEXTURE_SWIZZLE_RGBA',
+		'TEXTURE_WRAP_S',
+		'TEXTURE_WRAP_T',
+		'TEXTURE_WRAP_R',
+	},
+	['target'] = {
+		'TEXTURE_1D',
+		'TEXTURE_2D',
+		'TEXTURE_3D',
+		'TEXTURE_1D_ARRAY',
+		'TEXTURE_2D_ARRAY',
+		'TEXTURE_RECTANGLE',
+		'TEXTURE_CUBE_MAP',
+		'TEXTURE_CUBE_MAP_ARRAY',
+		'TEXTURE_2D_MULTISAMPLE',
+		'TEXTURE_2D_MULTISAMPLE_ARRAY',
+	},
 },
 
 ['TexParameteri'] = {
-	['pname'] = {},
-	['target'] = {},
+	['pname'] = {
+		'DEPTH_TEXTURE_MODE',
+		'DEPTH_STENCIL_TEXTURE_MODE',
+		'GENERATE_MIPMAP',
+		'TEXTURE_BASE_LEVEL',
+		'TEXTURE_BORDER_COLOR',
+		'TEXTURE_COMPARE_MODE',
+		'TEXTURE_COMPARE_FUNC',
+		'TEXTURE_LOD_BIAS',
+		'TEXTURE_MAG_FILTER',
+		'TEXTURE_MAX_LEVEL',
+		'TEXTURE_MAX_LOD',
+		'TEXTURE_MIN_FILTER',
+		'TEXTURE_MIN_LOD',
+		'TEXTURE_PRIORITY',
+		'TEXTURE_SWIZZLE_R',
+		'TEXTURE_SWIZZLE_G',
+		'TEXTURE_SWIZZLE_B',
+		'TEXTURE_SWIZZLE_A',
+		'TEXTURE_SWIZZLE_RGBA',
+		'TEXTURE_WRAP_S',
+		'TEXTURE_WRAP_T',
+		'TEXTURE_WRAP_R',
+	},
+	['target'] = {
+		'TEXTURE_1D',
+		'TEXTURE_2D',
+		'TEXTURE_3D',
+		'TEXTURE_1D_ARRAY',
+		'TEXTURE_2D_ARRAY',
+		'TEXTURE_RECTANGLE',
+		'TEXTURE_CUBE_MAP',
+		'TEXTURE_CUBE_MAP_ARRAY',
+		'TEXTURE_2D_MULTISAMPLE',
+		'TEXTURE_2D_MULTISAMPLE_ARRAY',
+	},
 },
 
 ['TexParameteriv'] = {
-	['pname'] = {},
-	['target'] = {},
+	['pname'] = {
+		'DEPTH_TEXTURE_MODE',
+		'DEPTH_STENCIL_TEXTURE_MODE',
+		'GENERATE_MIPMAP',
+		'TEXTURE_BASE_LEVEL',
+		'TEXTURE_BORDER_COLOR',
+		'TEXTURE_COMPARE_MODE',
+		'TEXTURE_COMPARE_FUNC',
+		'TEXTURE_LOD_BIAS',
+		'TEXTURE_MAG_FILTER',
+		'TEXTURE_MAX_LEVEL',
+		'TEXTURE_MAX_LOD',
+		'TEXTURE_MIN_FILTER',
+		'TEXTURE_MIN_LOD',
+		'TEXTURE_PRIORITY',
+		'TEXTURE_SWIZZLE_R',
+		'TEXTURE_SWIZZLE_G',
+		'TEXTURE_SWIZZLE_B',
+		'TEXTURE_SWIZZLE_A',
+		'TEXTURE_SWIZZLE_RGBA',
+		'TEXTURE_WRAP_S',
+		'TEXTURE_WRAP_T',
+		'TEXTURE_WRAP_R',
+	},
+	['target'] = {
+		'TEXTURE_1D',
+		'TEXTURE_2D',
+		'TEXTURE_3D',
+		'TEXTURE_1D_ARRAY',
+		'TEXTURE_2D_ARRAY',
+		'TEXTURE_RECTANGLE',
+		'TEXTURE_CUBE_MAP',
+		'TEXTURE_CUBE_MAP_ARRAY',
+		'TEXTURE_2D_MULTISAMPLE',
+		'TEXTURE_2D_MULTISAMPLE_ARRAY',
+	},
 },
 
 ['TexSubImage1D'] = {
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.