vec2 vec3 refactoring