Fixed issues with ref counted.
Changed Vector3f back to pass by register type.