Fix register.cxx so it actually works with VTK 6.