refactor to Pic class - not quite working