[PATCH v3 3/6] d3dx9: Factor our check_texture_requirements() function.