To be an RAF pilot, you need to meet minimum eyesight requirements.
This means that in almost all cases, you will not be able to become a pilot with the RAF if you need to wear glasses or corrective lenses. This is just one of the medical conditions that preclude entry.
You may be allowed to become part of the aircrew with glasses, but this is not guaranteed and you should discuss it with a Recruitment Officer at your local AFCO.