Reworked VM_CL_PolygonBegin/Vertex/End functions to do the commit to the mesh in PolygonEnd, this allows it to examine if alpha is used on vertices and request different variants of a material according to such discoveries.
Refactored CL_MeshEntities_AddToScene and CL_MeshEntities_Reset to be the more distinct stages of CL_MeshEntities_Scene_Clear (which is called in VM_CL_R_ClearScene), CL_MeshEntities_Scene_AddRenderEntity (which is called during VM_CL_R_AddEntities), and CL_MeshEntities_Scene_FinalizeRenderEntity (which is called during VM_CL_R_RenderScene) - this fixes issues with CSQC predraw functions adding polygons which were not subject to Finalize and thus not rendered.
Fixed Mod_LoadTextureFromQ3Shader handling of texture name "" to properly set basematerialflags, this fixes invisible polygons in some games such as Xonotic.
Refactored CL_Mesh_CSQC and CL_Mesh_Debug into CL_Mesh_Scene - not really a need for more than one mesh to overlay on the world.
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12567
d7cf8633-e32d-0410-b094-
e92efae38249