Is Compass Active in all Altitude and Manual Flight Modes?

I can´t find any information about compass use in diffrent flight modes.
I know the compass is active in position mode and during RTL. But how about Altitude or Manual?

Lets say we would like to take-off from a metall surface where the compass/mag reading gets interfered. Would it be possible to take-off in Altitude or Manual mode?

Compass can be used for autonomous navigation so I assume it’s not used in any manual or assisted modes other than Position.

Is there anyway to confirm this?