Transition from Phase to Generalized Synchronization