We study generalized magnetic Schrödinger operators of the form H h (A, V ) = h(Π A ) + V , where h is an elliptic symbol, Π A = −i∇ − A, with A a vector potential defining a variable magnetic field B, and V is a scalar potential. We are mainly interested in anisotropic functions B and V . The first step is to show that these operators are affiliated to suitable C * -algebras of (magnetic) pseudodifferential operators. A study of the quotient of these C * -algebras by the ideal of compact operators leads to formulae for the essential spectrum of H h (A, V ), expressed as a union of spectra of some asymptotic operators, supported by the quasi-orbits of a suitable dynamical system. The quotient of the same C * -algebras by other ideals give localization results on the functional calculus of the operators H h (A, V ), which can be interpreted as non-propagation properties of their unitary groups.