Self-polar double configurations in projective geometry: I. A general condition for self-polarity