Move the Check* type functions into wined3d and copy from d3d9, and