Add protected Mesh constructor and move invalidate to VertexData

Adds a protected constructor to Mesh, which allows the user to specify a custom VertexData and IndexData implementation. Made it protected instead of public, because imo most users should not have to care about this and if they do then extending the Mesh class shouldn't be a problem.

Also moved the invalidate() method to the VertexData interface, instead of the instanceof check. Mesh shouldn't be aware of the VertexData implementation. E.g. VertexBufferObjectSubData does also have a invalidate() method implementation.