Artificial retina for the treatment of pigmented retinopathy and macular degeneration