In the hereditary form, a germline mutation alters one allele in all cells, and a later somatic mutation alters the other allele in the retinal cells (the second hit in this two-hit model), resulting in the cancer.